My entity beans with bean-managed persistence sometimes get a "connection
closed" exception. This doesn't happen with every request, but it does happen
reasonably frequently if I try to stress-test the program. The beans query the
JNDI context for a DataSource, then do the usual JDBC to open a connection,
execute a query, and then close the JDBC connection. The confusing thing to me
is that the closed connection exception does not happen with every request.
(Could this be related to connection pooling?) A stack trace is shown below. Any
ideas?

Details: Orion 1.1.9, JDK1.3.0, NT4, Inetsoftware's JDBC driver talking to
MSSQL7

javax.transaction.xa.XAException: The connection was closed
        at com.evermind.sql.al.prepare(JAX)
        at com.evermind.server.f8.g3(JAX)
        at com.evermind.server.ApplicationServerTransaction.commit(JAX)
        at com.evermind.server.ApplicationServerTransaction.end(JAX)
        at
StatusEjbHome_EntityHomeWrapper10.findByPrimaryKey(StatusEjbHome_EntityHomeWrapper10.java:273)

        at com.lycos.ni.task.ejb.StatusEjb.findByPrimaryKey(StatusEjb.java)
        at
com.lycos.ni.task.request.ui.ViewTaskUIRequest.handleRequest(ViewTaskUIRequest.java)

        at
com.lycos.ni.task.request.RequestHandler.handleRequest(RequestHandler.java)
        at
com.lycos.ni.task.request.ui.UIRequestHandler.handleRequest(UIRequestHandler.java)

        at
com.lycos.ni.task.request.DispatcherServlet.handleRequest(DispatcherServlet.java)

        at com.lycos.ni.task.request.TaskServlet.doRequest(TaskServlet.java)
        at com.lycos.ni.task.request.TaskServlet.doGet(TaskServlet.java)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java)
        at com.evermind.server.http.dg.o2(JAX)
        at com.evermind.server.http.dg.forward(JAX)
        at com.evermind.server.http.dp.o8(JAX)
        at com.evermind.server.http.dp.o7(JAX)
        at com.evermind.util.e.run(JAX)



Reply via email to