• Post Reply 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

Advanced JNDI/WSAD question.

 
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Ok guys, I have been pulling my hair out on this one. Just a quick prelude to the configuration of my app:

2 WSAD workspaces open.
Each workspace has it's own server configuration. So there are a total of 2 servers, let's just call them server1 and server2.

Ok now the problem:
I have created a new EJB service that allows for applications to report on the status of a process. Currently, this service is running in server1 of workspace1. There is an application running in workspace2 on server2, that needs to make use of the status service remotely. In other words, the application in server2 is acting as a client for the service provided in server1.

I am having trouble locating the service in the JNDI namespace. When I run the dumpnamespace utility, I can see that the service is bound to the namespace. I am explicitly specifying the ORB port of server1 when I construct my InitialContext. To no avail...

Below is my initial context code:

Properties props = new Properties();
props.put(
Context.INITIAL_CONTEXT_FACTORY,
"com.ibm.websphere.naming.WsnInitialContextFactory");

//TODO externalize the URL!!!
String url = "corbaloc:iiop:localhost2:2809";
props.put(Context.PROVIDER_URL, url);

InitialContext ctx = new InitialContext(props);
NamingEnumeration ne = ctx.listBindings("thisNode/node/servers/server1/ejb/xxx/xxx/xx/xxxx");
while(ne.hasMoreElements()){

Object obj = ne.next();
System.out.println(obj.toString());
}
return ctx;

It seems that WSAD is ignoring the port, because the only resouces I see when I traverse the namespace are the ones local to the workspace. I am pretty sure that I would be able to see the service bound when I move the app to the WAS environment, because of the federated namepsace. However, I want to be able to test locally. Is this a limitation of WSAD or am I missing some configuration?? Anyhelp, would be greatly appreciated.

Thanks.

Roy
 
ranger
Posts: 17347
11
Mac IntelliJ IDE Spring
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
"Roy Rogers"

Please click the My Profile link above and change your display name to meet the JavaRanch Naming policy of using your real first and real last names.

Thanks

Mark
 
Paddy spent all of his days in the O'Furniture back yard with this tiny ad:
a bit of art, as a gift, the permaculture playing cards
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic