CannotInstantiateObjectException
dear frds.
i got following error when using ibm db2 datasource 5,(working good with data source 4)
CannotInstantiateObjectException: Exception occurred while the JNDI NamingManager was processing a javax.naming.Reference object. [Root exception is java.lang.Exception: Attempted to use a 5.0 DataSource outside of a 2.3 servlet]
i also got the same exception , while migrating the application of webspehre 4.0.7 to 5.1 in WSAD environment.
the exception was :
java.lang.Exception: Attempted to use a 5.0 DataSource outside of a 2.3 servlet
at com.ibm.ejs.j2c.ConnectionFactoryBuilderImpl.validServlet(ConnectionFactoryBuilderImpl.java:2162)
at com.ibm.ejs.j2c.ConnectionFactoryBuilderImpl.getCMConfigData(ConnectionFactoryBuilderImpl.java:1649)
at com.ibm.ejs.j2c.ConnectionFactoryBuilderImpl.getObjectInstance(ConnectionFactoryBuilderImpl.java:1018)
at javax.naming.spi.NamingManager.getObjectInstance(NamingManager.java:313)
i do the same thing i just change the web.xml accordingly and it works.
thanks for the great help.
Similar Messages
-
WSAD 5, xerces, datasource and classcastexception issue
I am running into an issue trying to run my code once I upgraded from WDAD 5.0 to WSAD 5.01. I am getting the error below when I try and connect to my DataSource. This all was working fine before I upgraded. It looks like an issue with the xerces.jar file because if I take out the JAXP stuff in the xerces.jar file I work fine. But I need the JAXP stuff because I am doing messaging. Anyone have any ideas?
[5/22/03 7:02:59:848 CDT] 2ec4c80 SystemOut O 2003.05.22 07:02:59.848--ServerSession(426724481)--Thread[asyncDelivery0,5,main]--Connection(47762586)--TopLink, version:TopLink - 9.0.3 (Build 423)
2003.05.22 07:02:59.848--ServerSession(426724481)--Thread[asyncDelivery0,5,main]--Connection(47762586)--connecting(DatabaseLogin(
platform => DB2Platform
user name => "ou79ecm"
datasource name => "jdbc/DB239DataSource"
[5/22/03 7:03:00:118 CDT] 2ec4c80 ConnectionFac I J2CA0122I: Resource reference jdbc/DB239DataSource could not be located, so default values of the following are used: [Resource-ref settings]
res-auth: 1 (APPLICATION)
res-isolation-level: 0 (TRANSACTION_NONE)
res-sharing-scope: true (SHAREABLE)
res-resolution-control: 999 (undefined)
[Other attributes]
isCMP1_x: false (not CMP1.x)
isJMS: false (not JMS)
[5/22/03 7:03:01:160 CDT] 2ec4c80 ConnectionFac E J2CA0009E: An exception occurred while trying to instantiate the ManagedConnectionFactory class com.ibm.ws.rsadapter.spi.WSManagedConnectionFactoryImpl used by resource jdbc/DB239DataSource : java.lang.ClassCastException: org.apache.xerces.jaxp.SAXParserFactoryImpl
at javax.xml.parsers.SAXParserFactory.newInstance(Unknown Source)
at com.ibm.ejs.j2c.XMLReader.validate(XMLReader.java:673)
at com.ibm.ejs.j2c.XMLReader.init(XMLReader.java:241)
at com.ibm.ejs.j2c.XMLReader.<init>(XMLReader.java:165)
at com.ibm.ejs.j2c.ConnectorRuntime.getJ2C_Properties(ConnectorRuntime.java:341)
at com.ibm.ejs.j2c.poolmanager.PoolManager.<init>(PoolManager.java:541)
at com.ibm.ejs.j2c.ConnectionFactoryBuilderImpl.createCFD_Common(ConnectionFactoryBuilderImpl.java:699)
at com.ibm.ejs.j2c.ConnectionFactoryBuilderImpl.createConnectionFactoryDetails(ConnectionFactoryBuilderImpl.java:417)
at com.ibm.ejs.j2c.ConnectionFactoryBuilderImpl.getObjectInstance(ConnectionFactoryBuilderImpl.java:1400)
at javax.naming.spi.NamingManager.getObjectInstance(NamingManager.java:313)
at com.ibm.ws.naming.util.Helpers.processSerializedObjectForLookup(Helpers.java:884)
at com.ibm.ws.naming.jndicos.CNContextImpl.processResolveResults(CNContextImpl.java:1675)
at com.ibm.ws.naming.jndicos.CNContextImpl.doLookup(CNContextImpl.java:1538)
at com.ibm.ws.naming.jndicos.CNContextImpl.doLookup(CNContextImpl.java:1458)
at com.ibm.ws.naming.jndicos.CNContextImpl.lookup(CNContextImpl.java:1130)
at com.ibm.ws.naming.util.WsnInitCtx.lookup(WsnInitCtx.java:122)
at javax.naming.InitialContext.lookup(InitialContext.java:363)
at oracle.toplink.jndi.JNDIConnector.connect(Unknown Source)
at oracle.toplink.sessions.DatabaseLogin.connect(Unknown Source)
at oracle.toplink.internal.databaseaccess.DatabaseAccessor.connect(Unknown Source)
at oracle.toplink.internal.databaseaccess.DatabaseAccessor.connect(Unknown Source)
at oracle.toplink.threetier.ConnectionPool.buildConnection(Unknown Source)
at oracle.toplink.threetier.ConnectionPool.startUp(Unknown Source)
at oracle.toplink.threetier.ServerSession.connect(Unknown Source)
at oracle.toplink.publicinterface.DatabaseSession.login(Unknown Source)
at oracle.toplink.tools.sessionmanagement.SessionManager.getSession(Unknown Source)
at oracle.toplink.tools.sessionmanagement.SessionManager.getSession(Unknown Source)
at oracle.toplink.tools.sessionmanagement.SessionManager.getSession(Unknown Source)
at com.deere.jdc.toplink.ToplinkServerSessionFactory.getSession(ToplinkServerSessionFactory.java:121)
at com.deere.jdc.toplink.ToplinkServerSessionFactory.getClientSession(ToplinkServerSessionFactory.java:56)
at com.deere.jdc.component.rcts.dao.RCTSGateway.findDealerASMByDealerNumber(RCTSGateway.java:194)
at com.deere.jdc.component.rcts.service.RCTSService.getRCTSDealerASM(RCTSService.java:159)
at com.deere.jdc.component.rcts.adapter.SoapRCTSService.getRCTSDealerASM(SoapRCTSService.java:107)
at java.lang.reflect.Method.invoke(Native Method)
at com.deere.jdc.component.rcts.messaging.RCTSMessageHandler.invokeServiceMethod(RCTSMessageHandler.java:103)
at com.deere.jdc.component.rcts.messaging.RCTSMessageHandler.processMessage(RCTSMessageHandler.java:62)
at com.deere.jdc.mqseries.MQJMSMessageHandler.onMessage(MQJMSMessageHandler.java:122)
at com.ibm.mq.jms.MQQueueReceiver.receiveAsync(MQQueueReceiver.java:861)
at com.ibm.mq.jms.SessionAsyncHelper.run(SessionAsyncHelper.java:401)
at java.lang.Thread.run(Thread.java:513)
[5/22/03 7:03:01:310 CDT] 2ec4c80 ConnectionFac A J2CA0013I: An exception occurred while trying to create ManagedConnectionFactory for DB239DataSource : java.lang.ClassCastException: org.apache.xerces.jaxp.SAXParserFactoryImpl
at javax.xml.parsers.SAXParserFactory.newInstance(Unknown Source)
at com.ibm.ejs.j2c.XMLReader.validate(XMLReader.java:673)
at com.ibm.ejs.j2c.XMLReader.init(XMLReader.java:241)
at com.ibm.ejs.j2c.XMLReader.<init>(XMLReader.java:165)
at com.ibm.ejs.j2c.ConnectorRuntime.getJ2C_Properties(ConnectorRuntime.java:341)
at com.ibm.ejs.j2c.poolmanager.PoolManager.<init>(PoolManager.java:541)
at com.ibm.ejs.j2c.ConnectionFactoryBuilderImpl.createCFD_Common(ConnectionFactoryBuilderImpl.java:699)
at com.ibm.ejs.j2c.ConnectionFactoryBuilderImpl.createConnectionFactoryDetails(ConnectionFactoryBuilderImpl.java:417)
at com.ibm.ejs.j2c.ConnectionFactoryBuilderImpl.getObjectInstance(ConnectionFactoryBuilderImpl.java:1400)
at javax.naming.spi.NamingManager.getObjectInstance(NamingManager.java:313)
at com.ibm.ws.naming.util.Helpers.processSerializedObjectForLookup(Helpers.java:884)
at com.ibm.ws.naming.jndicos.CNContextImpl.processResolveResults(CNContextImpl.java:1675)
at com.ibm.ws.naming.jndicos.CNContextImpl.doLookup(CNContextImpl.java:1538)
at com.ibm.ws.naming.jndicos.CNContextImpl.doLookup(CNContextImpl.java:1458)
at com.ibm.ws.naming.jndicos.CNContextImpl.lookup(CNContextImpl.java:1130)
at com.ibm.ws.naming.util.WsnInitCtx.lookup(WsnInitCtx.java:122)
at javax.naming.InitialContext.lookup(InitialContext.java:363)
at oracle.toplink.jndi.JNDIConnector.connect(Unknown Source)
at oracle.toplink.sessions.DatabaseLogin.connect(Unknown Source)
at oracle.toplink.internal.databaseaccess.DatabaseAccessor.connect(Unknown Source)
at oracle.toplink.internal.databaseaccess.DatabaseAccessor.connect(Unknown Source)
at oracle.toplink.threetier.ConnectionPool.buildConnection(Unknown Source)
at oracle.toplink.threetier.ConnectionPool.startUp(Unknown Source)
at oracle.toplink.threetier.ServerSession.connect(Unknown Source)
at oracle.toplink.publicinterface.DatabaseSession.login(Unknown Source)
at oracle.toplink.tools.sessionmanagement.SessionManager.getSession(Unknown Source)
at oracle.toplink.tools.sessionmanagement.SessionManager.getSession(Unknown Source)
at oracle.toplink.tools.sessionmanagement.SessionManager.getSession(Unknown Source)
at com.deere.jdc.toplink.ToplinkServerSessionFactory.getSession(ToplinkServerSessionFactory.java:121)
at com.deere.jdc.toplink.ToplinkServerSessionFactory.getClientSession(ToplinkServerSessionFactory.java:56)
at com.deere.jdc.component.rcts.dao.RCTSGateway.findDealerASMByDealerNumber(RCTSGateway.java:194)
at com.deere.jdc.component.rcts.service.RCTSService.getRCTSDealerASM(RCTSService.java:159)
at com.deere.jdc.component.rcts.adapter.SoapRCTSService.getRCTSDealerASM(SoapRCTSService.java:107)
at java.lang.reflect.Method.invoke(Native Method)
at com.deere.jdc.component.rcts.messaging.RCTSMessageHandler.invokeServiceMethod(RCTSMessageHandler.java:103)
at com.deere.jdc.component.rcts.messaging.RCTSMessageHandler.processMessage(RCTSMessageHandler.java:62)
at com.deere.jdc.mqseries.MQJMSMessageHandler.onMessage(MQJMSMessageHandler.java:122)
at com.ibm.mq.jms.MQQueueReceiver.receiveAsync(MQQueueReceiver.java:861)
at com.ibm.mq.jms.SessionAsyncHelper.run(SessionAsyncHelper.java:401)
at java.lang.Thread.run(Thread.java:513)
[5/22/03 7:03:01:340 CDT] 2ec4c80 Helpers W NMSV0605W: A Reference object looked up from the context "localhost/nodes/localhost/servers/server1" with the name "jdbc/DB239DataSource" was sent to the JNDI Naming Manager and an exception resulted. Reference data follows:
Reference Factory Class Name: com.ibm.ejs.j2c.ConnectionFactoryBuilderImpl
Reference Factory Class Location URLs: <null>
Reference Class Name: DB239DataSource
Type: connectorName
Content: DB239DataSource
Type: classpath
Content: C:\Program Files\IBM\WebSphere Studio\runtimes\base_v5/lib/rsadapter.rar
Type: FactoryJndiName
Content: jdbc/DB239DataSource
Address Type: dd
AddressContents: ffffffac ffffffed 0 5 73 72 0 25 63 6f 6d 2e 69 62 6d 2e 65 6a 73 2e 6a 32 63 2e 52 65 73 6f 75 72 63 65 ...
Address Type: poolProps
AddressContents: ffffffac ffffffed 0 5 73 72 0 27 63 6f 6d 2e 69 62 6d 2e 65 6a 73 2e 6a 32 63 2e 43 6f 6e 6e 65 63 74 6f ...
Address Type: configProps
AddressContents: ffffffac ffffffed 0 5 73 72 0 23 63 6f 6d 2e 69 62 6d 2e 65 6a 73 2e 6a 32 63 2e 43 6f 6e 6e 65 63 74 6f ...
Address Type: dsProps
AddressContents: ffffffac ffffffed 0 5 73 72 0 14 6a 61 76 61 2e 75 74 69 6c 2e 50 72 6f 70 65 72 74 69 65 73 39 12 ffffffd0 7a ...
Address Type: mcfProps
AddressContents: ffffffac ffffffed 0 5 73 72 0 2d 63 6f 6d 2e 69 62 6d 2e 65 6a 73 2e 6a 32 63 2e 4d 61 6e 61 67 65 64 43 ...
Address Type: mbeanProps
AddressContents: ffffffac ffffffed 0 5 73 72 0 1a 63 6f 6d 2e 69 62 6d 2e 65 6a 73 2e 6a 32 63 2e 4d 42 65 61 6e 50 72 6f ...
Exception data follows:
java.lang.ClassCastException: org.apache.xerces.jaxp.SAXParserFactoryImpl
at javax.xml.parsers.SAXParserFactory.newInstance(Unknown Source)
at com.ibm.ejs.j2c.XMLReader.validate(XMLReader.java:673)
at com.ibm.ejs.j2c.XMLReader.init(XMLReader.java:241)
at com.ibm.ejs.j2c.XMLReader.<init>(XMLReader.java:165)
at com.ibm.ejs.j2c.ConnectorRuntime.getJ2C_Properties(ConnectorRuntime.java:341)
at com.ibm.ejs.j2c.poolmanager.PoolManager.<init>(PoolManager.java:541)
at com.ibm.ejs.j2c.ConnectionFactoryBuilderImpl.createCFD_Common(ConnectionFactoryBuilderImpl.java:699)
at com.ibm.ejs.j2c.ConnectionFactoryBuilderImpl.createConnectionFactoryDetails(ConnectionFactoryBuilderImpl.java:417)
at com.ibm.ejs.j2c.ConnectionFactoryBuilderImpl.getObjectInstance(ConnectionFactoryBuilderImpl.java:1400)
at javax.naming.spi.NamingManager.getObjectInstance(NamingManager.java:313)
at com.ibm.ws.naming.util.Helpers.processSerializedObjectForLookup(Helpers.java:884)
at com.ibm.ws.naming.jndicos.CNContextImpl.processResolveResults(CNContextImpl.java:1675)
at com.ibm.ws.naming.jndicos.CNContextImpl.doLookup(CNContextImpl.java:1538)
at com.ibm.ws.naming.jndicos.CNContextImpl.doLookup(CNContextImpl.java:1458)
at com.ibm.ws.naming.jndicos.CNContextImpl.lookup(CNContextImpl.java:1130)
at com.ibm.ws.naming.util.WsnInitCtx.lookup(WsnInitCtx.java:122)
at javax.naming.InitialContext.lookup(InitialContext.java:363)
at oracle.toplink.jndi.JNDIConnector.connect(Unknown Source)
at oracle.toplink.sessions.DatabaseLogin.connect(Unknown Source)
at oracle.toplink.internal.databaseaccess.DatabaseAccessor.connect(Unknown Source)
at oracle.toplink.internal.databaseaccess.DatabaseAccessor.connect(Unknown Source)
at oracle.toplink.threetier.ConnectionPool.buildConnection(Unknown Source)
at oracle.toplink.threetier.ConnectionPool.startUp(Unknown Source)
at oracle.toplink.threetier.ServerSession.connect(Unknown Source)
at oracle.toplink.publicinterface.DatabaseSession.login(Unknown Source)
at oracle.toplink.tools.sessionmanagement.SessionManager.getSession(Unknown Source)
at oracle.toplink.tools.sessionmanagement.SessionManager.getSession(Unknown Source)
at oracle.toplink.tools.sessionmanagement.SessionManager.getSession(Unknown Source)
at com.deere.jdc.toplink.ToplinkServerSessionFactory.getSession(ToplinkServerSessionFactory.java:121)
at com.deere.jdc.toplink.ToplinkServerSessionFactory.getClientSession(ToplinkServerSessionFactory.java:56)
at com.deere.jdc.component.rcts.dao.RCTSGateway.findDealerASMByDealerNumber(RCTSGateway.java:194)
at com.deere.jdc.component.rcts.service.RCTSService.getRCTSDealerASM(RCTSService.java:159)
at com.deere.jdc.component.rcts.adapter.SoapRCTSService.getRCTSDealerASM(SoapRCTSService.java:107)
at java.lang.reflect.Method.invoke(Native Method)
at com.deere.jdc.component.rcts.messaging.RCTSMessageHandler.invokeServiceMethod(RCTSMessageHandler.java:103)
at com.deere.jdc.component.rcts.messaging.RCTSMessageHandler.processMessage(RCTSMessageHandler.java:62)
at com.deere.jdc.mqseries.MQJMSMessageHandler.onMessage(MQJMSMessageHandler.java:122)
at com.ibm.mq.jms.MQQueueReceiver.receiveAsync(MQQueueReceiver.java:861)
at com.ibm.mq.jms.SessionAsyncHelper.run(SessionAsyncHelper.java:401)
at java.lang.Thread.run(Thread.java:513)
[5/22/03 7:03:01:891 CDT] 2ec4c80 Helpers W NMSV0610I: A NamingException is being thrown from a javax.naming.Context implementation. Details follow:
Context implementation: com.ibm.ws.naming.jndicos.CNContextImpl
Context method: lookup
Context name: localhost/nodes/localhost/servers/server1
Target name: jdbc/DB239DataSource
Other data:
Exception stack trace: com.ibm.websphere.naming.CannotInstantiateObjectException: Exception occurred while the JNDI NamingManager was processing a javax.naming.Reference object. Root exception is java.lang.ClassCastException: org.apache.xerces.jaxp.SAXParserFactoryImpl
at javax.xml.parsers.SAXParserFactory.newInstance(Unknown Source)
at com.ibm.ejs.j2c.XMLReader.validate(XMLReader.java:673)
at com.ibm.ejs.j2c.XMLReader.init(XMLReader.java:241)
at com.ibm.ejs.j2c.XMLReader.<init>(XMLReader.java:165)
at com.ibm.ejs.j2c.ConnectorRuntime.getJ2C_Properties(ConnectorRuntime.java:341)
at com.ibm.ejs.j2c.poolmanager.PoolManager.<init>(PoolManager.java:541)
at com.ibm.ejs.j2c.ConnectionFactoryBuilderImpl.createCFD_Common(ConnectionFactoryBuilderImpl.java:699)
at com.ibm.ejs.j2c.ConnectionFactoryBuilderImpl.createConnectionFactoryDetails(ConnectionFactoryBuilderImpl.java:417)
at com.ibm.ejs.j2c.ConnectionFactoryBuilderImpl.getObjectInstance(ConnectionFactoryBuilderImpl.java:1400)
at javax.naming.spi.NamingManager.getObjectInstance(NamingManager.java:313)
at com.ibm.ws.naming.util.Helpers.processSerializedObjectForLookup(Helpers.java:884)
at com.ibm.ws.naming.jndicos.CNContextImpl.processResolveResults(CNContextImpl.java:1675)
at com.ibm.ws.naming.jndicos.CNContextImpl.doLookup(CNContextImpl.java:1538)
at com.ibm.ws.naming.jndicos.CNContextImpl.doLookup(CNContextImpl.java:1458)
at com.ibm.ws.naming.jndicos.CNContextImpl.lookup(CNContextImpl.java:1130)
at com.ibm.ws.naming.util.WsnInitCtx.lookup(WsnInitCtx.java:122)
at javax.naming.InitialContext.lookup(InitialContext.java:363)
at oracle.toplink.jndi.JNDIConnector.connect(Unknown Source)
at oracle.toplink.sessions.DatabaseLogin.connect(Unknown Source)
at oracle.toplink.internal.databaseaccess.DatabaseAccessor.connect(Unknown Source)
at oracle.toplink.internal.databaseaccess.DatabaseAccessor.connect(Unknown Source)
at oracle.toplink.threetier.ConnectionPool.buildConnection(Unknown Source)
at oracle.toplink.threetier.ConnectionPool.startUp(Unknown Source)
at oracle.toplink.threetier.ServerSession.connect(Unknown Source)
at oracle.toplink.publicinterface.DatabaseSession.login(Unknown Source)
at oracle.toplink.tools.sessionmanagement.SessionManager.getSession(Unknown Source)
at oracle.toplink.tools.sessionmanagement.SessionManager.getSession(Unknown Source)
at oracle.toplink.tools.sessionmanagement.SessionManager.getSession(Unknown Source)
at com.deere.jdc.toplink.ToplinkServerSessionFactory.getSession(ToplinkServerSessionFactory.java:121)
at com.deere.jdc.toplink.ToplinkServerSessionFactory.getClientSession(ToplinkServerSessionFactory.java:56)
at com.deere.jdc.component.rcts.dao.RCTSGateway.findDealerASMByDealerNumber(RCTSGateway.java:194)
at com.deere.jdc.component.rcts.service.RCTSService.getRCTSDealerASM(RCTSService.java:159)
at com.deere.jdc.component.rcts.adapter.SoapRCTSService.getRCTSDealerASM(SoapRCTSService.java:107)
at java.lang.reflect.Method.invoke(Native Method)
at com.deere.jdc.component.rcts.messaging.RCTSMessageHandler.invokeServiceMethod(RCTSMessageHandler.java:103)
at com.deere.jdc.component.rcts.messaging.RCTSMessageHandler.processMessage(RCTSMessageHandler.java:62)
at com.deere.jdc.mqseries.MQJMSMessageHandler.onMessage(MQJMSMessageHandler.java:122)
at com.ibm.mq.jms.MQQueueReceiver.receiveAsync(MQQueueReceiver.java:861)
at com.ibm.mq.jms.SessionAsyncHelper.run(SessionAsyncHelper.java:401)
at java.lang.Thread.run(Thread.java:513)
2003.05.22 07:03:02.111--ServerSession(426724481)--Thread[asyncDelivery0,5,main]--EXCEPTION [TOPLINK-7060] (TopLink - 9.0.3 (Build 423)): oracle.toplink.exceptions.ValidationException
EXCEPTION DESCRIPTION: Cannot acquire data source [jdbc/DB239DataSource].
INTERNAL EXCEPTION: com.ibm.websphere.naming.CannotInstantiateObjectException: Exception occurred while the JNDI NamingManager was processing a javax.naming.Reference object. [Root exception is java.lang.ClassCastException: org.apache.xerces.jaxp.SAXParserFactoryImpl]LOCAL EXCEPTION STACK:
EXCEPTION [TOPLINK-7060] (TopLink - 9.0.3 (Build 423)): oracle.toplink.exceptions.ValidationException
EXCEPTION DESCRIPTION: Cannot acquire data source [jdbc/DB239DataSource].
INTERNAL EXCEPTION: com.ibm.websphere.naming.CannotInstantiateObjectException: Exception occurred while the JNDI NamingManager was processing a javax.naming.Reference object. [Root exception is java.lang.ClassCastException: org.apache.xerces.jaxp.SAXParserFactoryImpl]
at oracle.toplink.exceptions.ValidationException.cannotAcquireDataSource(Unknown Source)
at oracle.toplink.jndi.JNDIConnector.connect(Unknown Source)
at oracle.toplink.sessions.DatabaseLogin.connect(Unknown Source)
at oracle.toplink.internal.databaseaccess.DatabaseAccessor.connect(Unknown Source)
at oracle.toplink.internal.databaseaccess.DatabaseAccessor.connect(Unknown Source)
at oracle.toplink.threetier.ConnectionPool.buildConnection(Unknown Source)
at oracle.toplink.threetier.ConnectionPool.startUp(Unknown Source)
at oracle.toplink.threetier.ServerSession.connect(Unknown Source)
at oracle.toplink.publicinterface.DatabaseSession.login(Unknown Source)
at oracle.toplink.tools.sessionmanagement.SessionManager.getSession(Unknown Source)
at oracle.toplink.tools.sessionmanagement.SessionManager.getSession(Unknown Source)
at oracle.toplink.tools.sessionmanagement.SessionManager.getSession(Unknown Source)
at com.deere.jdc.toplink.ToplinkServerSessionFactory.getSession(ToplinkServerSessionFactory.java:121)
at com.deere.jdc.toplink.ToplinkServerSessionFactory.getClientSession(ToplinkServerSessionFactory.java:56)
at com.deere.jdc.component.rcts.dao.RCTSGateway.findDealerASMByDealerNumber(RCTSGateway.java:194)
at com.deere.jdc.component.rcts.service.RCTSService.getRCTSDealerASM(RCTSService.java:159)
at com.deere.jdc.component.rcts.adapter.SoapRCTSService.getRCTSDealerASM(SoapRCTSService.java:107)
at java.lang.reflect.Method.invoke(Native Method)
at com.deere.jdc.component.rcts.messaging.RCTSMessageHandler.invokeServiceMethod(RCTSMessageHandler.java:103)
at com.deere.jdc.component.rcts.messaging.RCTSMessageHandler.processMessage(RCTSMessageHandler.java:62)
at com.deere.jdc.mqseries.MQJMSMessageHandler.onMessage(MQJMSMessageHandler.java:122)
at com.ibm.mq.jms.MQQueueReceiver.receiveAsync(MQQueueReceiver.java:861)
at com.ibm.mq.jms.SessionAsyncHelper.run(SessionAsyncHelper.java:401)
at java.lang.Thread.run(Thread.java:513)
INTERNAL EXCEPTION STACK:
com.ibm.websphere.naming.CannotInstantiateObjectException: Exception occurred while the JNDI NamingManager was processing a javax.naming.Reference object. Root exception is java.lang.ClassCastException: org.apache.xerces.jaxp.SAXParserFactoryImpl
at javax.xml.parsers.SAXParserFactory.newInstance(Unknown Source)
at com.ibm.ejs.j2c.XMLReader.validate(XMLReader.java:673)
at com.ibm.ejs.j2c.XMLReader.init(XMLReader.java:241)
at com.ibm.ejs.j2c.XMLReader.<init>(XMLReader.java:165)
at com.ibm.ejs.j2c.ConnectorRuntime.getJ2C_Properties(ConnectorRuntime.java:341)
at com.ibm.ejs.j2c.poolmanager.PoolManager.<init>(PoolManager.java:541)
at com.ibm.ejs.j2c.ConnectionFactoryBuilderImpl.createCFD_Common(ConnectionFactoryBuilderImpl.java:699)
at com.ibm.ejs.j2c.ConnectionFactoryBuilderImpl.createConnectionFactoryDetails(ConnectionFactoryBuilderImpl.java:417)
at com.ibm.ejs.j2c.ConnectionFactoryBuilderImpl.getObjectInstance(ConnectionFactoryBuilderImpl.java:1400)
at javax.naming.spi.NamingManager.getObjectInstance(NamingManager.java:313)
at com.ibm.ws.naming.util.Helpers.processSerializedObjectForLookup(Helpers.java:884)
at com.ibm.ws.naming.jndicos.CNContextImpl.processResolveResults(CNContextImpl.java:1675)
at com.ibm.ws.naming.jndicos.CNContextImpl.doLookup(CNContextImpl.java:1538)
at com.ibm.ws.naming.jndicos.CNContextImpl.doLookup(CNContextImpl.java:1458)
at com.ibm.ws.naming.jndicos.CNContextImpl.lookup(CNContextImpl.java:1130)
at com.ibm.ws.naming.util.WsnInitCtx.lookup(WsnInitCtx.java:122)
at javax.naming.InitialContext.lookup(InitialContext.java:363)
at oracle.toplink.jndi.JNDIConnector.connect(Unknown Source)
at oracle.toplink.sessions.DatabaseLogin.connect(Unknown Source)
at oracle.toplink.internal.databaseaccess.DatabaseAccessor.connect(Unknown Source)
at oracle.toplink.internal.databaseaccess.DatabaseAccessor.connect(Unknown Source)
at oracle.toplink.threetier.ConnectionPool.buildConnection(Unknown Source)
at oracle.toplink.threetier.ConnectionPool.startUp(Unknown Source)
at oracle.toplink.threetier.ServerSession.connect(Unknown Source)
at oracle.toplink.publicinterface.DatabaseSession.login(Unknown Source)
at oracle.toplink.tools.sessionmanagement.SessionManager.getSession(Unknown Source)
at oracle.toplink.tools.sessionmanagement.SessionManager.getSession(Unknown Source)
at oracle.toplink.tools.sessionmanagement.SessionManager.getSession(Unknown Source)
at com.deere.jdc.toplink.ToplinkServerSessionFactory.getSession(ToplinkServerSessionFactory.java:121)
at com.deere.jdc.toplink.ToplinkServerSessionFactory.getClientSession(ToplinkServerSessionFactory.java:56)
at com.deere.jdc.component.rcts.dao.RCTSGateway.findDealerASMByDealerNumber(RCTSGateway.java:194)
at com.deere.jdc.component.rcts.service.RCTSService.getRCTSDealerASM(RCTSService.java:159)
at com.deere.jdc.component.rcts.adapter.SoapRCTSService.getRCTSDealerASM(SoapRCTSService.java:107)
at java.lang.reflect.Method.invoke(Native Method)
at com.deere.jdc.component.rcts.messaging.RCTSMessageHandler.invokeServiceMethod(RCTSMessageHandler.java:103)
at com.deere.jdc.component.rcts.messaging.RCTSMessageHandler.processMessage(RCTSMessageHandler.java:62)
at com.deere.jdc.mqseries.MQJMSMessageHandler.onMessage(MQJMSMessageHandler.java:122)
at com.ibm.mq.jms.MQQueueReceiver.receiveAsync(MQQueueReceiver.java:861)
at com.ibm.mq.jms.SessionAsyncHelper.run(SessionAsyncHelper.java:401)
at java.lang.Thread.run(Thread.java:513)This looks like a classPath issue.check ur runtime
class path and make sure xerces is before any other
parser(xml4j /oracleParser)
vasanth -
Problem in deploy a entitiy bean in WAS5.0 (URGENT)
ANYONE Pl Give u r suggestions
I am trying to deploy a entitiy bean in WebSphere Application Version 5. I have followed all the steps provided by the User Interface. I am connecting to Oracle 9i driver. I am trying to validate and install the ear. the validation and installation are happenning properly. but when I try to start the services, it is failing to start with the following exception:
com.ibm.websphere.naming.CannotInstantiateObjectException: Exception occurred while the JNDI NamingManager was processing a javax.naming.Reference object. Root exception is javax.naming.NamingException: Failed to lookup the object configured with a null or empty name
at com.ibm.ws.naming.util.IndirectJndiLookupObjectFactory$1.run(IndirectJndiLookupObjectFactory.java:145)
at java.security.AccessController.doPrivileged(Native Method)
at com.ibm.ws.naming.util.IndirectJndiLookupObjectFactory.getObjectInstance(IndirectJndiLookupObjectFactory.java:92)
at javax.naming.spi.NamingManager.getObjectInstance(NamingManager.java:313)
at com.ibm.ws.naming.util.Helpers.processSerializedObjectForLookup(Helpers.java:884)
at com.ibm.ws.naming.urlbase.UrlContextHelper.processBoundObjectForLookup(UrlContextHelper.java:135)
at com.ibm.ws.naming.urlbase.UrlContext.lookup(UrlContext.java:1227)
at com.ibm.ws.naming.urlbase.UrlContext.lookup(UrlContext.java:1203)
at com.ibm.ws.naming.urlbase.UrlContext.lookup(UrlContext.java:1257)
at javax.naming.InitialContext.lookup(InitialContext.java:359)
at com.ibm.ws.ejbpersistence.beanextensions.ConcreteBeanClassExtensionImpl.lookup(ConcreteBeanClassExtensionImpl.java:727)
at com.ibm.ws.ejbpersistence.beanextensions.ConcreteBeanClassExtensionImpl.getConnectionFactory(ConcreteBeanClassExtensionImpl.java:260)
at com.ibm.ws.ejbpersistence.beanextensions.PMModuleCookieImpl.beanInstall(PMModuleCookieImpl.java:98)
at com.ibm.ws.ejbpersistence.beanextensions.PersistenceManagerImpl.beanInstall(PersistenceManagerImpl.java:69)
at com.ibm.ejs.container.EJSContainer.loadBeanMetaData(EJSContainer.java:1293)
at com.ibm.ejs.container.EJSContainer.getHomeWrapperCommon(EJSContainer.java:958)
at com.ibm.ejs.container.EJSContainer.getHomeInstance(EJSContainer.java:881)
at com.ibm.ejs.container.EJSContainer.startBean(EJSContainer.java:860)
at com.ibm.ws.runtime.component.EJBContainerImpl.startBean(EJBContainerImpl.java:1249)
at com.ibm.ws.runtime.component.EJBContainerImpl.install(EJBContainerImpl.java:982)
at com.ibm.ws.runtime.component.EJBContainerImpl.start(EJBContainerImpl.java:1456)
at com.ibm.ws.runtime.component.ApplicationMgrImpl.start(ApplicationMgrImpl.java:401)
at com.ibm.ws.runtime.component.DeployedApplicationImpl.fireDeployedObjectStart(DeployedApplicationImpl.java:743)
at com.ibm.ws.runtime.component.DeployedModuleImpl.start(DeployedModuleImpl.java:337)
at com.ibm.ws.runtime.component.DeployedApplicationImpl.start(DeployedApplicationImpl.java:531)
at com.ibm.ws.runtime.component.ApplicationMgrImpl.startApplication(ApplicationMgrImpl.java:254)
at com.ibm.ws.runtime.component.ApplicationMgrImpl.startApplication(ApplicationMgrImpl.java:458)
at java.lang.reflect.Method.invoke(Native Method)
at com.tivoli.jmx.modelmbean.MMBInvoker.invoke(MMBInvoker.java:46)
at com.tivoli.jmx.modelmbean.MMBInvoker.invokeOperation(MMBInvoker.java:115)
at com.tivoli.jmx.modelmbean.DynamicModelMBeanSupport.invoke(DynamicModelMBeanSupport.java:409)
at javax.management.modelmbean.RequiredModelMBean.invoke(RequiredModelMBean.java:323)
at com.tivoli.jmx.GenericMBeanSupport.invoke(GenericMBeanSupport.java:178)
at com.tivoli.jmx.MBeanAccess.invoke(MBeanAccess.java:113)
at com.tivoli.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:290)
at com.ibm.ws.management.AdminServiceImpl.invoke(AdminServiceImpl.java:655)
at com.ibm.ws.console.core.mbean.MBeanHelper.invoke(MBeanHelper.java:137)
at com.ibm.ws.console.appdeployment.ApplicationDeploymentCollectionAction.perform(ApplicationDeploymentCollectionAction.java:239)
at org.apache.struts.action.ActionServlet.processActionPerform(ActionServlet.java:1791)
at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1586)
at org.apache.struts.action.ActionServlet.doPost(ActionServlet.java:510)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:760)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at com.ibm.ws.webcontainer.servlet.StrictServletInstance.doService(StrictServletInstance.java:110)
at com.ibm.ws.webcontainer.servlet.StrictLifecycleServlet._service(StrictLifecycleServlet.java:174)
at com.ibm.ws.webcontainer.servlet.IdleServletState.service(StrictLifecycleServlet.java:313)
at com.ibm.ws.webcontainer.servlet.StrictLifecycleServlet.service(StrictLifecycleServlet.java:116)
at com.ibm.ws.webcontainer.servlet.ServletInstance.service(ServletInstance.java:258)
at com.ibm.ws.webcontainer.servlet.ValidServletReferenceState.dispatch(ValidServletReferenceState.java:42)
at com.ibm.ws.webcontainer.servlet.ServletInstanceReference.dispatch(ServletInstanceReference.java:40)
at com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcher.handleWebAppDispatch(WebAppRequestDispatcher.java:872)
at com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcher.dispatch(WebAppRequestDispatcher.java:491)
at com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcher.forward(WebAppRequestDispatcher.java:173)
at com.ibm.ws.webcontainer.srt.WebAppInvoker.doForward(WebAppInvoker.java:79)
at com.ibm.ws.webcontainer.srt.WebAppInvoker.handleInvocationHook(WebAppInvoker.java:199)
at com.ibm.ws.webcontainer.cache.invocation.CachedInvocation.handleInvocation(CachedInvocation.java:71)
at com.ibm.ws.webcontainer.srp.ServletRequestProcessor.dispatchByURI(ServletRequestProcessor.java:182)
at com.ibm.ws.webcontainer.oselistener.OSEListenerDispatcher.service(OSEListener.java:331)
at com.ibm.ws.webcontainer.http.HttpConnection.handleRequest(HttpConnection.java:56)
at com.ibm.ws.http.HttpConnection.readAndHandleRequest(HttpConnection.java:432)
at com.ibm.ws.http.HttpConnection.run(HttpConnection.java:343)
at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:592)hello there
when u are deploying ur component there will be a screen that will show components present in ur jar/ear and will ask for JNDI name.U will have to fill the JNDI name manually and deploy the bean..
If even after that u are facing the same problem, use AAT(Application Assembly Tool) to create ur jar / ear ... there is a seperate link for giving JNDI names (namely JNDI Bindings) .use this tab to specify ur JNDI name and create the jar/ear.deploy as such in WAS and i am sure the error will not occur
Ganesh V -
JCA - Failed calling get method getThreadSecurity on the ManagedConnectionF
Hi All,
This is my first post with the SDN, hope I could see and extend helping hands in form of technology and solutions
My problem
=============
I am new to JCA.I am trying to deploy the helloworldra.ear provided by the IBM site.I deployed the resoource adapter and created a connectionFactory named "HelloWorld"(jndi).I get the below mentioned exception when I do
ConnectionFactory cxFactory = (ConnectionFactory) context.lookup("java:comp/env/HelloWorld");
Kindly chek into the exception and provide me with the solution.
Thanks in Advance
KABA
Exceptions Snapshot
==================
[7/7/06 14:38:27:624 EDT] 5a004128 SystemOut O Populating Context
[7/7/06 14:38:27:624 EDT] 5a004128 SystemOut O #################### JNDI Context Contents ####################
[7/7/06 14:38:27:624 EDT] 5a004128 SystemOut O com.ibm.websphere.naming.hostname.normalizer ---:-- com.ibm.ws.naming.util.DefaultHostnameNormalizer
[7/7/06 14:38:27:624 EDT] 5a004128 SystemOut O java.naming.factory.initial ---:-- com.ibm.websphere.naming.WsnInitialContextFactory
[7/7/06 14:38:27:624 EDT] 5a004128 SystemOut O com.ibm.websphere.naming.name.syntax ---:-- jndi
[7/7/06 14:38:27:624 EDT] 5a004128 SystemOut O com.ibm.websphere.naming.namespace.connection ---:-- lazy
[7/7/06 14:38:27:624 EDT] 5a004128 SystemOut O com.ibm.ws.naming.ldap.ldapinitctxfactory ---:-- com.sun.jndi.ldap.LdapCtxFactory
[7/7/06 14:38:27:624 EDT] 5a004128 SystemOut O com.ibm.websphere.naming.jndicache.cacheobject ---:-- populated
[7/7/06 14:38:27:624 EDT] 5a004128 SystemOut O com.ibm.websphere.naming.namespaceroot ---:-- defaultroot
[7/7/06 14:38:27:624 EDT] 5a004128 SystemOut O com.ibm.ws.naming.wsn.factory.initial ---:-- com.ibm.ws.naming.util.WsnInitCtxFactory
[7/7/06 14:38:27:624 EDT] 5a004128 SystemOut O com.ibm.websphere.naming.jndicache.maxcachelife ---:-- 0
[7/7/06 14:38:27:624 EDT] 5a004128 SystemOut O com.ibm.websphere.naming.jndicache.maxentrylife ---:-- 0
[7/7/06 14:38:27:624 EDT] 5a004128 SystemOut O com.ibm.websphere.naming.jndicache.cachename ---:-- providerURL
[7/7/06 14:38:27:624 EDT] 5a004128 SystemOut O java.naming.provider.url ---:-- corbaloc:rir:/NameServiceServerRoot
[7/7/06 14:38:27:624 EDT] 5a004128 SystemOut O java.naming.factory.url.pkgs ---:-- com.ibm.ws.runtime:com.ibm.ws.naming
[7/7/06 14:38:27:624 EDT] 5a004128 SystemOut O #################### JNDI Context Contents END ####################
[7/7/06 14:38:28:718 EDT] 5a004128 ConnectionFac E J2CA0066E: Failed calling get method getThreadSecurity on the ManagedConnectionFactory class com.ibm.ws.rsadapter.spi.WSManagedConnectionFactoryImpl used by resource jca/HelloWorld with the value <null>. Exception is java.lang.reflect.InvocationTargetException: java.lang.NullPointerException
at com.ibm.ws.rsadapter.spi.WSManagedConnectionFactoryImpl.getThreadSecurity(WSManagedConnectionFactoryImpl.java:612)
at java.lang.reflect.Method.invoke(Native Method)
at com.ibm.ejs.j2c.ConnectionFactoryBuilderImpl.getThreadSecurity(ConnectionFactoryBuilderImpl.java:2520)
at com.ibm.ejs.j2c.ConnectionFactoryBuilderImpl.createMCFandPM(ConnectionFactoryBuilderImpl.java:1747)
at com.ibm.ejs.j2c.ConnectionFactoryBuilderImpl.getObjectInstance(ConnectionFactoryBuilderImpl.java:1188)
at javax.naming.spi.NamingManager.getObjectInstance(NamingManager.java:313)
at com.ibm.ws.naming.util.Helpers.processSerializedObjectForLookup(Helpers.java:884)
at com.ibm.ws.naming.jndicos.CNContextImpl.processResolveResults(CNContextImpl.java:1762)
at com.ibm.ws.naming.jndicos.CNContextImpl.doLookup(CNContextImpl.java:1615)
at com.ibm.ws.naming.jndicos.CNContextImpl.doLookup(CNContextImpl.java:1525)
at com.ibm.ws.naming.jndicos.CNContextImpl.lookup(CNContextImpl.java:1225)
at com.ibm.ws.naming.util.WsnInitCtx.lookup(WsnInitCtx.java:132)
at javax.naming.InitialContext.lookup(InitialContext.java:359)
at com.ibm.ws.naming.util.IndirectJndiLookupObjectFactory$1.run(IndirectJndiLookupObjectFactory.java:293)
at java.security.AccessController.doPrivileged(Native Method)
at com.ibm.ws.naming.util.IndirectJndiLookupObjectFactory.getObjectInstance(IndirectJndiLookupObjectFactory.java:144)
at com.ibm.ws.util.ResRefJndiLookupObjectFactory.getObjectInstance(ResRefJndiLookupObjectFactory.java:127)
at javax.naming.spi.NamingManager.getObjectInstance(NamingManager.java:313)
at com.ibm.ws.naming.util.Helpers.processSerializedObjectForLookup(Helpers.java:884)
at com.ibm.ws.naming.urlbase.UrlContextHelper.processBoundObjectForLookup(UrlContextHelper.java:135)
at com.ibm.ws.naming.urlbase.UrlContext.lookup(UrlContext.java:1227)
at com.ibm.ws.naming.urlbase.UrlContext.lookup(UrlContext.java:1203)
at com.ibm.ws.naming.urlbase.UrlContext.lookup(UrlContext.java:1257)
at javax.naming.InitialContext.lookup(InitialContext.java:359)
at com.ibm.ssya.helloworldra.servlets.HelloWorldBean.execute(HelloWorldBean.java:81)
at org.apache.jsp._HelloWorldResults._jspService(_HelloWorldResults.java:105)
at com.ibm.ws.webcontainer.jsp.runtime.HttpJspBase.service(HttpJspBase.java:89)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at com.ibm.ws.webcontainer.jsp.servlet.JspServlet$JspServletWrapper.service(JspServlet.java:357)
at com.ibm.ws.webcontainer.jsp.servlet.JspServlet.serviceJspFile(JspServlet.java:675)
at com.ibm.ws.webcontainer.jsp.servlet.JspServlet.service(JspServlet.java:773)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at com.ibm.ws.webcontainer.servlet.StrictServletInstance.doService(StrictServletInstance.java:110)
at com.ibm.ws.webcontainer.servlet.StrictLifecycleServlet._service(StrictLifecycleServlet.java:174)
at com.ibm.ws.webcontainer.servlet.IdleServletState.service(StrictLifecycleServlet.java:313)
at com.ibm.ws.webcontainer.servlet.StrictLifecycleServlet.service(StrictLifecycleServlet.java:116)
at com.ibm.ws.webcontainer.servlet.ServletInstance.service(ServletInstance.java:283)
at com.ibm.ws.webcontainer.servlet.ValidServletReferenceState.dispatch(ValidServletReferenceState.java:42)
at com.ibm.ws.webcontainer.servlet.ServletInstanceReference.dispatch(ServletInstanceReference.java:40)
at com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcher.handleWebAppDispatch(WebAppRequestDispatcher.java:948)
at com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcher.dispatch(WebAppRequestDispatcher.java:530)
at com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcher.forward(WebAppRequestDispatcher.java:176)
at com.ibm.ssya.helloworldra.servlets.HelloWorldController.dispatch(HelloWorldController.java:101)
at com.ibm.ssya.helloworldra.servlets.HelloWorldController.performTask(HelloWorldController.java:66)
at com.ibm.ssya.helloworldra.servlets.HelloWorldController.doPost(HelloWorldController.java:88)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:760)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at com.ibm.ws.webcontainer.servlet.StrictServletInstance.doService(StrictServletInstance.java:110)
at com.ibm.ws.webcontainer.servlet.StrictLifecycleServlet._service(StrictLifecycleServlet.java:174)
at com.ibm.ws.webcontainer.servlet.IdleServletState.service(StrictLifecycleServlet.java:313)
at com.ibm.ws.webcontainer.servlet.StrictLifecycleServlet.service(StrictLifecycleServlet.java:116)
at com.ibm.ws.webcontainer.servlet.ServletInstance.service(ServletInstance.java:283)
at com.ibm.ws.webcontainer.servlet.ValidServletReferenceState.dispatch(ValidServletReferenceState.java:42)
at com.ibm.ws.webcontainer.servlet.ServletInstanceReference.dispatch(ServletInstanceReference.java:40)
at com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcher.handleWebAppDispatch(WebAppRequestDispatcher.java:948)
at com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcher.dispatch(WebAppRequestDispatcher.java:530)
at com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcher.forward(WebAppRequestDispatcher.java:176)
at com.ibm.ws.webcontainer.srt.WebAppInvoker.doForward(WebAppInvoker.java:79)
at com.ibm.ws.webcontainer.srt.WebAppInvoker.handleInvocationHook(WebAppInvoker.java:201)
at com.ibm.ws.webcontainer.cache.invocation.CachedInvocation.handleInvocation(CachedInvocation.java:71)
at com.ibm.ws.webcontainer.cache.invocation.CacheableInvocationContext.invoke(CacheableInvocationContext.java:114)
at com.ibm.ws.webcontainer.srp.ServletRequestProcessor.dispatchByURI(ServletRequestProcessor.java:186)
at com.ibm.ws.webcontainer.oselistener.OSEListenerDispatcher.service(OSEListener.java:334)
at com.ibm.ws.webcontainer.http.HttpConnection.handleRequest(HttpConnection.java:56)
at com.ibm.ws.http.HttpConnection.readAndHandleRequest(HttpConnection.java:610)
at com.ibm.ws.http.HttpConnection.run(HttpConnection.java:431)
at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:593)
[7/7/06 14:38:28:812 EDT] 5a004128 ConnectionFac E J2CA0009E: An exception occurred while trying to instantiate the ManagedConnectionFactory class com.ibm.ws.rsadapter.spi.WSManagedConnectionFactoryImpl used by resource jca/HelloWorld : java.lang.reflect.InvocationTargetException: java.lang.NullPointerException
at com.ibm.ws.rsadapter.spi.WSManagedConnectionFactoryImpl.getThreadSecurity(WSManagedConnectionFactoryImpl.java:612)
at java.lang.reflect.Method.invoke(Native Method)
at com.ibm.ejs.j2c.ConnectionFactoryBuilderImpl.getThreadSecurity(ConnectionFactoryBuilderImpl.java:2520)
at com.ibm.ejs.j2c.ConnectionFactoryBuilderImpl.createMCFandPM(ConnectionFactoryBuilderImpl.java:1747)
at com.ibm.ejs.j2c.ConnectionFactoryBuilderImpl.getObjectInstance(ConnectionFactoryBuilderImpl.java:1188)
at javax.naming.spi.NamingManager.getObjectInstance(NamingManager.java:313)
at com.ibm.ws.naming.util.Helpers.processSerializedObjectForLookup(Helpers.java:884)
at com.ibm.ws.naming.jndicos.CNContextImpl.processResolveResults(CNContextImpl.java:1762)
at com.ibm.ws.naming.jndicos.CNContextImpl.doLookup(CNContextImpl.java:1615)
at com.ibm.ws.naming.jndicos.CNContextImpl.doLookup(CNContextImpl.java:1525)
at com.ibm.ws.naming.jndicos.CNContextImpl.lookup(CNContextImpl.java:1225)
at com.ibm.ws.naming.util.WsnInitCtx.lookup(WsnInitCtx.java:132)
at javax.naming.InitialContext.lookup(InitialContext.java:359)
at com.ibm.ws.naming.util.IndirectJndiLookupObjectFactory$1.run(IndirectJndiLookupObjectFactory.java:293)
at java.security.AccessController.doPrivileged(Native Method)
at com.ibm.ws.naming.util.IndirectJndiLookupObjectFactory.getObjectInstance(IndirectJndiLookupObjectFactory.java:144)
at com.ibm.ws.util.ResRefJndiLookupObjectFactory.getObjectInstance(ResRefJndiLookupObjectFactory.java:127)
at javax.naming.spi.NamingManager.getObjectInstance(NamingManager.java:313)
at com.ibm.ws.naming.util.Helpers.processSerializedObjectForLookup(Helpers.java:884)
at com.ibm.ws.naming.urlbase.UrlContextHelper.processBoundObjectForLookup(UrlContextHelper.java:135)
at com.ibm.ws.naming.urlbase.UrlContext.lookup(UrlContext.java:1227)
at com.ibm.ws.naming.urlbase.UrlContext.lookup(UrlContext.java:1203)
at com.ibm.ws.naming.urlbase.UrlContext.lookup(UrlContext.java:1257)
at javax.naming.InitialContext.lookup(InitialContext.java:359)
at com.ibm.ssya.helloworldra.servlets.HelloWorldBean.execute(HelloWorldBean.java:81)
at org.apache.jsp._HelloWorldResults._jspService(_HelloWorldResults.java:105)
at com.ibm.ws.webcontainer.jsp.runtime.HttpJspBase.service(HttpJspBase.java:89)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at com.ibm.ws.webcontainer.jsp.servlet.JspServlet$JspServletWrapper.service(JspServlet.java:357)
at com.ibm.ws.webcontainer.jsp.servlet.JspServlet.serviceJspFile(JspServlet.java:675)
at com.ibm.ws.webcontainer.jsp.servlet.JspServlet.service(JspServlet.java:773)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at com.ibm.ws.webcontainer.servlet.StrictServletInstance.doService(StrictServletInstance.java:110)
at com.ibm.ws.webcontainer.servlet.StrictLifecycleServlet._service(StrictLifecycleServlet.java:174)
at com.ibm.ws.webcontainer.servlet.IdleServletState.service(StrictLifecycleServlet.java:313)
at com.ibm.ws.webcontainer.servlet.StrictLifecycleServlet.service(StrictLifecycleServlet.java:116)
at com.ibm.ws.webcontainer.servlet.ServletInstance.service(ServletInstance.java:283)
at com.ibm.ws.webcontainer.servlet.ValidServletReferenceState.dispatch(ValidServletReferenceState.java:42)
at com.ibm.ws.webcontainer.servlet.ServletInstanceReference.dispatch(ServletInstanceReference.java:40)
at com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcher.handleWebAppDispatch(WebAppRequestDispatcher.java:948)
at com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcher.dispatch(WebAppRequestDispatcher.java:530)
at com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcher.forward(WebAppRequestDispatcher.java:176)
at com.ibm.ssya.helloworldra.servlets.HelloWorldController.dispatch(HelloWorldController.java:101)
at com.ibm.ssya.helloworldra.servlets.HelloWorldController.performTask(HelloWorldController.java:66)
at com.ibm.ssya.helloworldra.servlets.HelloWorldController.doPost(HelloWorldController.java:88)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:760)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at com.ibm.ws.webcontainer.servlet.StrictServletInstance.doService(StrictServletInstance.java:110)
at com.ibm.ws.webcontainer.servlet.StrictLifecycleServlet._service(StrictLifecycleServlet.java:174)
at com.ibm.ws.webcontainer.servlet.IdleServletState.service(StrictLifecycleServlet.java:313)
at com.ibm.ws.webcontainer.servlet.StrictLifecycleServlet.service(StrictLifecycleServlet.java:116)
at com.ibm.ws.webcontainer.servlet.ServletInstance.service(ServletInstance.java:283)
at com.ibm.ws.webcontainer.servlet.ValidServletReferenceState.dispatch(ValidServletReferenceState.java:42)
at com.ibm.ws.webcontainer.servlet.ServletInstanceReference.dispatch(ServletInstanceReference.java:40)
at com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcher.handleWebAppDispatch(WebAppRequestDispatcher.java:948)
at com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcher.dispatch(WebAppRequestDispatcher.java:530)
at com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcher.forward(WebAppRequestDispatcher.java:176)
at com.ibm.ws.webcontainer.srt.WebAppInvoker.doForward(WebAppInvoker.java:79)
at com.ibm.ws.webcontainer.srt.WebAppInvoker.handleInvocationHook(WebAppInvoker.java:201)
at com.ibm.ws.webcontainer.cache.invocation.CachedInvocation.handleInvocation(CachedInvocation.java:71)
at com.ibm.ws.webcontainer.cache.invocation.CacheableInvocationContext.invoke(CacheableInvocationContext.java:114)
at com.ibm.ws.webcontainer.srp.ServletRequestProcessor.dispatchByURI(ServletRequestProcessor.java:186)
at com.ibm.ws.webcontainer.oselistener.OSEListenerDispatcher.service(OSEListener.java:334)
at com.ibm.ws.webcontainer.http.HttpConnection.handleRequest(HttpConnection.java:56)
at com.ibm.ws.http.HttpConnection.readAndHandleRequest(HttpConnection.java:610)
at com.ibm.ws.http.HttpConnection.run(HttpConnection.java:431)
at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:593)
[7/7/06 14:38:28:859 EDT] 5a004128 Helpers W NMSV0605W: A Reference object looked up from the context "localhost/nodes/localhost/servers/server1" with the name "jca/HelloWorld" was sent to the JNDI Naming Manager and an exception resulted. Reference data follows:
Reference Factory Class Name: com.ibm.ejs.j2c.ConnectionFactoryBuilderImpl
Reference Factory Class Location URLs: <null>
Reference Class Name: HelloWorld
Type: connectorName
Content: HelloWorld
Type: classpath
Content: C:\Program Files\IBM\WebSphere Studio\Application Developer\v5.1\runtimes\base_v5/lib/rsadapter.rar
Type: FactoryJndiName
Content: jca/HelloWorld
Address Type: dd
AddressContents: ffffffac ffffffed 0 5 73 72 0 25 63 6f 6d 2e 69 62 6d 2e 65 6a 73 2e 6a 32 63 2e 52 65 73 6f 75 72 63 65 ...
Address Type: poolProps
AddressContents: ffffffac ffffffed 0 5 73 72 0 27 63 6f 6d 2e 69 62 6d 2e 65 6a 73 2e 6a 32 63 2e 43 6f 6e 6e 65 63 74 6f ...
Address Type: configProps
AddressContents: ffffffac ffffffed 0 5 73 72 0 23 63 6f 6d 2e 69 62 6d 2e 65 6a 73 2e 6a 32 63 2e 43 6f 6e 6e 65 63 74 6f ...
Address Type: mmProps
AddressContents: ffffffac ffffffed 0 5 73 72 0 14 6a 61 76 61 2e 75 74 69 6c 2e 50 72 6f 70 65 72 74 69 65 73 39 12 ffffffd0 7a ...
Address Type: mbeanProps
AddressContents: ffffffac ffffffed 0 5 73 72 0 1a 63 6f 6d 2e 69 62 6d 2e 65 6a 73 2e 6a 32 63 2e 4d 42 65 61 6e 50 72 6f ...
Exception data follows:
java.lang.reflect.InvocationTargetException: java.lang.NullPointerException
at com.ibm.ws.rsadapter.spi.WSManagedConnectionFactoryImpl.getThreadSecurity(WSManagedConnectionFactoryImpl.java:612)
at java.lang.reflect.Method.invoke(Native Method)
at com.ibm.ejs.j2c.ConnectionFactoryBuilderImpl.getThreadSecurity(ConnectionFactoryBuilderImpl.java:2520)
at com.ibm.ejs.j2c.ConnectionFactoryBuilderImpl.createMCFandPM(ConnectionFactoryBuilderImpl.java:1747)
at com.ibm.ejs.j2c.ConnectionFactoryBuilderImpl.getObjectInstance(ConnectionFactoryBuilderImpl.java:1188)
at javax.naming.spi.NamingManager.getObjectInstance(NamingManager.java:313)
at com.ibm.ws.naming.util.Helpers.processSerializedObjectForLookup(Helpers.java:884)
at com.ibm.ws.naming.jndicos.CNContextImpl.processResolveResults(CNContextImpl.java:1762)
at com.ibm.ws.naming.jndicos.CNContextImpl.doLookup(CNContextImpl.java:1615)
at com.ibm.ws.naming.jndicos.CNContextImpl.doLookup(CNContextImpl.java:1525)
at com.ibm.ws.naming.jndicos.CNContextImpl.lookup(CNContextImpl.java:1225)
at com.ibm.ws.naming.util.WsnInitCtx.lookup(WsnInitCtx.java:132)
at javax.naming.InitialContext.lookup(InitialContext.java:359)
at com.ibm.ws.naming.util.IndirectJndiLookupObjectFactory$1.run(IndirectJndiLookupObjectFactory.java:293)
at java.security.AccessController.doPrivileged(Native Method)
at com.ibm.ws.naming.util.IndirectJndiLookupObjectFactory.getObjectInstance(IndirectJndiLookupObjectFactory.java:144)
at com.ibm.ws.util.ResRefJndiLookupObjectFactory.getObjectInstance(ResRefJndiLookupObjectFactory.java:127)
at javax.naming.spi.NamingManager.getObjectInstance(NamingManager.java:313)
at com.ibm.ws.naming.util.Helpers.processSerializedObjectForLookup(Helpers.java:884)
at com.ibm.ws.naming.urlbase.UrlContextHelper.processBoundObjectForLookup(UrlContextHelper.java:135)
at com.ibm.ws.naming.urlbase.UrlContext.lookup(UrlContext.java:1227)
at com.ibm.ws.naming.urlbase.UrlContext.lookup(UrlContext.java:1203)
at com.ibm.ws.naming.urlbase.UrlContext.lookup(UrlContext.java:1257)
at javax.naming.InitialContext.lookup(InitialContext.java:359)
at com.ibm.ssya.helloworldra.servlets.HelloWorldBean.execute(HelloWorldBean.java:81)
at org.apache.jsp._HelloWorldResults._jspService(_HelloWorldResults.java:105)
at com.ibm.ws.webcontainer.jsp.runtime.HttpJspBase.service(HttpJspBase.java:89)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at com.ibm.ws.webcontainer.jsp.servlet.JspServlet$JspServletWrapper.service(JspServlet.java:357)
at com.ibm.ws.webcontainer.jsp.servlet.JspServlet.serviceJspFile(JspServlet.java:675)
at com.ibm.ws.webcontainer.jsp.servlet.JspServlet.service(JspServlet.java:773)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at com.ibm.ws.webcontainer.servlet.StrictServletInstance.doService(StrictServletInstance.java:110)
at com.ibm.ws.webcontainer.servlet.StrictLifecycleServlet._service(StrictLifecycleServlet.java:174)
at com.ibm.ws.webcontainer.servlet.IdleServletState.service(StrictLifecycleServlet.java:313)
at com.ibm.ws.webcontainer.servlet.StrictLifecycleServlet.service(StrictLifecycleServlet.java:116)
at com.ibm.ws.webcontainer.servlet.ServletInstance.service(ServletInstance.java:283)
at com.ibm.ws.webcontainer.servlet.ValidServletReferenceState.dispatch(ValidServletReferenceState.java:42)
at com.ibm.ws.webcontainer.servlet.ServletInstanceReference.dispatch(ServletInstanceReference.java:40)
at com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcher.handleWebAppDispatch(WebAppRequestDispatcher.java:948)
at com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcher.dispatch(WebAppRequestDispatcher.java:530)
at com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcher.forward(WebAppRequestDispatcher.java:176)
at com.ibm.ssya.helloworldra.servlets.HelloWorldController.dispatch(HelloWorldController.java:101)
at com.ibm.ssya.helloworldra.servlets.HelloWorldController.performTask(HelloWorldController.java:66)
at com.ibm.ssya.helloworldra.servlets.HelloWorldController.doPost(HelloWorldController.java:88)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:760)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at com.ibm.ws.webcontainer.servlet.StrictServletInstance.doService(StrictServletInstance.java:110)
at com.ibm.ws.webcontainer.servlet.StrictLifecycleServlet._service(StrictLifecycleServlet.java:174)
at com.ibm.ws.webcontainer.servlet.IdleServletState.service(StrictLifecycleServlet.java:313)
at com.ibm.ws.webcontainer.servlet.StrictLifecycleServlet.service(StrictLifecycleServlet.java:116)
at com.ibm.ws.webcontainer.servlet.ServletInstance.service(ServletInstance.java:283)
at com.ibm.ws.webcontainer.servlet.ValidServletReferenceState.dispatch(ValidServletReferenceState.java:42)
at com.ibm.ws.webcontainer.servlet.ServletInstanceReference.dispatch(ServletInstanceReference.java:40)
at com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcher.handleWebAppDispatch(WebAppRequestDispatcher.java:948)
at com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcher.dispatch(WebAppRequestDispatcher.java:530)
at com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcher.forward(WebAppRequestDispatcher.java:176)
at com.ibm.ws.webcontainer.srt.WebAppInvoker.doForward(WebAppInvoker.java:79)
at com.ibm.ws.webcontainer.srt.WebAppInvoker.handleInvocationHook(WebAppInvoker.java:201)
at com.ibm.ws.webcontainer.cache.invocation.CachedInvocation.handleInvocation(CachedInvocation.java:71)
at com.ibm.ws.webcontainer.cache.invocation.CacheableInvocationContext.invoke(CacheableInvocationContext.java:114)
at com.ibm.ws.webcontainer.srp.ServletRequestProcessor.dispatchByURI(ServletRequestProcessor.java:186)
at com.ibm.ws.webcontainer.oselistener.OSEListenerDispatcher.service(OSEListener.java:334)
at com.ibm.ws.webcontainer.http.HttpConnection.handleRequest(HttpConnection.java:56)
at com.ibm.ws.http.HttpConnection.readAndHandleRequest(HttpConnection.java:610)
at com.ibm.ws.http.HttpConnection.run(HttpConnection.java:431)
at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:593)
[7/7/06 14:38:28:953 EDT] 5a004128 Helpers W NMSV0610I: A NamingException is being thrown from a javax.naming.Context implementation. Details follow:
Context implementation: com.ibm.ws.naming.jndicos.CNContextImpl
Context method: lookup
Context name: localhost/nodes/localhost/servers/server1
Target name: jca/HelloWorld
Other data:
Exception stack trace: com.ibm.websphere.naming.CannotInstantiateObjectException: Exception occurred while the JNDI NamingManager was processing a javax.naming.Reference object. Root exception is java.lang.reflect.InvocationTargetException: java.lang.NullPointerException
at com.ibm.ws.rsadapter.spi.WSManagedConnectionFactoryImpl.getThreadSecurity(WSManagedConnectionFactoryImpl.java:612)
at java.lang.reflect.Method.invoke(Native Method)
at com.ibm.ejs.j2c.ConnectionFactoryBuilderImpl.getThreadSecurity(ConnectionFactoryBuilderImpl.java:2520)
at com.ibm.ejs.j2c.ConnectionFactoryBuilderImpl.createMCFandPM(ConnectionFactoryBuilderImpl.java:1747)
at com.ibm.ejs.j2c.ConnectionFactoryBuilderImpl.getObjectInstance(ConnectionFactoryBuilderImpl.java:1188)
at javax.naming.spi.NamingManager.getObjectInstance(NamingManager.java:313)
at com.ibm.ws.naming.util.Helpers.processSerializedObjectForLookup(Helpers.java:884)
at com.ibm.ws.naming.jndicos.CNContextImpl.processResolveResults(CNContextImpl.java:1762)
at com.ibm.ws.naming.jndicos.CNContextImpl.doLookup(CNContextImpl.java:1615)
at com.ibm.ws.naming.jndicos.CNContextImpl.doLookup(CNContextImpl.java:1525)
at com.ibm.ws.naming.jndicos.CNContextImpl.lookup(CNContextImpl.java:1225)
at com.ibm.ws.naming.util.WsnInitCtx.lookup(WsnInitCtx.java:132)
at javax.naming.InitialContext.lookup(InitialContext.java:359)
at com.ibm.ws.naming.util.IndirectJndiLookupObjectFactory$1.run(IndirectJndiLookupObjectFactory.java:293)
at java.security.AccessController.doPrivileged(Native Method)
at com.ibm.ws.naming.util.IndirectJndiLookupObjectFactory.getObjectInstance(IndirectJndiLookupObjectFactory.java:144)
at com.ibm.ws.util.ResRefJndiLookupObjectFactory.getObjectInstance(ResRefJndiLookupObjectFactory.java:127)
at javax.naming.spi.NamingManager.getObjectInstance(NamingManager.java:313)
at com.ibm.ws.naming.util.Helpers.processSerializedObjectForLookup(Helpers.java:884)
at com.ibm.ws.naming.urlbase.UrlContextHelper.processBoundObjectForLookup(UrlContextHelper.java:135)
at com.ibm.ws.naming.urlbase.UrlContext.lookup(UrlContext.java:1227)
at com.ibm.ws.naming.urlbase.UrlContext.lookup(UrlContext.java:1203)
at com.ibm.ws.naming.urlbase.UrlContext.lookup(UrlContext.java:1257)
at javax.naming.InitialContext.lookup(InitialContext.java:359)
at com.ibm.ssya.helloworldra.servlets.HelloWorldBean.execute(HelloWorldBean.java:81)
at org.apache.jsp._HelloWorldResults._jspService(_HelloWorldResults.java:105)
at com.ibm.ws.webcontainer.jsp.runtime.HttpJspBase.service(HttpJspBase.java:89)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at com.ibm.ws.webcontainer.jsp.servlet.JspServlet$JspServletWrapper.service(JspServlet.java:357)
at com.ibm.ws.webcontainer.jsp.servlet.JspServlet.serviceJspFile(JspServlet.java:675)
at com.ibm.ws.webcontainer.jsp.servlet.JspServlet.service(JspServlet.java:773)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at com.ibm.ws.webcontainer.servlet.StrictServletInstance.doService(StrictServletInstance.java:110)
at com.ibm.ws.webcontainer.servlet.StrictLifecycleServlet._service(StrictLifecycleServlet.java:174)
at com.ibm.ws.webcontainer.servlet.IdleServletState.service(StrictLifecycleServlet.java:313)
at com.ibm.ws.webcontainer.servlet.StrictLifecycleServlet.service(StrictLifecycleServlet.java:116)
at com.ibm.ws.webcontainer.servlet.ServletInstance.service(ServletInstance.java:283)
at com.ibm.ws.webcontainer.servlet.ValidServletReferenceState.dispatch(ValidServletReferenceState.java:42)
at com.ibm.ws.webcontainer.servlet.ServletInstanceReference.dispatch(ServletInstanceReference.java:40)
at com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcher.handleWebAppDispatch(WebAppRequestDispatcher.java:948)
at com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcher.dispatch(WebAppRequestDispatcher.java:530)
at com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcher.forward(WebAppRequestDispatcher.java:176)
at com.ibm.ssya.helloworldra.servlets.HelloWorldController.dispatch(HelloWorldController.java:101)
at com.ibm.ssya.helloworldra.servlets.HelloWorldController.performTask(HelloWorldController.java:66)
at com.ibm.ssya.helloworldra.servlets.HelloWorldController.doPost(HelloWorldController.java:88)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:760)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at com.ibm.ws.webcontainer.servlet.StrictServletInstance.doService(StrictServletInstance.java:110)
at com.ibm.ws.webcontainer.servlet.StrictLifecycleServlet._service(StrictLifecycleServlet.java:174)
at com.ibm.ws.webcontainer.servlet.IdleServletState.service(StrictLifecycleServlet.java:313)
at com.ibm.ws.webcontainer.servlet.StrictLifecycleServlet.service(StrictLifecycleServlet.java:116)
at com.ibm.ws.webcontainer.servlet.ServletInstance.service(ServletInstance.java:283)
at com.ibm.ws.webcontainer.servlet.ValidServletReferenceState.dispatch(ValidServletReferenceState.java:42)
at com.ibm.ws.webcontainer.servlet.ServletInstanceReference.dispatch(ServletInstanceReference.java:40)
at com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcher.handleWebAppDispatch(WebAppRequestDispatcher.java:948)
at com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcher.dispatch(WebAppRequestDispatcher.java:530)
at com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcher.forward(WebAppRequestDispatcher.java:176)
at com.ibm.ws.webcontainer.srt.WebAppInvoker.doForward(WebAppInvoker.java:79)
at com.ibm.ws.webcontainer.srt.WebAppInvoker.handleInvocationHook(WebAppInvoker.java:201)
at com.ibm.ws.webcontainer.cache.invocation.CachedInvocation.handleInvocation(CachedInvocation.java:71)
at com.ibm.ws.webcontainer.cache.invocation.CacheableInvocationContext.invoke(CacheableInvocationContext.java:114)
at com.ibm.ws.webcontainer.srp.ServletRequestProcessor.dispatchByURI(ServletRequestProcessor.java:186)
at com.ibm.ws.webcontainer.oselistener.OSEListenerDispatcher.service(OSEListener.java:334)
at com.ibm.ws.webcontainer.http.HttpConnection.handleRequest(HttpConnection.java:56)
at com.ibm.ws.http.HttpConnection.readAndHandleRequest(HttpConnection.java:610)
at com.ibm.ws.http.HttpConnection.run(HttpConnection.java:431)
at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:593)
[7/7/06 14:38:29:031 EDT] 5a004128 ConnectionFac E J2CA0066E: Failed calling get method getThreadSecurity on the ManagedConnectionFactory class com.ibm.ws.rsadapter.spi.WSManagedConnectionFactoryImpl used by resource jca/HelloWorld with the value <null>. Exception is java.lang.reflect.InvocationTargetException: java.lang.NullPointerException
at com.ibm.ws.rsadapter.spi.WSManagedConnectionFactoryImpl.getThreadSecurity(WSManagedConnectionFactoryImpl.java:612)
at java.lang.reflect.Method.invoke(Native Method)
at com.ibm.ejs.j2c.ConnectionFactoryBuilderImpl.getThreadSecurity(ConnectionFactoryBuilderImpl.java:2520)
at com.ibm.ejs.j2c.ConnectionFactoryBuilderImpl.createMCFandPM(ConnectionFPersianKamran wrote:
folks.. i am sending my class object on Sockets from client to Server (i am implementing Seriablizable Interface).
No your aren't.
You are sending the data in the class.
That is what serialization does. (And actually not all data can be sent either.)
When i get the object on server, i am able to print all its fields and methods... But i have one problem. I want to invoke a simple static method that just prints "hello".. The method on client that i am trying to invoke is....You probably either need stop attempting that or re-architect the solution.
It is possible to send a class (not data) to another computer and that computer runs it. That is how applets work.
But for that to work you must send the class. And deal with how the VM loads and unloads classes (not data) as well. -
Help needed to run a JMS application on WSAD
Hello everybody,
I�m trying to execute a JMS application which calls a QueueConnectionFactory and a Queue by JNDI lookup.
I had configured these queues & Connection Factory at the server configuration for the JMS Server & these are being displayed while the server is starting up that these names had been binded.until here it�s ok.
But the problem comes when I try to us my JMS program with configurations as websphere 5.1 application client.\
The error is being displayed as :
com.ibm.websphere.naming.CannotInstantiateObjectException: Exception occurred while the JNDI NamingManager was processing a javax.naming.Reference object.
[Root exception is java.lang.Exception: De-reference of JMS provider's Reference failed - check provider is on classpath]
WSCL0100E: Exception received: java.lang.reflect.InvocationTargetException
If any body can check this out please help.
best regards,
Raju Cherukuri.Hi,
I am facing the same issue. Also regarding the resolution posted in this thread, to add the MQ jars in the classpath, do I still have to do if I am using the embedded JMS and not MQ.
Cosmo can you pls explain what are the steps to do, for whatever you've suggested.
Regards,
Hari -
I am getting this error
com.ibm.websphere.naming.CannotInstantiateObjectException: Exception occurred while the JNDI NamingManager was processing a javax.naming.Reference object. Root exception is java.lang.reflect.InvocationTargetException
While trying to create datasource. the code goes here.
I am getting error in the last line.
Hashtable parms = new Hashtable();
parms.put( Context.INITIAL_CONTEXT_FACTORY,
"com.ibm.websphere.naming.WsnInitialContextFactory");
InitialContext ctx = new InitialContext(parms);
DataSource ds = (DataSource) ctx.lookup(jndiName);
Please help me why i am getting this error.Which database you are curently working. Just an assumption, it looks that the specified database does not have the jar in place and due that you are getting the error
-
Importing coherence-tx.rar in WSAD 5.1 and deploying it on WAS 5.1
All,
I have downloaded coherence s/w (3.2.2 build 371) for evaluation purposes, on desktop environment.
I am currently trying to import the cohrence rar file into WSAD 5.1.2 so i can built it into my ear file (which contains an MDB and 1 servlet). I am trying to test the code (published on code section of this web site) demonstrating how to put to a distributed cache within scope of a JTA/MDB/EJB XA transaction.
I tried importing the rar file into WSAD in 2 ways
a) In J2EE hierarchy, under modules ->did right click->import->import rar file. After giving the path of the rar file on my desktop, WSAD gives an error 'Missing required library:Coherence-txConnector/imported_classes' in the 'tasks' panel of WSAD. It also gives errors pertaiing to some weblogic specific ra.xmls. When i removed the weblogic xmls in the rar file and tried again - it still gives the missing requierd library error.
It is however able to create the coherence-txConnector module under 'Connector Modules' tree in J2EE hierarchy tab
b) I then deleted this module from WSAD and tried doing file->import->rar file. again I get the same error pertaining missing classes.
I have added tangosol.lib, coherence.lib to the java build path for my war/MDB projects - dont know if this is related to above issue or not.
2) Assuming I am able to build the ear with this rar included in it, when I am going to install the ear on my WAS instance, are there any specific settings that need to be done to configure the rar adapter (within my ear).
Apologise if these may seem silly questions - but this is the first time i am working with resource adapters in WSAD/WAS environments.
Any help given will be appreciated since this is a stumbling block now.
regards,
Sanjeev.Dimitri,
Further updates to this issue (as on 27th Feb) - I tried the following strategy (since there were no responses to my forum posting)
1) I cleaned up my ear project in WSAD (removed the connector and all references to it in the ear) and simply imported the connector rar as a standalone connector in WSAD (not part of the ear) using File->import->import rar file (note - i have removed the weblogic specific xml from the rar files shipped with Coherence).
2) Was able to build my ear without any issues (I have kept references to tangosol.jar and coherence.jar in the root of the ear). The web project within the ear refers to these 2 jars via entries in its manifest file.
3) I additionally deployed the rar file on a WAS instance through the admin console using Resources->Resource Adapters->install RAR.Once it installed, I gave the JNDI name (in J2C connection Factories) as tangosol.coherenceTx for this resource adapter. I used defaults for everything else.
4) After that - I deployed the ear without any issues.
5) However - when I execute my servlet (which basically puts a cache entry via the CacheAdapter, within a JTA transaction) - I get the following exception.
[2/26/07 15:30:43:248 IST] 2de2d2e4 SystemErr R (Wrapped) com.ibm.websphere.naming.CannotInstantiateObjectException: Exception occurred while the JNDI NamingManager was processing a javax.naming.Reference object. Root exception is java.lang.NoClassDefFoundError: com/tangosol/util/WrapperException
[2/26/07 15:30:43:248 IST] 2de2d2e4 SystemErr R at java.lang.Class.getDeclaredConstructors0(Native Method)
[2/26/07 15:30:43:248 IST] 2de2d2e4 SystemErr R at java.lang.Class.privateGetDeclaredConstructors(Class.java(Compiled Code))
[2/26/07 15:30:43:248 IST] 2de2d2e4 SystemErr R at java.lang.Class.getConstructor1(Class.java(Compiled Code))
[2/26/07 15:30:43:248 IST] 2de2d2e4 SystemErr R at java.lang.Class.newInstance3(Class.java(Compiled Code))
[2/26/07 15:30:43:248 IST] 2de2d2e4 SystemErr R at java.lang.Class.newInstance(Class.java(Compiled Code))
[2/26/07 15:30:43:248 IST] 2de2d2e4 SystemErr R at com.ibm.ejs.j2c.J2CXAResourceFactory.createMCFEntry(J2CXAResourceFactory.java:344)
[2/26/07 15:30:43:248 IST] 2de2d2e4 SystemErr R at com.ibm.ejs.j2c.ConnectionFactoryBuilderImpl.createMCFandPM(ConnectionFactoryBuilderImpl.java:1414)
[2/26/07 15:30:43:248 IST] 2de2d2e4 SystemErr R at com.ibm.ejs.j2c.ConnectionFactoryBuilderImpl.getObjectInstance(ConnectionFactoryBuilderImpl.java:1201)
[2/26/07 15:30:43:248 IST] 2de2d2e4 SystemErr R at javax.naming.spi.NamingManager.getObjectInstance(NamingManager.java:313)
[2/26/07 15:30:43:248 IST] 2de2d2e4 SystemErr R at com.ibm.ws.naming.util.Helpers.processSerializedObjectForLookupExt(Helpers.java:873)
[2/26/07 15:30:43:248 IST] 2de2d2e4 SystemErr R at com.ibm.ws.naming.util.Helpers.processSerializedObjectForLookup(Helpers.java:680)
[2/26/07 15:30:43:248 IST] 2de2d2e4 SystemErr R at com.ibm.ws.naming.jndicos.CNContextImpl.processResolveResults(CNContextImpl.java:1712)
[2/26/07 15:30:43:248 IST] 2de2d2e4 SystemErr R at com.ibm.ws.naming.jndicos.CNContextImpl.doLookup(CNContextImpl.java:1567)
[2/26/07 15:30:43:248 IST] 2de2d2e4 SystemErr R at com.ibm.ws.naming.jndicos.CNContextImpl.doLookup(CNContextImpl.java:1480)
[2/26/07 15:30:43:248 IST] 2de2d2e4 SystemErr R at com.ibm.ws.naming.jndicos.CNContextImpl.lookupExt(CNContextImpl.java:1187)
[2/26/07 15:30:43:248 IST] 2de2d2e4 SystemErr R at com.ibm.ws.naming.jndicos.CNContextImpl.lookup(CNContextImpl.java:1067)
[2/26/07 15:30:43:248 IST] 2de2d2e4 SystemErr R at com.ibm.ws.naming.util.WsnInitCtx.lookup(WsnInitCtx.java:132)
[2/26/07 15:30:43:248 IST] 2de2d2e4 SystemErr R at javax.naming.InitialContext.lookup(InitialContext.java:360)
[2/26/07 15:30:43:248 IST] 2de2d2e4 SystemErr R at com.tangosol.run.jca.CacheAdapter.<init>(CacheAdapter.java:94)
[2/26/07 15:30:43:248 IST] 2de2d2e4 SystemErr R at CacheMessagePublisher.doGet(CacheMessagePublisher.java:46)
[2/26/07 15:30:43:248 IST] 2de2d2e4 SystemErr R at javax.servlet.http.HttpServlet.service(HttpServlet.java:740)
[2/26/07 15:30:43:248 IST] 2de2d2e4 SystemErr R at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
[2/26/07 15:30:43:248 IST] 2de2d2e4 SystemErr R at com.ibm.ws.webcontainer.servlet.StrictServletInstance.doService(StrictServletInstance.java:110)
[2/26/07 15:30:43:248 IST] 2de2d2e4 SystemErr R at com.ibm.ws.webcontainer.servlet.StrictLifecycleServlet._service(StrictLifecycleServlet.java:174)
[2/26/07 15:30:43:248 IST] 2de2d2e4 SystemErr R at com.ibm.ws.webcontainer.servlet.IdleServletState.service(StrictLifecycleServlet.java:313)
[2/26/07 15:30:43:248 IST] 2de2d2e4 SystemErr R at com.ibm.ws.webcontainer.servlet.StrictLifecycleServlet.service(StrictLifecycleServlet.java:116)
[2/26/07 15:30:43:248 IST] 2de2d2e4 SystemErr R at com.ibm.ws.webcontainer.servlet.ServletInstance.service(ServletInstance.java:283)
[2/26/07 15:30:43:248 IST] 2de2d2e4 SystemErr R at com.ibm.ws.webcontainer.servlet.ValidServletReferenceState.dispatch(ValidServletReferenceState.java:42)
[2/26/07 15:30:43:248 IST] 2de2d2e4 SystemErr R at com.ibm.ws.webcontainer.servlet.ServletInstanceReference.dispatch(ServletInstanceReference.java:40)
[2/26/07 15:30:43:248 IST] 2de2d2e4 SystemErr R at com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcher.handleWebAppDispatch(WebAppRequestDispatcher.java:974)
[2/26/07 15:30:43:248 IST] 2de2d2e4 SystemErr R at com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcher.dispatch(WebAppRequestDispatcher.java:555)
[2/26/07 15:30:43:248 IST] 2de2d2e4 SystemErr R at com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcher.forward(WebAppRequestDispatcher.java:200)
[2/26/07 15:30:43:248 IST] 2de2d2e4 SystemErr R at com.ibm.ws.webcontainer.srt.WebAppInvoker.doForward(WebAppInvoker.java:119)
[2/26/07 15:30:43:248 IST] 2de2d2e4 SystemErr R at com.ibm.ws.webcontainer.srt.WebAppInvoker.handleInvocationHook(WebAppInvoker.java:276)
[2/26/07 15:30:43:248 IST] 2de2d2e4 SystemErr R at com.ibm.ws.webcontainer.cache.invocation.CachedInvocation.handleInvocation(CachedInvocation.java:71)
[2/26/07 15:30:43:248 IST] 2de2d2e4 SystemErr R at com.ibm.ws.webcontainer.srp.ServletRequestProcessor.dispatchByURI(ServletRequestProcessor.java:182)
[2/26/07 15:30:43:248 IST] 2de2d2e4 SystemErr R at com.ibm.ws.webcontainer.oselistener.OSEListenerDispatcher.service(OSEListener.java:334)
[2/26/07 15:30:43:248 IST] 2de2d2e4 SystemErr R at com.ibm.ws.webcontainer.http.HttpConnection.handleRequest(HttpConnection.java:56)
[2/26/07 15:30:43:248 IST] 2de2d2e4 SystemErr R at com.ibm.ws.http.HttpConnection.readAndHandleRequest(HttpConnection.java:618)
[2/26/07 15:30:43:248 IST] 2de2d2e4 SystemErr R at com.ibm.ws.http.HttpConnection.run(HttpConnection.java:439)
[2/26/07 15:30:43:248 IST] 2de2d2e4 SystemErr R at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:593)
[2/27/07 11:02:59:106 IST] 6d9ed2e5 SystemErr R (Wrapped) com.ibm.websphere.naming.CannotInstantiateObjectException: Exception occurred while the JNDI NamingManager was processing a javax.naming.Reference object. Root exception is java.lang.NoClassDefFoundError: com/tangosol/util/WrapperException
[2/27/07 11:02:59:106 IST] 6d9ed2e5 SystemErr R at java.lang.Class.getDeclaredConstructors0(Native Method)
[2/27/07 11:02:59:106 IST] 6d9ed2e5 SystemErr R at java.lang.Class.privateGetDeclaredConstructors(Class.java(Compiled Code))
[2/27/07 11:02:59:106 IST] 6d9ed2e5 SystemErr R at java.lang.Class.getConstructor1(Class.java(Compiled Code))
[2/27/07 11:02:59:106 IST] 6d9ed2e5 SystemErr R at java.lang.Class.newInstance3(Class.java(Compiled Code))
[2/27/07 11:02:59:106 IST] 6d9ed2e5 SystemErr R at java.lang.Class.newInstance(Class.java(Compiled Code))
[2/27/07 11:02:59:106 IST] 6d9ed2e5 SystemErr R at com.ibm.ejs.j2c.J2CXAResourceFactory.createMCFEntry(J2CXAResourceFactory.java:344)
[2/27/07 11:02:59:106 IST] 6d9ed2e5 SystemErr R at com.ibm.ejs.j2c.ConnectionFactoryBuilderImpl.createMCFandPM(ConnectionFactoryBuilderImpl.java:1414)
[2/27/07 11:02:59:106 IST] 6d9ed2e5 SystemErr R at com.ibm.ejs.j2c.ConnectionFactoryBuilderImpl.getObjectInstance(ConnectionFactoryBuilderImpl.java:1201)
[2/27/07 11:02:59:106 IST] 6d9ed2e5 SystemErr R at javax.naming.spi.NamingManager.getObjectInstance(NamingManager.java:313)
[2/27/07 11:02:59:106 IST] 6d9ed2e5 SystemErr R at com.ibm.ws.naming.util.Helpers.processSerializedObjectForLookupExt(Helpers.java:873)
[2/27/07 11:02:59:106 IST] 6d9ed2e5 SystemErr R at com.ibm.ws.naming.util.Helpers.processSerializedObjectForLookup(Helpers.java:680)
[2/27/07 11:02:59:106 IST] 6d9ed2e5 SystemErr R at com.ibm.ws.naming.jndicos.CNContextImpl.processResolveResults(CNContextImpl.java:1712)
[2/27/07 11:02:59:106 IST] 6d9ed2e5 SystemErr R at com.ibm.ws.naming.jndicos.CNContextImpl.doLookup(CNContextImpl.java:1567)
[2/27/07 11:02:59:106 IST] 6d9ed2e5 SystemErr R at com.ibm.ws.naming.jndicos.CNContextImpl.doLookup(CNContextImpl.java:1480)
[2/27/07 11:02:59:106 IST] 6d9ed2e5 SystemErr R at com.ibm.ws.naming.jndicos.CNContextImpl.lookupExt(CNContextImpl.java:1187)
[2/27/07 11:02:59:106 IST] 6d9ed2e5 SystemErr R at com.ibm.ws.naming.jndicos.CNContextImpl.lookup(CNContextImpl.java:1067)
[2/27/07 11:02:59:106 IST] 6d9ed2e5 SystemErr R at com.ibm.ws.naming.util.WsnInitCtx.lookup(WsnInitCtx.java:132)
[2/27/07 11:02:59:106 IST] 6d9ed2e5 SystemErr R at javax.naming.InitialContext.lookup(InitialContext.java:360)
[2/27/07 11:02:59:106 IST] 6d9ed2e5 SystemErr R at com.tangosol.run.jca.CacheAdapter.<init>(CacheAdapter.java:94)
[2/27/07 11:02:59:106 IST] 6d9ed2e5 SystemErr R at CacheMessagePublisher.doGet(CacheMessagePublisher.java:46)
[2/27/07 11:02:59:106 IST] 6d9ed2e5 SystemErr R at javax.servlet.http.HttpServlet.service(HttpServlet.java:740)
[2/27/07 11:02:59:106 IST] 6d9ed2e5 SystemErr R at javax.servlet.http.HttpServlet.service(HttpServlet.java(Compiled Code))
[2/27/07 11:02:59:106 IST] 6d9ed2e5 SystemErr R at com.ibm.ws.webcontainer.servlet.StrictServletInstance.doService(StrictServletInstance.java(Compiled Code))
[2/27/07 11:02:59:106 IST] 6d9ed2e5 SystemErr R at com.ibm.ws.webcontainer.servlet.StrictLifecycleServlet._service(StrictLifecycleServlet.java(Compiled Code))
[2/27/07 11:02:59:106 IST] 6d9ed2e5 SystemErr R at com.ibm.ws.webcontainer.servlet.IdleServletState.service(StrictLifecycleServlet.java(Compiled Code))
[2/27/07 11:02:59:106 IST] 6d9ed2e5 SystemErr R at com.ibm.ws.webcontainer.servlet.StrictLifecycleServlet.service(StrictLifecycleServlet.java(Inlined Compiled Code))
[2/27/07 11:02:59:106 IST] 6d9ed2e5 SystemErr R at com.ibm.ws.webcontainer.servlet.ServletInstance.service(ServletInstance.java(Compiled Code))
[2/27/07 11:02:59:106 IST] 6d9ed2e5 SystemErr R at com.ibm.ws.webcontainer.servlet.ValidServletReferenceState.dispatch(ValidServletReferenceState.java(Compiled Code))
[2/27/07 11:02:59:106 IST] 6d9ed2e5 SystemErr R at com.ibm.ws.webcontainer.servlet.ServletInstanceReference.dispatch(ServletInstanceReference.java(Inlined Compiled Code))
[2/27/07 11:02:59:106 IST] 6d9ed2e5 SystemErr R at com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcher.handleWebAppDispatch(WebAppRequestDispatcher.java(Compiled Code))
[2/27/07 11:02:59:106 IST] 6d9ed2e5 SystemErr R at com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcher.dispatch(WebAppRequestDispatcher.java(Compiled Code))
[2/27/07 11:02:59:106 IST] 6d9ed2e5 SystemErr R at com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcher.forward(WebAppRequestDispatcher.java(Compiled Code))
[2/27/07 11:02:59:106 IST] 6d9ed2e5 SystemErr R at com.ibm.ws.webcontainer.srt.WebAppInvoker.doForward(WebAppInvoker.java:119)
[2/27/07 11:02:59:106 IST] 6d9ed2e5 SystemErr R at com.ibm.ws.webcontainer.srt.WebAppInvoker.handleInvocationHook(WebAppInvoker.java:276)
[2/27/07 11:02:59:106 IST] 6d9ed2e5 SystemErr R at com.ibm.ws.webcontainer.cache.invocation.CachedInvocation.handleInvocation(CachedInvocation.java:71)
[2/27/07 11:02:59:106 IST] 6d9ed2e5 SystemErr R at com.ibm.ws.webcontainer.srp.ServletRequestProcessor.dispatchByURI(ServletRequestProcessor.java:182)
[2/27/07 11:02:59:106 IST] 6d9ed2e5 SystemErr R at com.ibm.ws.webcontainer.oselistener.OSEListenerDispatcher.service(OSEListener.java:334)
[2/27/07 11:02:59:106 IST] 6d9ed2e5 SystemErr R at com.ibm.ws.webcontainer.http.HttpConnection.handleRequest(HttpConnection.java:56)
[2/27/07 11:02:59:106 IST] 6d9ed2e5 SystemErr R at com.ibm.ws.http.HttpConnection.readAndHandleRequest(HttpConnection.java(Compiled Code))
[2/27/07 11:02:59:106 IST] 6d9ed2e5 SystemErr R at com.ibm.ws.http.HttpConnection.run(HttpConnection.java(Compiled Code))
[2/27/07 11:02:59:106 IST] 6d9ed2e5 SystemErr R at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java(Compiled Code))
The WrapperException class is within tangosol.jar which is present in manifest reference of war file, so I am not able to understand why this exception should come.
Any help on this matter is highly appreciated - since without resolving this issue I cannot evaluate the transactional abilities of Coherence.
Pls let me know if you want me to send u additional details/the ear itself?
regards,
Sanjeev. -
Attempted to use a 5.0 DataSource outside of a 2.3 servlet
I am using WAS 5.0 with Oracle 9.2 . I cannot get a servlet to work with the datasource 5.0 . Any ideas??
The message I get is :
[2/26/04 11:17:28:984 GMT-06:00] 20bfba44 Helpers W NMSV0610I: A NamingException is being thrown from a javax.naming.Context implementation. Details follow:
Context implementation: com.ibm.ws.naming.jndicos.CNContextImpl
Context method: lookup
Context name: localhost/nodes/localhost/servers/server1
Target name: jdbc/WMBDatasource
Other data:
Exception stack trace: com.ibm.websphere.naming.CannotInstantiateObjectException: Exception occurred while the JNDI NamingManager was processing a javax.naming.Reference object. Root exception is java.lang.Exception: Attempted to use a 5.0 DataSource outside of a 2.3 servlet
at com.ibm.ws.naming.jndicos.CNContextImpl.lookup(CNContextImpl.java:1179)
My Servlet code is :
public class SimpleServlet extends HttpServlet {
public void doGet(HttpServletRequest req, HttpServletResponse resp)
throws ServletException, IOException
javax.sql.DataSource ds = null;
java.sql.Connection con = null;
java.io.PrintWriter out = resp.getWriter();
resp.setContentType("text/html");
try
out.println("Looking up DataSource<br>");
javax.naming.InitialContext ctx = new javax.naming.InitialContext();
ds = (javax.sql.DataSource) ctx.lookup("jdbc/WMBDatasource");
out.println("Getting connection<br>");
con = ds.getConnection();
con.close();
catch (Exception e)
e.printStackTrace(out);
out.println("Done<br>");hi vijay ,
i am using wasd5.1 ,and i am trying to access database thru datasource and i had created one javawebapplication and one server(test enviroument with data source ), and i had created this class inside web application, and i am running this class as a java application , but i am getting output like
Before Context
After Context
In Exception
com.ibm.websphere.naming.CannotInstantiateObjectException: Exception occurred while the JNDI NamingManager was processing a javax.naming.Reference object. [Root exception is java.lang.Exception: Failed security check. Client is not permitted to create connection factory jdbc/db]
please help me to get out of this problem
/*please see code first*/
import java.sql.SQLException;
import java.util.Properties;
import java.sql.Connection;
import javax.naming.*;
import javax.sql.DataSource;
import java.sql.DriverManager;
import java.util.*;
public class checkclass
//private static String OWD2_DATASOURCE ="jdbc/db";
private static String INITIAL_CONTEXT_FACTORY "com.ibm.websphere.naming.WsnInitialContextFactory";
public static void main (String args[])
try{
Hashtable jndiProperties = new Hashtable();
jndiProperties.put(Context.INITIAL_CONTEXT_FACTORY,INITIAL_CONTEXT_FACTORY);
jndiProperties.put(Context.PROVIDER_URL,"iiop://localhost:2809");
jndiProperties.put(Context.REFERRAL, "throw");
System.out.println("Before Context");
javax.naming.Context ctx = new javax.naming.InitialContext(jndiProperties);
System.out.println("After Context");
DataSource ds = (javax.sql.DataSource)ctx.lookup("jdbc/db");
ctx.close();
System.out.println("After DataSource");
Connection con = ds.getConnection();
System.out.println("After Getting Connection");
con.close();
System.out.println("After Closing Connection");
catch(Exception e)
System.out.println("In Exception");
System.out.println(e);
} -
Error connecting to Sybase database through WSAD
In my jsp page I am trying to connect to Sybase database within WSAD.
Here is my code:
InitialContext ctx = new InitialContext();
DataSource ds = (DataSource) ctx.lookup("jdbc/AimDB");
Connection con = ds.getConnection();
It is giving an error message:
Error 500: Exception occurred while the JNDI NamingManager was processing a javax.naming.Reference object.
On console below error message is coming:
E SRVE0026E: [Servlet Error]-[Exception occurred while the JNDI NamingManager was processing a javax.naming.Reference object.]: com.ibm.websphere.naming.CannotInstantiateObjectException: Exception occurred while the JNDI NamingManager was processing a javax.naming.Reference object. Root exception is java.lang.Exception: Failed security check. Client is not permitted to create connection factory jdbc/AimDB
at com.ibm.ejs.j2c.ConnectionFactoryBuilderImpl.createMCFandPM(ConnectionFactoryBuilderImpl.java:1566)
at com.ibm.ejs.j2c.ConnectionFactoryBuilderImpl.getObjectInstance(ConnectionFactoryBuilderImpl.java:1188)
at javax.naming.spi.NamingManager.getObjectInstance(NamingManager.java:313)
at com.ibm.ws.naming.util.Helpers.processSerializedObjectForLookup(Helpers.java:884)
at com.ibm.ws.naming.jndicos.CNContextImpl.processResolveResults(CNContextImpl.java:1762)
at com.ibm.ws.naming.jndicos.CNContextImpl.doLookup(CNContextImpl.java:1615)
at com.ibm.ws.naming.jndicos.CNContextImpl.doLookup(CNContextImpl.java:1525)
at com.ibm.ws.naming.jndicos.CNContextImpl.lookup(CNContextImpl.java:1225)
at com.ibm.ws.naming.util.WsnInitCtx.lookup(WsnInitCtx.java:132)
at javax.naming.InitialContext.lookup(InitialContext.java:359)
at org.apache.jsp._Test1._jspService(_Test1.java:89)
Thanks,
VineetHi ,
Any body have this solution ??? I am using wsad -5.1.2 .When I try to access datasource from test server I got this same problems....
I tried whatever instructs in above link.But after that I got same problem ....
Sorry,for bad english
advance thanks -
SetRepo command to view the current Index repository location
Hi,
I am using the following command to view the current location of the index repository.
./lh -Djava.ext.dirs=/usr/WebSphere/AppServer/java/jre/lib/ext:/usr/WebSphere/AppServer/lib setRepo -icom.ibm.websphere.naming.WsnInitialContextFactory -c
However I get the following error
Feb 11, 2009 5:08:28 PM com.ibm.ejs.j2c.ConnectionFactoryBuilderImpl
SEVERE: SET_METHOD_EXCP_J2CA0036
Feb 11, 2009 5:08:29 PM com.ibm.ejs.j2c.ConnectionFactoryBuilderImpl
SEVERE: CREATE_MANAGED_CONNECTION_FACTORY_DETAILS_EXCP_J2CA0009
Feb 11, 2009 5:08:29 PM com.ibm.ws.naming.util.Helpers
WARNING: jndiGetObjInstErr
Feb 11, 2009 5:08:29 PM com.ibm.ws.naming.util.Helpers
WARNING: jndiNamingException
com.ibm.websphere.naming.CannotInstantiateObjectException: Exception occurred while the JNDI NamingManager was processing a javax.naming.Reference object. [Root exception is java.lang.reflect.InvocationTargetException]
Cannot reach current repository location:com.waveset.util.ConfigurationError: Failed to load JDBC DataSource 'jdbc/eumdevrepo2':
==> com.ibm.websphere.naming.CannotInstantiateObjectException: Exception occurred while the JNDI NamingManager was processing a javax.naming.Reference object
From my appserver admin console, I am able to test my datasource and it works fine without any issues. any ideas as to what could be the problem?
thanksHi ,
No, there is not a shortcut keyboard command to insert the current date into a Date cell in Datasheet view.
For your issue, you can set the default value of the Date column to “Today’s Date”:
Go to your list -> List Settings -> select the Date column
under Columns section.
Select “Today’s Date” to default value.
Best Regards,
Eric
Eric Tao
TechNet Community Support -
Migrating issue from ibm jdk to sun jdk and from WAS5.0 to WAS6.1
hi,
while creating ConnectionFactory i am getting the following error:
com.ibm.websphere.naming.CannotInstantiateObjectException: Exception occurred while the JNDI NamingManager was processing a javax.naming.Reference object. [Root exception is java.lang.NoClassDefFoundError: Invalid Implementation Key, com.ibm.ws.transaction.NonRecovWSTxManager]
Using SUN JDK5 , WAS6.1
I have included com.ibm.ws.runtime_6.1.0.jar and com.ibm.ws.webservices.thinclient_6.1.0.jar in my buildpath but still i am getting the exception.
Can anybody point out where i found this class?
plz help,
Thanks in advance...Hi,
I have exactly identical probelm. Do you have any solution to it? Would you please share here.
Thank you. -
Urgent----unbale to lookup queueconnection factory in webphere
hi,
i configured queueconnection factory as well as queue in websphere 6.1 server.
i had taken a standalone project in WSAD IDE as well as RAD7 , and i try to look up the connection factory. i am getting the intial conetxt and unable to looup the factory object.
the same code i pasted in a jsp it is working fine wothout any issues.
if i run from a standalone i am facing the following problem.
com.ibm.websphere.naming.CannotInstantiateObjectException: Exception occurred while the JNDI NamingManager was processing a javax.naming.Reference object. [com.ibm.websphere.naming.CannotInstantiateObjectException: Exception occurred while the JNDI NamingManager was processing a javax.naming.Reference object. [*Root exception is java.lang.NoClassDefFoundError: com.ibm.ws.sib.utils.ras.SibTr*]
at com.ibm.ws.naming.util.Helpers.processSerializedObjectForLookupExt(Helpers.java:1000)
at com.ibm.ws.naming.util.Helpers.processSerializedObjectForLookup(Helpers.java:705)
at com.ibm.ws.naming.jndicos.CNContextImpl.processResolveResults(CNContextImpl.java:2093)
at com.ibm.ws.naming.jndicos.CNContextImpl.doLookup(CNContextImpl.java:1947)
at com.ibm.ws.naming.jndicos.CNContextImpl.doLookup(CNContextImpl.java:1862)
at com.ibm.ws.naming.jndicos.CNContextImpl.lookupExt(CNContextImpl.java:1552)
at com.ibm.ws.naming.jndicos.CNContextImpl.lookup(CNContextImpl.java:1354)
at com.ibm.ws.naming.util.WsnInitCtx.lookup(WsnInitCtx.java:172)
at javax.naming.InitialContext.lookup(InitialContext.java:363)
at com.mits.providers.QueueSender.createReceiver(QueueSender.java:57)
at com.mits.providers.QueueSender.main(QueueSender.java:36)
Caused by: java.lang.NoClassDefFoundError: com.ibm.ws.sib.utils.ras.SibTr
at com.ibm.ws.sib.api.jmsra.impl.JmsJcaManagedConnectionFactoryImpl.<clinit>(JmsJcaManagedConnectionFactoryImpl.java:180)
at java.lang.J9VMInternals.initializeImpl(Native Method)
at java.lang.J9VMInternals.initialize(J9VMInternals.java:177)
at java.lang.J9VMInternals.initialize(J9VMInternals.java:144)
at java.lang.Class.newInstanceImpl(Native Method)
at java.lang.Class.newInstance(Class.java:1263)
at com.ibm.ejs.j2c.ConnectionFactoryBuilderImpl.createMCF(ConnectionFactoryBuilderImpl.java:1342)
at com.ibm.ejs.j2c.ConnectionFactoryBuilderImpl.processObjectInstance(ConnectionFactoryBuilderImpl.java:663)
at com.ibm.ejs.j2c.ConnectionFactoryBuilderImpl.getObjectInstance(ConnectionFactoryBuilderImpl.java:613)
at javax.naming.spi.NamingManager.getObjectInstance(NamingManager.java:316)
at com.ibm.ws.naming.util.Helpers.processSerializedObjectForLookupExt(Helpers.java:896)
... 10 more]
at com.ibm.ws.naming.util.Helpers.processSerializedObjectForLookupExt(Helpers.java:1000)
at com.ibm.ws.naming.util.Helpers.processSerializedObjectForLookup(Helpers.java:705)
at com.ibm.ws.naming.jndicos.CNContextImpl.processResolveResults(CNContextImpl.java:2093)
at com.ibm.ws.naming.jndicos.CNContextImpl.doLookup(CNContextImpl.java:1947)
at com.ibm.ws.naming.jndicos.CNContextImpl.doLookup(CNContextImpl.java:1862)
at com.ibm.ws.naming.jndicos.CNContextImpl.lookupExt(CNContextImpl.java:1552)
at com.ibm.ws.naming.jndicos.CNContextImpl.lookup(CNContextImpl.java:1354)
at com.ibm.ws.naming.util.WsnInitCtx.lookup(WsnInitCtx.java:172)
at javax.naming.InitialContext.lookup(InitialContext.java:363)
at com.mits.providers.QueueSender.createReceiver(QueueSender.java:57)
at com.mits.providers.QueueSender.main(QueueSender.java:36)
Caused by: java.lang.NoClassDefFoundError: com.ibm.ws.sib.utils.ras.SibTr
at com.ibm.ws.sib.api.jmsra.impl.JmsJcaManagedConnectionFactoryImpl.<clinit>(JmsJcaManagedConnectionFactoryImpl.java:180)
at java.lang.J9VMInternals.initializeImpl(Native Method)
at java.lang.J9VMInternals.initialize(J9VMInternals.java:177)
at java.lang.J9VMInternals.initialize(J9VMInternals.java:144)
at java.lang.Class.newInstanceImpl(Native Method)
at java.lang.Class.newInstance(Class.java:1263)
at com.ibm.ejs.j2c.ConnectionFactoryBuilderImpl.createMCF(ConnectionFactoryBuilderImpl.java:1342)
at com.ibm.ejs.j2c.ConnectionFactoryBuilderImpl.processObjectInstance(ConnectionFactoryBuilderImpl.java:663)
at com.ibm.ejs.j2c.ConnectionFactoryBuilderImpl.getObjectInstance(ConnectionFactoryBuilderImpl.java:613)
at javax.naming.spi.NamingManager.getObjectInstance(NamingManager.java:316)
at com.ibm.ws.naming.util.Helpers.processSerializedObjectForLookupExt(Helpers.java:896)
... 10 more
i added the following jars,
naming.jar,namingclient.jar.namingsever.jar,ffdc.jar.ras.jar,j2ee.jar,implfactory.jar,iwsorb.jar,j2cimpl.jar,javax.jms.jar,jms.jar,icu4j.jar,
schedularclient.jar and schedularservice.jar, messageclient.jar.Hi,
One reason for this is when we are running that from standalone application the initial context for standalone application won't be same as the Server's initial context where connection factory is configured. Try giving environment to set the initial context for the server. Then it can lookup the JNDI which is there in the server using initial context object.
Eg: Instead of giving InitialContext ctx = new InitialContext();
give:
=======
Hashtable env = new Hashtable();
env.put(Context.INITIAL_CONTEXT_FACTORY,
"com.ibm.websphere.naming.WsnInitialContextFactory");
env.put(Context.PROVIDER_URL, "corbaloc:iiop:myhost.mycompany.com:2809");
InitialContext ctx = new InitialContext(env);
Maybe you are looking for
-
Why do I get a black screen when I start my macbook pro?
why do I get a black screen when I start my MacBook pro?
-
How to translate BW 3.5 objects.
Hi Gurus, How to transalate BW 3.5 objects other than english language and procedure to transport. Thanks in advance, Anil
-
Stacks - how to access ALL files? (those that don't show)
I have my Application folder in my dock. I used to, under tiger, click on it. type 'v'... 'p'.... then apple-O to get my VPN client. type 'v'...'i'.. then apple-O to get visual hub. Or I could click then scroll around in the folder to find the apps I
-
Since switching to firefox my hotmail spell check is switched off how do I activate it
I have recently switched to firefox and my spell check on hotmail is not now working - I believe the two events are linked
-
Hi SDNers. What is the most common/used business content related to HR? (Infoproviders and which ds goes with them.) Or do you know a link I could get the info. Help.sap.com does not discriminate between most common and rarely used. Thanks. Shahid