Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

WebSphere 6.0 jndi question

 
Greenhorn
Posts: 26
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Report post to moderator
I can't believe I have to ask this, but I can't figure it out
and this is my job, not merely fun so I've got to get my ducks
in a row.
Using WebSphere 6.0 I start up a Websphere 6.0 server on
localhost that runs within the WebSphere IDE.
Then I right click on it and select "run universal test client".
That opens up a browser with the UTC in it. (The url is:
http://localhost:9080/UTC/initialize?port=2809?wasAdminPort=2809 )
Then I select the "JNDI Explorer". It shows a tree of the
jndi entries it has. One of them is "eis". When I click on "eis"
it shows: net.sourceforge.filera.api.FileResourceAdapterConnectionFactory (net.sourceforge.filera.api.FileResourceAdapterConnectionFactory)

There is also a text box labeled "Jndi Name" which you can fill in
and then press the "lookup" button.

So what I do is, I copy/paste the following into the "Jndi Name"
box:

eis:net.sourceforge.filera.api.FileResourceAdapterConnectionFactory

Then I press the "lookup button".

Here is what I get:

IWAD0402E Could not perform lookup with the JNDI name: NamingManager.getURLContext cannot find the factory for this scheme: eis

So I try this in the text box:

eis/net.sourceforge.filera.api.FileResourceAdapterConnectionFactory

And this is what I get:

IWAD0402E Could not perform lookup with the JNDI name: Context: gloverr-webNode01Cell/nodes/gloverr-webNode01/servers/server1, name: eis/net.sourceforge.filera.api.FileResourceAdapterConnectionFactory : First component in name net.sourceforge.filera.api.FileResourceAdapterConnectionFactory not found.

So I try this in the text box:

eis\net.sourceforge.filera.api.FileResourceAdapterConnectionFactory

and this is what I get:

IWAD0402E Could not perform lookup with the JNDI name: Escape character (\) was followed by a character other than "/" or "\" in the name component, "eis\net.sourceforge.filera.api.FileResourceAdapterConnectionFactory ".

IN fact, I can never, ever put anything in the text box that
it says is a valid jndi name.


I am running:

IBM Rational Software Development Platform

Version: 6.0.0.1
Build id: 20050214_1800


Actually, what I eventually will start discussing here is
JCA 1.5, but I've got to crawl a bit before getting to that point.

Thank you very much for any help anyone can provide.

Robert




It also has a text box which lets you
type a jndi name in. But every time I type a jndi name into the
text box, it says it is an invalid name.
 
Robert Glover
Greenhorn
Posts: 26
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Report post to moderator
I'm making a little progress. I wrote a little Servlet, to
make experimenting the JNDI easier. Here is the relevant portion:

=====================================================
protected void doWork(HttpServletRequest request, HttpServletResponse
response) throws ServletException, IOException {
ServletOutputStream sos = response.getOutputStream();
String sContextToLookup =
(null==request.getParameter("param1")) ? "eis" : request.getParameter("param1");
sos.println("<html><head><title>FileraNyseMwPocServ</title></head>");
sos.println("<body>");
sos.println("<h1>Hello World. param1='" + sContextToLookup + "'</h1>");
InitialContext context = null;
Object obj = null;
try {
context = new InitialContext();
obj = context.lookup(sContextToLookup);
} catch (NamingException e) {
sos.println("<h1>" + e.getMessage() + "</h1>");
sos.println("</body></html>");
return;
}
sos.println("<h1>obj.toString()='" + obj.toString() + "'</h1>");
sos.println("<h1>Goodbye... " + (new Date()).toString() + "</h1>");
sos.println("</body></html>");
}
====================================================

When I run the servlet, here's what I get:

Hello World. param1='eis'
obj.toString()='com.ibm.ws.naming.jndicos.CNContextImpl(gloverr-webNode01Cell/nodes/gloverr-webNode01/servers/server1/eis)'
Goodbye... Fri Sep 23 18:31:32 EDT 2005

=================
However, if I go to Universal Test Client .... JNDI Explorer and
type "eis" into the text box, I get this message:

IWAD0401E Unknown type of JNDI object

And if I type "/eis" into the text box I get:

IWAD0402E Could not perform lookup with the JNDI name: Context: gloverr-webNode01Cell/nodes/gloverr-webNode01/servers/server1, name: /eis: First component in name /eis not found.

================================
Now, currently in Universal Test Client the only enty that appears
in the visual JNDI tree for EIS is:
DefaultDatasource_CMP (javax.resource.cci.ConnectionFactory)

=======================================
Yes, when I type "/eis/DefaultDatasource_CMP" into the JNDI text
box I get:

IWAD0402E Could not perform lookup with the JNDI name: Context: gloverr-webNode01Cell/nodes/gloverr-webNode01/servers/server1, name: /eis/DefaultDatasource_CMP: First component in name /eis/DefaultDatasource_CMP not found.

===========================================

Obviously I don't know how to use the JNDI text box. It must
be very simple. Somebody out there must surely know the secret...
 
Robert Glover
Greenhorn
Posts: 26
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Report post to moderator
Made some more progress. In the test servlet I can not
get from JNDI the Factory:

=======================================
Hello World. param1='eis/filera'
obj.toString()='net.sourceforge.filera.api.DefaultFileResourceAdapterConnectionFactory@53847959'
Goodbye... Fri Sep 23 19:04:15 EDT 2005
=========================================

And in Universal Test Client when I type "eis/filera" into the
test box I get: IWAD0401E Unknown type of JNDI object

==========================================

I may end up answering this question myself, in which case I
apologize for using up bandwidth unnecessarily.
 
author & internet detective
Posts: 41860
908
Eclipse IDE VI Editor Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Report post to moderator
Robert,
In WSAD 4 and 5, you could only look up EJBs through that JNDI lookup box. I haven't used RAD 6 yet, but that is likely to be the case there too.

I may end up answering this question myself, in which case I
apologize for using up bandwidth unnecessarily.


No such thing. It helps everyone to see the answer. That way future people with the same problem can read what happened.
 
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Report post to moderator
I am using IBM Rational Software Development Platform as well. However I have updated it with Refresh Pack 1. I am not sure what seems to be the problem , it worked find in one of my colleagues machine and it doesnt work on my own machine. Same error, unknown JNDI Object when I clicked on a simple calculator EJB deployed from the Sample Gallery.

I am totally new with the Rational Software Dev, anyone having this sort of problem?

I am suppose to write application on Spring with this. I am not gaining much confidences in this product with these kind of glitches.

Thanks in advance for all your help

Joshua
 
J Yi
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Report post to moderator
Hi Robert,

I am making some progress on the JNDI Explorer. Make sure you go to Project ---> Clean, Build Auto, then go to server tab , and Click on Publish.

I cant say for sure which is the step which made it "click" but my JNDI Explorer is able to use the Simple Calculator after I have done the above.

Do remember to restart the Universal Test Client before you view the JNDI Explorer again

Joshua
[ October 12, 2005: Message edited by: Joshua Yip ]
 
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Report post to moderator
Unfortunately I cannot help but confirm this problem which I have after I updated the WAS 6 Express to 6.0.2.1. My entity and session beans are listed by UTC but without link to activation. And when I lookup for the remote home interface I also get IWAD0401E as result.

I also tried this: http://www-1.ibm.com/support/docview.wss?rs=404&context=SS7K4U&dc=DB520&uid=swg21211302&loc=en_US&cs=UTF-8&lang=all

But it did not help.

My application can access and use the beans and runs fine.

Also I can use the UTC on a different workstation.

This is very crazy and I already spent much time to figure out, what the reason could be.
 
J Yi
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Report post to moderator
After updating my Websphere RAD to 6.0.2.1 , I am having the same prb as described above. JNDI Explorer, no activation link on my beans... I am now uninstalling it, since the fix pointed out by IBM on UTC doesnt work for me either

Anyone else have any luck on this?
 
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Report post to moderator
If you "Build Project" after the Deployment, then it works. To test it please restart the UTC.
 
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Report post to moderator
I am running WAS 6.0 from a AIX box. I have some message-driven enterprise bean in my application which needs an activation specification JNDI name.As i have checked "set default bindings", it has automatically generated the JNDI name as eis/GFSAGG by looking up the specific ejb xml.
My application fails to start when I try to start from Applications > Enterprise Applications > Check my application name and click start.

When I check with the logs it shows the following message

[2/20/07 10:07:50:118 GMT+00:00] 00000039 RALifeCycleMa E J2CA0052E: The lookup of the ActivationSpec with JNDI Name eis/GFSAGG failed due to exception javax.naming.NameNotFoundException: Context: MyNodeNode01Cell/nodes/MyNodeNode01/servers/server1, name: eis/GFSAGG: First component in name GFSAGG not found. Root exception is org.omg.CosNaming.NamingContextPackage.NotFound: IDL mg.org/CosNaming/NamingContext/NotFound:1.0
at com.ibm.ws.naming.ipcos.WsnOptimizedNamingImpl.do_resolve_complete_info(WsnOptimizedNamingImpl.java:969)
at com.ibm.ws.naming.cosbase.WsnOptimizedNamingImplBase.resolve_complete_info(WsnOptimizedNamingImplBase.java:1435)
at com.ibm.WsnOptimizedNaming._NamingContextStub.resolve_complete_info(Unknown Source)
at com.ibm.ws.naming.jndicos.CNContextImpl.cosResolve(CNContextImpl.java:4045)
at com.ibm.ws.naming.jndicos.CNContextImpl.doLookup(CNContextImpl.java:1776)
at com.ibm.ws.naming.jndicos.CNContextImpl.doLookup(CNContextImpl.java:1737)
at com.ibm.ws.naming.jndicos.CNContextImpl.lookupExt(CNContextImpl.java:1444)
at com.ibm.ws.naming.jndicos.CNContextImpl.lookup(CNContextImpl.java:1324)
at com.ibm.ws.naming.util.WsnInitCtx.lookup(WsnInitCtx.java:144)
at javax.naming.InitialContext.lookup(InitialContext.java:361)
....................................................................
....................................................................


Caused by: javax.naming.NameNotFoundException: Context: MyNodeNode01Cell/nodes/MyNodeNode01/servers/server1, name: eis/GFSAGG: First component in name GFSAGG not found. [Root exception is org.omg.CosNaming.NamingContextPackage.NotFound: IDL mg.org/CosNaming/NamingContext/NotFound:1.0]
at com.ibm.ws.naming.jndicos.CNContextImpl.processNotFoundException(CNContextImpl.java:4394)
at com.ibm.ws.naming.jndicos.CNContextImpl.doLookup(CNContextImpl.java:1784)
at com.ibm.ws.naming.jndicos.CNContextImpl.doLookup(CNContextImpl.java:1737)
at com.ibm.ws.naming.jndicos.CNContextImpl.lookupExt(CNContextImpl.java:1444)
at com.ibm.ws.naming.jndicos.CNContextImpl.lookup(CNContextImpl.java:1324)
at com.ibm.ws.naming.util.WsnInitCtx.lookup(WsnInitCtx.java:144)
at javax.naming.InitialContext.lookup(InitialContext.java:361)
at com.ibm.ejs.j2c.RALifeCycleManagerImpl.activateEndpoint(RALifeCycleManagerImpl.java:1248)
... 54 more

Also I don't see any UTC to work with?? Where should I exactly look for starting my UTC??

Can anyone help??

Thanks,
Radhika.
 
ranger
Posts: 17347
11
Mac IntelliJ IDE Spring
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Report post to moderator
Radhika

Please post your question in a new thread, and in the Websphere's Forum (see the note at the top of this forum regarding vendor specific questions. You can find the Websphere's forum here:
https://coderanch.com/forums/f-46/Websphere

The thread you replied to is about 2 years old.

Thanks

Mark
 
    Bookmark Topic Watch Topic
  • New Topic