<resource-ref>
<ref-name>LookupName</ref-name>
<resource-link>EntityBeanName</resource-link>
</resource-ref>
but if I do it this way, how I create the context ?
Like this:
Context ctx = new InitialContext(); //without parameters ?
Best Regards,
Olivier Voutat
On 3/31/06,
Manu George <[EMAIL PROTECTED]> wrote:
Hi Olivier,
You need not pass any properties to the InitialContext for local lookups from other components running in the server. You only need to give an ejb-ref in the deployment descriptor. You can get more info on this from Aaron's book
http://www.chariotsolutions.com/geronimo/geronimo-html-one-page.html
There are also many examples in developerworks and confluence
RegardsManuOn 3/30/06, Olivier Voutat < [EMAIL PROTECTED]> wrote:To do the remote lookup for a bean I was setting my properties like this :
----------------------------------------------------------------------------------------------------------------------------------
prop.put("java.naming.factory.initial","org.openejb.client.RemoteInitialContextFactory");
prop.put("java.naming.provider.url","localhost:4201");
prop.put("java.naming.security.principal","system");
prop.put("java.naming.security.credentials","manager");
----------------------------------------------------------------------------------------------------------------------------------
I was researching and found that local calls should use:
----------------------------------------------------------------------------------------------------------------------------------
prop.put("java.naming.factory.initial","org.openejb.client.LocalInitialContextFactory");
----------------------------------------------------------------------------------------------------------------------------------
but the question is (and I'm asking because I didn't had enough time to keep testing) do I need the other properties lines ? Think not because it is a internal container lookup but would like to be sure.
Best Regards,
Olivier Voutat
--
Olivier & Cidiane Voutat
Rua Praia de Muriú, 9188
Cep 59092-390 / Natal - RN
Tel: (84) 3219-0427 Cel: (84) 9977-3917
--
Olivier & Cidiane Voutat
Rua Praia de Muriú, 9188
Cep 59092-390 / Natal - RN
Tel: (84) 3219-0427 Cel: (84) 9977-3917
