Win a copy of Functional Reactive Programming this week in the Other Languages forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Connecting to J2EE Server installed in Solaris

 
Issac Abbas
Greenhorn
Posts: 10
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
am facing a problem when i try to connect to a J2EE Server running on
Solaris Machine. I have a JMS Client which publishes message to a
'topic' in the Server. The Client is running on NT machine. I tried in
so many way still i am getting the CommunicationException.
The message is:
JNDI lookup failed: javax.naming.CommunicationException: Can't find
SerialContext
tProvider
NT machine also has the J2EE installed. I tried by changing the
'orb.properites' in the client machine to point to J2EE Server running
in the Solaris machine. I also tried by setting the sytem properties
through commad line as follows
java -Dorg.omg.CORBA.ORBInitialHost= host name
-Dorg.omg.CORBA.ORBInitialPort=1050 Client
In both cases i am getting the same Exception.
The same case works fine if i try to connect to J2EE Server running on
another NT Machine ( instead of Solaris ).
Any kind of help in this regard is appreciated. contact me in issac.abbas@wipro.com
 
Thomas Paul
mister krabs
Ranch Hand
Posts: 13974
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Please note that JavaRanch has a naming standard. We require that you use your real first name - space - real last name as your display name.
Thanks.
 
Thomas Paul
mister krabs
Ranch Hand
Posts: 13974
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Could you show the code you are using to lookup on the Solaris server?
 
Issac Abbas
Greenhorn
Posts: 10
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
There is no change in the code for connecting to NT or Solaris. It works with fine when i try to connect to J2EE Server in NT from a NT Client. It also works fine for connecting to a J2EE Server in Solaris from Solaris Client. Only when i do cross-platform connection, the problem arises. Here is the code which i used to connect.
try
{
jndiContext = new InitialContext();
topicConnectionFactory = (TopicConnectionFactory)
jndiContext.lookup("TopicConnectionFactory");
topic = (Topic) jndiContext.lookup(topicName);
}
catch (NamingException e)
{
System.out.println("JNDI lookup failed: " +e.toString());
System.exit(1);
}
try
{
topicConnection = topicConnectionFactory.createTopicConnection();
topicSession = topicConnection.createTopicSession(false,Session.AUTO_ACKNOWLEDGE);
topicPublisher = topicSession.createPublisher(topic);
message = topicSession.createTextMessage();
topicPublisher.publish(message);
}
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic