Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

EJB Home lookup failure: Attempt to sendMsg using a closed connection

0 views
Skip to first unread message

Jim Clark

unread,
Sep 27, 2001, 10:48:24 AM9/27/01
to
We have an EJB home factory that we're having an intermittent problem with
when we retrieve EJB home objects from a remote server (WebLogic to WebLogic
connection). It is very difficult to reproduce, but overtime we're able to
do so. We are not running in a clustered environment. However, the lookup is
failing when trying to find EJBs in a remote server, not local lookups.
Below is the exception that is occurring. We're using WLS 6.0 SP1, Solaris
2.7 , JVM 1.3.1

The only solution I've seen is to make sure the context object is closed,
which we're doing.

Any help would be appreciated.
Jim

2001-09-25 11:52:29,574 [ExecuteThread: '10' for queue: 'default'] ERROR
CoreComponents -com.idea.util.ejb.util.EJBHomeFactory getEJBHome:
javax.naming.CommunicationException [Root exception is
java.rmi.ConnectException: Attempt to sendMsg using a closed connection]
javax.naming.CommunicationException. Root exception is
java.rmi.ConnectException: Attempt to sendMsg using a closed connection
at
weblogic.rmi.internal.AbstractOutboundRequest.sendReceive(AbstractOutboundRe
quest.java:90)
at
weblogic.rmi.cluster.ReplicaAwareRemoteRef.invoke(ReplicaAwareRemoteRef.java
:247)
at
weblogic.rmi.cluster.ReplicaAwareRemoteRef.invoke(ReplicaAwareRemoteRef.java
:225)
at
weblogic.jndi.internal.ServerNamingNode_WLStub.lookup(ServerNamingNode_WLStu
b.java:121)
at
weblogic.jndi.internal.WLContextImpl.lookup(WLContextImpl.java:323)
at javax.naming.InitialContext.lookup(InitialContext.java:350)
at
com.idea.util.ejb.util.EJBHomeFactory.getEJBHome(EJBHomeFactory.java:349)
at
com.idea.util.ejb.util.EJBHomeFactory.getHomeInterface(EJBHomeFactory.java:2
62)
at
com.frontier.ovm.util.ManagerHelper.getManager(ManagerHelper.java:172)
at
com.frontier.ovm.util.ManagerHelper.getEPNDocumentMgr(ManagerHelper.java:124
)
at
com.frontier.ovm.requesthandler.UploadDocumentsHandler.saveFormBean(UploadDo
cumentsHandler.java:344)
at
com.frontier.requestprocessor.servlet.DispatcherServlet.generateWorker(Dispa
tcherServlet.java:520)
at
com.frontier.requestprocessor.servlet.DispatcherServlet.service(DispatcherSe
rvlet.java:231)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at
weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java
:213)
at
weblogic.servlet.internal.WebAppServletContext.invokeServlet(WebAppServletCo
ntext.java:1265)
at
weblogic.servlet.internal.ServletRequestImpl.execute(ServletRequestImpl.java
:1622)
at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:137)


protected EJBHome getEJBHome (String lookupName, String serverName) throws
NamingException {

Hashtable props = null;
try {
props = getAppServerProperties (serverName);
} catch (Exception e) {
cat.warn ("An error occured gettting the properties for the server " +
serverName);
throw new NamingException (e.toString ());
}
Context ctx = null;
EJBHome home = null;
try {
ctx = new InitialContext(props);
home = (EJBHome) ctx.lookup(lookupName);
} catch ( javax.naming.NamingException ne ) {
cat.error ( ne );
ne.printStackTrace();
throw (ne);
} finally {
try {
ctx.close();
} catch (Exception e) {
cat.debug ("Couldn't close the context! " + e.toString ());
}
}
return home;
}

0 new messages