WebSphere Application Server - WSAD local context problem

This is Interesting: Free IT Magazines  
Home > Archive > WebSphere Application Server > February 2004 > WSAD local context problem





You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

Author WSAD local context problem
kumar73

2004-02-26, 2:33 am

I am getting local jndi context probem to access local home bean.

env.put(Context.INITIAL_CONTEXT_FACTORY,
"com.ibm.websphere.naming.wsninitialcontextfactory");

env.put(Context.provider_url, "iiop://localhost:2809");

then jndictx = new InitialContext(env);

got successful creation of jndi...

but when i look up jndi context for local bean it is failing...

I tried ,

java:com:env/ejb/mypackage/mybean

got error saying that name not found in context "java:"

tried

local:/ejb/ejb/...

got same error saying that Name not found in context "local:"

if i pass with out java: or local again it is saying that name not found


in a universal test client package structure showing that


local ejb beans --package -----localhome

please any genius help me...i spend more than 1 week for this problem


advance thanks kumar



--
posted via MFF : http://www.MainFrameForum.com - USENET Gateway
Ken Hygh

2004-02-26, 6:33 am

kumar73 wrote:
> I am getting local jndi context probem to access local home bean.
>
> env.put(Context.INITIAL_CONTEXT_FACTORY,
> "com.ibm.websphere.naming.wsninitialcontextfactory");
>
> env.put(Context.provider_url, "iiop://localhost:2809");
>
> then jndictx = new InitialContext(env);
>
> got successful creation of jndi...
>
> but when i look up jndi context for local bean it is failing...
>
> I tried ,
>
> java:com:env/ejb/mypackage/mybean
>
> got error saying that name not found in context "java:"


This syntax will only work if you create an EJB reference.

>
> tried
>
> local:/ejb/ejb/...
>
> got same error saying that Name not found in context "local:"
>
> if i pass with out java: or local again it is saying that name not found
>
>
> in a universal test client package structure showing that
>
>
> local ejb beans --package -----localhome


Your EJB should have a JNDI name - use it.

>
> please any genius help me...i spend more than 1 week for this problem
>
>
> advance thanks kumar
>
>
>
> --
> posted via MFF : http://www.MainFrameForum.com - USENET Gateway


Sponsored Links






Free braindumps | Software forum | Database administration forum

Copyright 2003 - 2008 webservertalk.com