Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » EclipseLink » DBWS Error on Deployment(DBWS eclipselink jboss)
DBWS Error on Deployment [message #1007871] Thu, 07 February 2013 20:35 Go to next message
Jay Royse is currently offline Jay RoyseFriend
Messages: 3
Registered: February 2013
Junior Member
Hi, I am attempting to build a simple WS to CRUD one Oracle DB table. I am using the DBWS utility to build the WS. I have generated the WAR file successfully, however I am getting an eror when deploying to JBoss AS. Please help. I am a novice at Java and could be missing something very simple. In Eclipse I see that the _dbws.DBWSProvider class is in the WAR file.

JBoss server error:
14:19:16,356 WARN  [org.jboss.modules] (MSC service thread 1-15) Failed to define class _dbws.DBWSProvider in Module "deployment.surplus.war:main" from Service Module Loader: java.lang.LinkageError: Failed to link _dbws/DBWSProvider (Module "deployment.surplus.war:main" from Service Module Loader)
	at org.jboss.modules.ModuleClassLoader.defineClass(ModuleClassLoader.java:396)
	at org.jboss.modules.ModuleClassLoader.loadClassLocal(ModuleClassLoader.java:243)
	at org.jboss.modules.ModuleClassLoader$1.loadClassLocal(ModuleClassLoader.java:73)
	at org.jboss.modules.Module.loadModuleClass(Module.java:517)
	at org.jboss.modules.ModuleClassLoader.findClass(ModuleClassLoader.java:182)
	at org.jboss.modules.ConcurrentClassLoader.performLoadClassUnchecked(ConcurrentClassLoader.java:468)
	at org.jboss.modules.ConcurrentClassLoader.performLoadClassChecked(ConcurrentClassLoader.java:456)
	at org.jboss.modules.ConcurrentClassLoader.performLoadClass(ConcurrentClassLoader.java:398)
	at org.jboss.modules.ConcurrentClassLoader.loadClass(ConcurrentClassLoader.java:120)
	at java.lang.Class.forName0(Native Method) [rt.jar:1.7.0_11]
	at java.lang.Class.forName(Class.java:264) [rt.jar:1.7.0_11]
	at org.jboss.as.server.deployment.reflect.DeploymentClassIndex.classIndex(DeploymentClassIndex.java:54)
	at org.jboss.as.ee.component.deployers.InterceptorAnnotationProcessor.processComponentConfig(InterceptorAnnotationProcessor.java:63) [jboss-as-ee-7.1.1.Final.jar:7.1.1.Final]
	at org.jboss.as.ee.component.deployers.InterceptorAnnotationProcessor.deploy(InterceptorAnnotationProcessor.java:55) [jboss-as-ee-7.1.1.Final.jar:7.1.1.Final]
	at org.jboss.as.server.deployment.DeploymentUnitPhaseService.start(DeploymentUnitPhaseService.java:113)
	at org.jboss.msc.service.ServiceControllerImpl$StartTask.startService(ServiceControllerImpl.java:1811)
	at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceControllerImpl.java:1746)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110) [rt.jar:1.7.0_11]
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603) [rt.jar:1.7.0_11]
	at java.lang.Thread.run(Thread.java:722) [rt.jar:1.7.0_11]
Caused by: java.lang.NoClassDefFoundError: org/eclipse/persistence/internal/dbws/ProviderHelper
	at java.lang.ClassLoader.defineClass1(Native Method) [rt.jar:1.7.0_11]
	at java.lang.ClassLoader.defineClass(ClassLoader.java:791) [rt.jar:1.7.0_11]
	at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142) [rt.jar:1.7.0_11]
	at org.jboss.modules.ModuleClassLoader.doDefineOrLoadClass(ModuleClassLoader.java:327)
	at org.jboss.modules.ModuleClassLoader.defineClass(ModuleClassLoader.java:391)
	... 19 more
Caused by: java.lang.ClassNotFoundException: org.eclipse.persistence.internal.dbws.ProviderHelper from [Module "deployment.surplus.war:main" from Service Module Loader]
	at org.jboss.modules.ModuleClassLoader.findClass(ModuleClassLoader.java:190)
	at org.jboss.modules.ConcurrentClassLoader.performLoadClassUnchecked(ConcurrentClassLoader.java:468)
	at org.jboss.modules.ConcurrentClassLoader.performLoadClassChecked(ConcurrentClassLoader.java:456)
	at org.jboss.modules.ConcurrentClassLoader.performLoadClass(ConcurrentClassLoader.java:398)
	at org.jboss.modules.ConcurrentClassLoader.loadClass(ConcurrentClassLoader.java:120)
	... 24 more

