[jboss-user] [EJB/JBoss] - Re: Problem when trying to access an EJB bean in an Enterpri
jaikiran
do-not-reply at jboss.com
Thu Nov 9 07:32:30 EST 2006
anonymous wrote : Yes, and I'v put these code into C:\Program Files\jboss-4.0.3\server\default\conf\jndi.properties
That's the wrong file which you edited. You will have to have the jndi.properties file in the application-client's classpath.
anonymous wrote : Do you know also how to code application-client.xml?
Had done it long time back so dont remember the exact contents but this is what i could think about:
application-client.xml:
| <?xml version="1.0" encoding="UTF-8"?>
|
| <!DOCTYPE application-client PUBLIC '-//Sun Microsystems, Inc.//DTD J2EE Application Client 1.3//EN' 'http://java.sun.com/dtd/application-client_1_3.dtd'>
|
| <application-client>
| <display-name>My App Client</display-name>
| <ejb-ref>
| <ejb-ref-name>ejb/someEJB</ejb-ref-name>
| <ejb-ref-type>Session</ejb-ref-type>
| <home>package.HomeClassName</home>
| <remote>package.RemoteClassName</remote>
| </ejb-ref>
|
| </application-client>
and the jboss-client.xml:
| <jboss-client>
| <jndi-name>SampleApplicationClient</jndi-name>
|
| <ejb-ref>
| <ejb-ref-name>ejb/someEJB</ejb-ref-name>
| <jndi-name>TheJndiNameOfTheEJB</jndi-name>
| </ejb-ref>
|
|
|
| </jboss-client>
the jndi.properties in the application client's classpath:
java.naming.factory.initial=org.jnp.interfaces.NamingContextFactory
| java.naming.provider.url=jnp://localhost:1099
| java.naming.factory.url.pkgs=org.jboss.naming.client
| j2ee.clientName=SampleApplicationClient
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3984485#3984485
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3984485
More information about the jboss-user
mailing list