PLSSS help me solving my problem:
Ich wrote a small app which connects to a EJB which is deployed on a websphere application server.
The small app can be executed with parameter..
i included all needed IBM jars ..XXorb.jar etc.. so i dont get a classnotfound exception any more. now i get the following error:
-----------------------------------------------------------------------------------------------------------------
Using: iiop://10.14.16.13:20505, com.ibm.websphere.naming.WsnInitialContextFactory
javax.naming.ServiceUnavailableException: A communication failure occurred while attempting to obtain an initial context using the provider url: "iiop://10.14.16.13:20505". Make sure that the host and port information is correct and that the server identified by the provider url is a running name server. If no port number is specified, the default port number 2809 is used. Other possible causes include the network environment or workstation network configuration. [Root exception is org.omg.CORBA.TRANSIENT: java.net.ConnectException: Connection timed out: connect:host=10.14.16.13,port=20505 vmcid: 0x4942f000 minor code: 3586 completed: No]
at com.ibm.ws.naming.util.WsnInitCtxFactory.mapInitialReferenceFailure(WsnInitCtxFactory.java:1824)
at com.ibm.ws.naming.util.WsnInitCtxFactory.mergeWsnNSProperties(WsnInitCtxFactory.java:1107)
at com.ibm.ws.naming.util.WsnInitCtxFactory.getRootContextFromServer(WsnInitCtxFactory.java:676)
at com.ibm.ws.naming.util.WsnInitCtxFactory.getRootJndiContext(WsnInitCtxFactory.java:604)
at com.ibm.ws.naming.util.WsnInitCtxFactory.getInitialContextInternal(WsnInitCtxFactory.java:478)
at com.ibm.ws.naming.util.WsnInitCtx.getContext(WsnInitCtx.java:102)
at com.ibm.ws.naming.util.WsnInitCtx.getContextIfNull(WsnInitCtx.java:408)
at com.ibm.ws.naming.util.WsnInitCtx.lookup(WsnInitCtx.java:131)
at javax.naming.InitialContext.lookup(InitialContext.java:351)
at AdminWorkstationExample.getHomeInterface(AdminWorkstationExample.java:545)
at AdminWorkstationExample.login(AdminWorkstationExample.java:450)
at AdminWorkstationExample.main(AdminWorkstationExample.java:58)
Caused by: org.omg.CORBA.TRANSIENT: java.net.ConnectException: Connection timed out: connect:host=10.14.16.13,port=20505 vmcid: 0x4942f000 minor code: 3586 completed: No
at com.ibm.CORBA.transport.TransportConnectionBase.connect(TransportConnectionBase.java:451)
at com.ibm.rmi.transport.TCPTransport.getConnection(TCPTransport.java:182)
at com.ibm.rmi.iiop.TransportManager.get(TransportManager.java:81)
at com.ibm.rmi.iiop.GIOPImpl.getConnection(GIOPImpl.java:86)
at com.ibm.rmi.iiop.GIOPImpl.locate(GIOPImpl.java:184)
at com.ibm.rmi.corba.Corbaloc.locateUsingINS(Corbaloc.java:306)
at com.ibm.rmi.corba.Corbaloc.resolve(Corbaloc.java:377)
at com.ibm.rmi.corba.ORB.objectURLToObject(ORB.java:3960)
at com.ibm.CORBA.iiop.ORB.objectURLToObject(ORB.java:3429)
at com.ibm.rmi.corba.ORB.string_to_object(ORB.java:3846)
at com.ibm.ws.naming.util.WsnInitCtxFactory.stringToObject(WsnInitCtxFactory.java:1232)
at com.ibm.ws.naming.util.WsnInitCtxFactory.mergeWsnNSProperties(WsnInitCtxFactory.java:1083)
... 10 more
Caused by: java.net.ConnectException: Connection timed out: connect
at java.net.PlainSocketImpl.socketConnect(Native Method)
at java.net.PlainSocketImpl.doConnect(PlainSocketImpl.java:333)
at java.net.PlainSocketImpl.connectToAddress(PlainSocketImpl.java:195)
at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:182)
at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:366)
at java.net.Socket.connect(Socket.java:507)
at com.ibm.rmi.transport.TCPTransportConnection.createSocket(TCPTransportConnection.java:175)
at com.ibm.rmi.transport.TCPTransportConnection.createSocket(TCPTransportConnection.java:188)
at com.ibm.CORBA.transport.TransportConnectionBase.connect(TransportConnectionBase.java:375)
... 21 more
java.lang.NullPointerException
at AdminWorkstationExample.login(AdminWorkstationExample.java:451)
at AdminWorkstationExample.main(AdminWorkstationExample.java:58)
----------------------------------------------------------------------------------------------------
Make sure that you are connecting to the server's bootstrap port (default is 2809).
Hope this helps,
Andy