14:19:16,392 WARN  [org.jboss.modules] (MSC service thread 1-16) Failed to define class _dbws.DBWSProvider in Module "deployment.surplus.war:main" from Service Module Loader: java.lang.LinkageError: Failed to link _dbws/DBWSProvider (Module "deployment.surplus.war:main" from Service Module Loader)
	at org.jboss.modules.ModuleClassLoader.defineClass(ModuleClassLoader.java:396)
	at org.jboss.modules.ModuleClassLoader.loadClassLocal(ModuleClassLoader.java:243)
	at org.jboss.modules.ModuleClassLoader$1.loadClassLocal(ModuleClassLoader.java:73)
	at org.jboss.modules.Module.loadModuleClass(Module.java:517)
	at org.jboss.modules.ModuleClassLoader.findClass(ModuleClassLoader.java:182)
	at org.jboss.modules.ConcurrentClassLoader.performLoadClassUnchecked(ConcurrentClassLoader.java:468)
	at org.jboss.modules.ConcurrentClassLoader.performLoadClassChecked(ConcurrentClassLoader.java:456)
	at org.jboss.modules.ConcurrentClassLoader.performLoadClass(ConcurrentClassLoader.java:398)
	at org.jboss.modules.ConcurrentClassLoader.loadClass(ConcurrentClassLoader.java:120)
	at java.lang.Class.forName0(Native Method) [rt.jar:1.7.0_11]
	at java.lang.Class.forName(Class.java:264) [rt.jar:1.7.0_11]
	at org.jboss.as.server.deployment.reflect.DeploymentClassIndex.classIndex(DeploymentClassIndex.java:54)
	at org.jboss.as.ee.component.deployers.EEModuleConfigurationProcessor.deploy(EEModuleConfigurationProcessor.java:79) [jboss-as-ee-7.1.1.Final.jar:7.1.1.Final]
	at org.jboss.as.server.deployment.DeploymentUnitPhaseService.start(DeploymentUnitPhaseService.java:113)
	at org.jboss.msc.service.ServiceControllerImpl$StartTask.startService(ServiceControllerImpl.java:1811)
	at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceControllerImpl.java:1746)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110) [rt.jar:1.7.0_11]
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603) [rt.jar:1.7.0_11]
	at java.lang.Thread.run(Thread.java:722) [rt.jar:1.7.0_11]
Caused by: java.lang.NoClassDefFoundError: org/eclipse/persistence/internal/dbws/ProviderHelper
	at java.lang.ClassLoader.defineClass1(Native Method) [rt.jar:1.7.0_11]
	at java.lang.ClassLoader.defineClass(ClassLoader.java:791) [rt.jar:1.7.0_11]
	at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142) [rt.jar:1.7.0_11]
	at org.jboss.modules.ModuleClassLoader.doDefineOrLoadClass(ModuleClassLoader.java:327)
	at org.jboss.modules.ModuleClassLoader.defineClass(ModuleClassLoader.java:391)
	... 18 more
Caused by: java.lang.ClassNotFoundException: org.eclipse.persistence.internal.dbws.ProviderHelper from [Module "deployment.surplus.war:main" from Service Module Loader]
	at org.jboss.modules.ModuleClassLoader.findClass(ModuleClassLoader.java:190)
	at org.jboss.modules.ConcurrentClassLoader.performLoadClassUnchecked(ConcurrentClassLoader.java:468)
	at org.jboss.modules.ConcurrentClassLoader.performLoadClassChecked(ConcurrentClassLoader.java:456)
	at org.jboss.modules.ConcurrentClassLoader.performLoadClass(ConcurrentClassLoader.java:398)
	at org.jboss.modules.ConcurrentClassLoader.loadClass(ConcurrentClassLoader.java:120)
	... 23 more

14:19:16,427 WARN  [org.jboss.as.ee] (MSC service thread 1-16) JBAS011006: Not installing optional component _dbws.DBWSProvider due to exception: java.lang.ClassNotFoundException: _dbws.DBWSProvider from [Module "deployment.surplus.war:main" from Service Module Loader]

  • Attachment: surplus.war
    (Size: 8.95KB, Downloaded 82 times)
