我用weblogic7和jbuilder9写了一个EntityBean,部署也成功了,但是运行client,抛出如下异常:
java.rmi.RemoteException: EJB Exception:; nested exception is:
java.sql.SQLException: Cannot obtain connection after 30 seconds. , Exception = Access not allowed
java.sql.SQLException: Cannot obtain connection after 30 seconds. , Exception = Access not allowed
at weblogic.jdbc.jts.Connection.wrapAndThrowSQLException(Connection.java:694)
at weblogic.jdbc.jts.Connection.getOrCreateConnection(Connection.java:616)
at weblogic.jdbc.jts.Connection.prepareStatement(Connection.java:131)
at weblogic.jdbc.rmi.internal.ConnectionImpl.prepareStatement(ConnectionImpl.java:139)
at weblogic.jdbc.rmi.SerialConnection.prepareStatement(SerialConnection.java:92)
at com.lon.j2ee.ejb.cmp.PersonBean_vjvtzf__WebLogic_CMP_RDBMS.__WL_create(PersonBean_vjvtzf__WebLogic_CMP_RDBMS.java:1158)
at com.lon.j2ee.ejb.cmp.PersonBean_vjvtzf__WebLogic_CMP_RDBMS.ejbPostCreate(PersonBean_vjvtzf__WebLogic_CMP_RDBMS.java:1085)
at java.lang.reflect.Method.invoke(Native Method)
at weblogic.ejb20.manager.DBManager.create(DBManager.java:959)
at weblogic.ejb20.manager.DBManager.remoteCreate(DBManager.java:833)
at weblogic.ejb20.internal.EntityEJBHome.create(EntityEJBHome.java:246)
at com.lon.j2ee.ejb.cmp.PersonBean_vjvtzf_HomeImpl.create(PersonBean_vjvtzf_HomeImpl.java:77)
at com.lon.j2ee.ejb.cmp.PersonBean_vjvtzf_HomeImpl_WLSkel.invoke(Unknown Source)
at weblogic.rmi.internal.BasicServerRef.invoke(BasicServerRef.java:362)
at weblogic.rmi.cluster.ReplicaAwareServerRef.invoke(ReplicaAwareServerRef.java:114)
at weblogic.rmi.internal.BasicServerRef$1.run(BasicServerRef.java:313)
at weblogic.security.service.SecurityServiceManager.runAs(SecurityServiceManager.java:785)
at weblogic.rmi.internal.BasicServerRef.handleRequest(BasicServerRef.java:308)
at weblogic.rmi.internal.BasicExecuteRequest.execute(BasicExecuteRequest.java:30)
at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:153)
at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:134)
End server side stack trace
; nested exception is:
java.sql.SQLException: Cannot obtain connection after 30 seconds. , Exception = Access not allowed
连接池和数据源都配了,我用同样的用户名和密码(数据库)直接用jdbc能操作数据库,请大家瞧瞧,谢谢!!!
--转自
该贴由koei123转至本版2015-6-2 9:10:24