• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Exception while EJB deployement

 
Greenhorn
Posts: 14
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,
I am trying to deploy ejb on weblogic 6.0 server. I am getting following exception ... Pl. help me to understand the exception and solve the problem
The exception is :
weblogic.ejb20.cmp.rdbms.RDBMSException: JNDI lookup of JDBC datasource 'MyJDBC Data Source' failed : javax.naming.NameNotFoundException: Unable to resolve MyJDBC Data Source. Resolved: '' Unresolved:
'MyJDBC Data Source' ; remaining name ''
<<no stack trace available>>
at weblogic.ejb20.cmp.rdbms.RDBMSPersistenceManager.setup(RDBMSPersistenceManager.java:71)
at weblogic.ejb20.internal.EntityEJBHome.setBeanInfo(EntityEJBHome.java:152)
at weblogic.ejb20.deployer.ClientDrivenBeanInfoImpl.deploy(ClientDrivenBeanInfoImpl.java:474)
at weblogic.ejb20.deployer.Deployer.deployDescriptor(Deployer.java:1105)
at weblogic.ejb20.deployer.Deployer.deploy(Deployer.java:908)
at weblogic.j2ee.EJBComponent.deploy(EJBComponent.java:31)
at weblogic.j2ee.Application.addComponent(Application.java:133)
at weblogic.j2ee.J2EEService.addDeployment(J2EEService.java:115)
at weblogic.management.mbeans.custom.DeploymentTarget.addDeployment(DeploymentTarget.java:327)
at weblogic.management.mbeans.custom.DeploymentTarget.addDeployments(DeploymentTarget.java:277)
at weblogic.management.mbeans.custom.DeploymentTarget.updateServerDeployments(DeploymentTarget.java:232)
at weblogic.management.mbeans.custom.DeploymentTarget.updateDeployments(DeploymentTarget.java:192)
at java.lang.reflect.Method.invoke(Native Method)
at weblogic.management.internal.DynamicMBeanImpl.invokeLocally(DynamicMBeanImpl.java:562)
at weblogic.management.internal.DynamicMBeanImpl.invoke(DynamicMBeanImpl.java:548)
at weblogic.management.internal.ConfigurationMBeanImpl.invoke(ConfigurationMBeanImpl.java:285)
at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:1555)
at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:1523)
at weblogic.management.internal.MBeanProxy.invoke(MBeanProxy.java:439)
at weblogic.management.internal.MBeanProxy.invoke(MBeanProxy.java:180)
at $Proxy29.updateDeployments(Unknown Source)
at weblogic.management.configuration.ServerMBean_CachingStub.updateDeployments(ServerMBean_CachingStub.java:2299)
at weblogic.management.mbeans.custom.ApplicationManager.startConfigManager(ApplicationManager.java:240)
at weblogic.management.mbeans.custom.ApplicationManager.start(ApplicationManager.java:122)
at java.lang.reflect.Method.invoke(Native Method)
at weblogic.management.internal.DynamicMBeanImpl.invokeLocally(DynamicMBeanImpl.java:562)
at weblogic.management.internal.DynamicMBeanImpl.invoke(DynamicMBeanImpl.java:548)
at weblogic.management.internal.ConfigurationMBeanImpl.invoke(ConfigurationMBeanImpl.java:285)
at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:1555)
at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:1523)
at weblogic.management.internal.MBeanProxy.invoke(MBeanProxy.java:439)
at weblogic.management.internal.MBeanProxy.invoke(MBeanProxy.java:180)
at $Proxy23.start(Unknown Source)
at weblogic.management.configuration.ApplicationManagerMBean_CachingStub.start(ApplicationManagerMBean_CachingStub.java:435)
at weblogic.management.Admin.startApplicationManager(Admin.java:1033)
at weblogic.management.Admin.finish(Admin.java:493)
at weblogic.t3.srvr.T3Srvr.start(T3Srvr.java:429)
at weblogic.t3.srvr.T3Srvr.run(T3Srvr.java:170)
at weblogic.Server.main(Server.java:35)
>
<Aug 10, 2001 4:24:20 PM GMT+05:30> <Error> <J2EE> <Error deploying application dtry: Could not deploy: 'dtry.jar'
Possible reasons include:
1. The bean or an interface class has been modified but
the deployment descriptor has not been updated
2. The database mappings in the deployment descriptor do not
match the database definition
3. The jar file is not a valid jar file
4. The jar file does not contain a valid bean>
Thanks,
Nabha
 
Ranch Hand
Posts: 919
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
It looks to me as though your JNDI reference to your JDBC DataSource is incorrectly mapped (or possibly not mapped at all), and consequently when your bean looks it up it can't find it.
I would re-check your JNDI datasource mappings if I was you.
 
Nabha Panat
Greenhorn
Posts: 14
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Dear George,
Will you please explain me where excatly I should look for the mapping. I am new to EJBs and Weblogic 6.0 and today bit confused. Will you help me ?
Thanks,
Nabha
 
Ranch Hand
Posts: 1871
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
It looks as if you are writing a entity bean. You need to specify the pool in the weblogic-ejb-jar.xml file. Check up if the pool is specified along with the table. You may have forgotten to specify this pool or have specified it wrongly.
------------------

Mahindrakar
IBM Application Server Forum Moderator
Consultant - Zensar Technologies.
SCJP2, SCJD2 & SCJEA (Part I)

[This message has been edited by Rahul Mahindrakar (edited September 04, 2001).]

[This message has been edited by Rahul Mahindrakar (edited September 04, 2001).]
 
Rahul Mahindrakar
Ranch Hand
Posts: 1871
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I have written a servlet that access data from the connection pool. Check up the servlet code below. You will need a table called "test" for this to work
 
Rahul Mahindrakar
Ranch Hand
Posts: 1871
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
My DataSource JNDI name is oracle1 and looks like yours is 'MyJDBC Data Source'.
check up if
1) spaces are allowed in the pool as your name has spaces
2) click on the Targets tab and see if the pool is "choosen" same is the case for the DataSource
------------------

Mahindrakar
IBM Application Server Forum Moderator
Consultant - Zensar Technologies.
SCJP2, SCJD2 & SCJEA (Part I)

[This message has been edited by Rahul Mahindrakar (edited September 04, 2001).]
 
Nabha Panat
Greenhorn
Posts: 14
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Dear Rahul and Gorge,
Thank you both. The above exception was misleading ...
It was about the entry of data-source-name in weblogic-cmp-rdbms-jar.xml and the URL for the oracle driver.
The correct entry is: <data-source-name>nabha</data-source-name>
I have created the data-source using admin console in which mentioned the connection pool name and jndi name. It is as follows:
<JDBCDataSource JNDIName="nabha" Name="nabha" PoolName="MyPool" Targets="myserver"/>
Then I have created connection pool using admin console:
<JDBCConnectionPool CapacityIncrement="1" DeploymentOrder="1000"
DriverName="oracle.jdbc.driver.OracleDriver" InitialCapacity="0"
JDBCXADebugLevel="0" LoginDelaySeconds="0" MaxCapacity="5"
Name="MyPool" Properties="password=pwd;username=unm"
RefreshMinutes="0" ShrinkPeriodMinutes="15"
ShrinkingEnabled="true" SupportsLocalTransaction="false"
Targets="myserver" TestConnectionsOnRelease="false"
TestConnectionsOnReserve="false" URL="jdbc racle:thin:username/password@host ort:sid"/>
The bean is deployed.
Nabha

 
Rahul Mahindrakar
Ranch Hand
Posts: 1871
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Things work and thats great
reply
    Bookmark Topic Watch Topic
  • New Topic