Re: DBWS Error on Deployment [message #1008039 is a reply to message #1007871] Fri, 08 February 2013 15:45 Go to previous messageGo to next message
David McCann is currently offline David McCannFriend
Messages: 20
Registered: July 2009
Junior Member
From the looks of the stack trace, eclipselink.jar isn't on the server classpath. This is required since our web service provider is used at runtime to handle the service request/response duties. I believe that JBoss typically expects to find the JAR in <JBOSS_HOME>/server/default/lib.

Also, this exception occurs when the datasource isn't configured correctly; if you haven't already, you'll need to configure the datasource passed to the DBWS builder utility on your JBoss server instance.

--Dave
Re: DBWS Error on Deployment [message #1008317 is a reply to message #1008039] Mon, 11 February 2013 21:43 Go to previous messageGo to next message
Jay Royse is currently offline Jay RoyseFriend
Messages: 3
Registered: February 2013
Junior Member
thank you Dave. I installed the JAR as a module (AS 7.1) and ensured the JAR file versions were the same. that seemed to resolve the Error. Now I am getting a separate error about the Provider class not being able to be cast to Servlet.

_dbws.DBWSProvider cannot be cast to javax.servlet.Servlet.

I have ALL the jars used by DBWS in the /WEB-INF/lib directory:

$ jar -xvf surplus1.3.war
inflated: META-INF/MANIFEST.MF
created: META-INF/
created: WEB-INF/
created: WEB-INF/classes/
created: WEB-INF/classes/META-INF/
inflated: WEB-INF/classes/META-INF/eclipselink-dbws-or.xml
inflated: WEB-INF/classes/META-INF/eclipselink-dbws-ox.xml
inflated: WEB-INF/classes/META-INF/eclipselink-dbws-sessions.xml
inflated: WEB-INF/classes/META-INF/eclipselink-dbws.xml
created: WEB-INF/classes/_dbws/
inflated: WEB-INF/classes/_dbws/DBWSProvider.java
inflated: WEB-INF/classes/_dbws/ProviderListener.java
inflated: WEB-INF/classes/_dbws/DBWSProvider.class
inflated: WEB-INF/classes/_dbws/ProviderListener.class
inflated: WEB-INF/jboss-web.xml
created: WEB-INF/lib/
inflated: WEB-INF/lib/eclipselink-2.4.0.jar
inflated: WEB-INF/lib/eclipselink-dbwsutils.jar
inflated: WEB-INF/lib/javax.servlet_2.4.0.v200806031604.jar
inflated: WEB-INF/lib/javax.wsdl_1.6.2.v201012040545.jar
inflated: WEB-INF/lib/ojdbc6.jar
inflated: WEB-INF/lib/org.eclipse.persistence.oracleddlparser_1.0.0.v20120628.jar
inflated: WEB-INF/web.xml
created: WEB-INF/wsdl/
inflated: WEB-INF/wsdl/eclipselink-dbws-schema.xsd
inflated: WEB-INF/wsdl/eclipselink-dbws.wsdl

15:27:36,374 INFO  [org.jboss.as.server.deployment] (MSC service thread 1-6) JBAS015876: Starting deployment of "surplus1.3.war"

15:27:39,105 INFO  [stdout] (MSC service thread 1-10) ))

15:27:39,105 INFO  [stdout] (MSC service thread 1-10) [EL Config]: connection: 2013-02-11 15:27:39.105--ServerSession(804864197)--Connection(1851283217)--Thread(Thread[MSC service thread 1-10,5,main])--Connected: jdbc:oracle:thin:@server:1521:instance

15:27:39,106 INFO  [stdout] (MSC service thread 1-10) 	User: user

15:27:39,107 INFO  [stdout] (MSC service thread 1-10) 	Database: Oracle  Version: Oracle Database 11g Release 11.2.0.3.0 - 64bit Production

15:27:39,107 INFO  [stdout] (MSC service thread 1-10) 	Driver: Oracle JDBC driver  Version: 11.2.0.3.0

15:27:39,110 INFO  [stdout] (MSC service thread 1-10) [EL Info]: connection: 2013-02-11 15:27:39.11--ServerSession(804864197)--Thread(Thread[MSC service thread 1-10,5,main])--surplus_asset-dbws-or-session login successful

15:27:39,113 INFO  [stdout] (MSC service thread 1-10) [EL Finer]: server: 2013-02-11 15:27:39.112--ServerSession(804864197)--Thread(Thread[MSC service thread 1-10,5,main])--JMX MBeanServer instance found: [org.jboss.as.jmx.PluggableMBeanServerImpl@48f514d7], # of beans: [196], domain: [DefaultDomain] at index: [0].

15:27:39,115 INFO  [stdout] (MSC service thread 1-10) [EL Warning]: server: 2013-02-11 15:27:39.115--ServerSession(804864197)--Thread(Thread[MSC service thread 1-10,5,main])--Problem while registering MBean: javax.management.InstanceAlreadyExistsException: TopLink:Name=Development-surplus_asset-dbws-or-session,Type=Configuration

15:27:39,117 INFO  [stdout] (MSC service thread 1-10) [EL Finest]: server: 2013-02-11 15:27:39.117--ServerSession(804864197)--Thread(Thread[MSC service thread 1-10,5,main])--Registered MBean: null on server org.jboss.as.jmx.PluggableMBeanServerImpl@48f514d7

