Hi. Again.
Now. The code seems correct. Except, the
url, that MAY require to be of the type:
ormi://localhost/Your_App_Name.
If you have deployed your beans in an
application, and NOT in the default APP, you HAVE to use the url with the
app_name at the end.
in config/server.xml
<application
name="Your_App_Name" path="../applications/YourApp.ear"/>
in properties:
java.naming.provider.url=ormi://your.host.your.domain/Your_App_Name
or
java.naming.provider.url=ormi://localhost/Your_App_Name << FOR LINUX
MAINLY!
in java code:
p.put(Context.PROVIDER_URL,
"ormi://localhost/Your_App_Name");
Then you will find your ejbs.
I would sincerly offer you to look-up the
name of the bean without any prefixes. It is hard to move to other app server
sometimes. In your case if you have no ejb-link, ejb-ref and so on stuff, just
look-up OrgOrganizations:
ctx.lookup("OrgOrganizations");
Also let's note, that if you use the
java:comp/* context it may not port well on different servers.
Lachezar.
P.S. Give it a try and write
again.
|
- how to shutdown orion app server? gusl
- Re: how to shutdown orion app server? mars
- RE: how to shutdown orion app server? Michael C. Han
- Re: how to shutdown orion app server? Liu Bin
- Re: how to shutdown orion app server? Lachezar Dobrev
- SV: how to shutdown orion app server? Jesper Rasmussen
- Re: how to shutdown orion app server? Renaud Bruyeron
- Re: how to shutdown orion app server? Mark Kettner
- Message Driven Beans Michael Maurer
- Re: Re: how to shutdown orion app server? Liu Bin
- Lachezar Dobrev