15:27:39,119 INFO  [stdout] (MSC service thread 1-10) [EL Warning]: server: 2013-02-11 15:27:39.119--ServerSession(804864197)--Thread(Thread[MSC service thread 1-10,5,main])--Problem while registering MBean: javax.management.InstanceAlreadyExistsException: TopLink:Name=Session(surplus_asset-dbws-or-session)

15:27:39,121 INFO  [stdout] (MSC service thread 1-10) [EL Finest]: server: 2013-02-11 15:27:39.121--ServerSession(804864197)--Thread(Thread[MSC service thread 1-10,5,main])--Registered MBean: null on server org.jboss.as.jmx.PluggableMBeanServerImpl@48f514d7

15:27:39,123 INFO  [stdout] (MSC service thread 1-10) [EL Finest]: server: 2013-02-11 15:27:39.123--ServerSession(804864197)--Thread(Thread[MSC service thread 1-10,5,main])--EclipseLink JMX Runtime Services is referencing the [Platform ConversionManager] ClassLoader at: [org.eclipse.persistence.internal.xr.XRDynamicClassLoader@1c7bba61]

15:27:39,124 INFO  [stdout] (MSC service thread 1-10) [EL Finest]: server: 2013-02-11 15:27:39.124--ServerSession(804864197)--Thread(Thread[MSC service thread 1-10,5,main])--The applicationName for the MBean attached to session [surplus_asset-dbws-or-session] is [unknown]

15:27:39,126 INFO  [stdout] (MSC service thread 1-10) [EL Finest]: server: 2013-02-11 15:27:39.126--ServerSession(804864197)--Thread(Thread[MSC service thread 1-10,5,main])--The moduleName for the MBean attached to session [surplus_asset-dbws-or-session] is [unknown]

15:27:39,183 INFO  [org.apache.catalina.core.ContainerBase.[jboss.web].[default-host].[/surplusContext]] (MSC service thread 1-10) Marking servlet DBWSProvider as unavailable
15:27:39,184 ERROR [org.apache.catalina.core.ContainerBase.[jboss.web].[default-host].[/surplusContext]] (MSC service thread 1-10) Servlet /surplusContext threw load() exception: java.lang.ClassCastException: _dbws.DBWSProvider cannot be cast to javax.servlet.Servlet
	at org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:1156) [jbossweb-7.0.13.Final.jar:]
	at org.apache.catalina.core.StandardWrapper.load(StandardWrapper.java:1102) [jbossweb-7.0.13.Final.jar:]
	at org.apache.catalina.core.StandardContext.loadOnStartup(StandardContext.java:3655) [jbossweb-7.0.13.Final.jar:]
	at org.apache.catalina.core.StandardContext.start(StandardContext.java:3873) [jbossweb-7.0.13.Final.jar:]
	at org.jboss.as.web.deployment.WebDeploymentService.start(WebDeploymentService.java:90) [jboss-as-web-7.1.1.Final.jar:7.1.1.Final]
	at org.jboss.msc.service.ServiceControllerImpl$StartTask.startService(ServiceControllerImpl.java:1811)
	at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceControllerImpl.java:1746)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110) [rt.jar:1.7.0_11]
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603) [rt.jar:1.7.0_11]
	at java.lang.Thread.run(Thread.java:722) [rt.jar:1.7.0_11]

15:27:39,192 INFO  [org.jboss.web] (MSC service thread 1-10) JBAS018210: Registering web context: /surplusContext
15:27:39,205 INFO  [org.jboss.as.server] (HttpManagementService-threads - 33) JBAS018559: Deployed "surplus1.3.war"

[Updated on: Mon, 11 February 2013 21:47]

Report message to a moderator

Re: DBWS Error on Deployment [message #1012066 is a reply to message #1008317] Wed, 20 February 2013 20:24 Go to previous message
David McCann is currently offline David McCannFriend
Messages: 20
Registered: July 2009
Junior Member
That's a new one... I haven't tested against JBoss 7, but have tests that run successfully against JBoss 5 and 6. I'll try and get a simple example running against JBoss 7 shortly. Are you able to try to deploy your .war on an earlier JBoss version? I believe that on those versions of JBoss you can plunk eclipselink.jar and your database driver jar (i.e. ojdbc6.jar) into the $JBOSS_HOME/server/default/lib folder, setup your datasource, and deploy (as opposed to setting up modules, editing properties files, etc). This may make things easier to debug.
Previous Topic:No Persistence provider for EntityManager named default
Next Topic:JAXB unmarshaller : no AttachmentUnmarshaller set
Goto Forum:
  


Current Time: Thu Nov 27 04:55:52 GMT 2014

Powered by FUDForum. Page generated in 0.08512 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software