[jboss-jira] [JBoss JIRA] Commented: (AS7-1015) Deployment fails with NullPointerException when installing JDBC Driver as a deployment
Sande Gilda (JIRA)
jira-events at lists.jboss.org
Wed Jun 15 08:21:50 EDT 2011
[ https://issues.jboss.org/browse/AS7-1015?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12608819#comment-12608819 ]
Sande Gilda commented on AS7-1015:
----------------------------------
Stefano, you are correct. The change you suggested works:
<driver>mysql-connector-java-5.1.15.jar</driver>
I am rereading the instructions here: http://community.jboss.org/wiki/DataSourceConfigurationinAS7
The sample standalone.xml file has this element for the MySQL driver:
<driver>com.mysql.jdbc.Driver#5.1</driver>
Later, it says:
In the module tag above, you should specify the fully qualtified name of the JDBC driver class, appended with a pound sign (#), with the major and minor version number. In my example above its 5.1, since I am using the 5.1.15 driver from MySQL. It does not support the micro version number, so if you are tempted, as I was, to add it, it will cause your module to fail loading, which will then cascade to your application using this data source.
Does this mean the above instruction is not correct? That the # is not needed and the micro version number is supported? Should I update this web page?
> Deployment fails with NullPointerException when installing JDBC Driver as a deployment
> --------------------------------------------------------------------------------------
>
> Key: AS7-1015
> URL: https://issues.jboss.org/browse/AS7-1015
> Project: Application Server 7
> Issue Type: Bug
> Components: JCA
> Environment: Fedora 14. JBoss AS7 build from June 8, Using MySQL JDBC driver downloaded as an example from http://community.jboss.org/wiki/DataSourceConfigurationinAS7#Installing_a_JDBC_driver_as_a_deployment
> Reporter: Sande Gilda
> Assignee: Stefano Maestri
> Attachments: standalone.xml
>
>
> I am working on the DataSource configuration changes for the EAP5 -> EAP6 migration guide and am following the steps here: http://community.jboss.org/wiki/DataSourceConfigurationinAS7.
> I have been able to successfully install the MySQL JDBC driver as a module, however, I am not having much luck installing the driver as a deployment, which this document says is the recommended way to install it.
> I've done the following:
> - I copied the JDBC-compliant mysql-connector-java-5.1.15.jar (downloaded from the above web site) into my <jboss7>/standalone/deployments directory.
> - I still have the <datasource> and <driver> elements defined in my standalone.xml file from when I successfully installed the driver as a module.
> When I start the server, I see the following error in the log:
> 11:53:42,348 ERROR [org.jboss.msc.service.fail] (MSC service thread 1-2) MSC00001: Failed to start service jboss.deployment.unit."TopicIndex.war".CONFIGURE_MODULE: org.jboss.msc.service.StartException in service jboss.deployment.unit."TopicIndex.war".CONFIGURE_MODULE: Failed to process phase CONFIGURE_MODULE of deployment "TopicIndex.war"
> at org.jboss.as.server.deployment.DeploymentUnitPhaseService.start(DeploymentUnitPhaseService.java:121) [jboss-as-server-7.0.0.Beta4-SNAPSHOT.jar:7.0.0.Beta4-SNAPSHOT]
> at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceControllerImpl.java:1675) [jboss-msc-1.0.0.Beta8.jar:1.0.0.Beta8]
> at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886) [:1.6.0_25]
> at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908) [:1.6.0_25]
> at java.lang.Thread.run(Thread.java:662) [:1.6.0_25]
> Caused by: java.lang.NullPointerException
> at org.jboss.msc.service.ServiceTargetImpl.install(ServiceTargetImpl.java:188) [jboss-msc-1.0.0.Beta8.jar:1.0.0.Beta8]
> at org.jboss.msc.service.ServiceControllerImpl$ChildServiceTarget.install(ServiceControllerImpl.java:2165) [jboss-msc-1.0.0.Beta8.jar:1.0.0.Beta8]
> at org.jboss.msc.service.ServiceTargetImpl.install(ServiceTargetImpl.java:188) [jboss-msc-1.0.0.Beta8.jar:1.0.0.Beta8]
> at org.jboss.msc.service.ServiceControllerImpl$ChildServiceTarget.install(ServiceControllerImpl.java:2165) [jboss-msc-1.0.0.Beta8.jar:1.0.0.Beta8]
> at org.jboss.msc.service.ServiceBuilderImpl.install(ServiceBuilderImpl.java:325) [jboss-msc-1.0.0.Beta8.jar:1.0.0.Beta8]
> at org.jboss.as.server.deployment.module.ModuleSpecProcessor.createModuleService(ModuleSpecProcessor.java:193) [jboss-as-server-7.0.0.Beta4-SNAPSHOT.jar:7.0.0.Beta4-SNAPSHOT]
> at org.jboss.as.server.deployment.module.ModuleSpecProcessor.deploy(ModuleSpecProcessor.java:99) [jboss-as-server-7.0.0.Beta4-SNAPSHOT.jar:7.0.0.Beta4-SNAPSHOT]
> at org.jboss.as.server.deployment.DeploymentUnitPhaseService.start(DeploymentUnitPhaseService.java:115) [jboss-as-server-7.0.0.Beta4-SNAPSHOT.jar:7.0.0.Beta4-SNAPSHOT]
> ... 4 more
> 11:53:42,350 ERROR [org.jboss.as] (MSC service thread 1-1) JBoss AS 7.0.0.Beta4-SNAPSHOT "(TBD)" started (with errors) in 6159ms - Started 136 of 196 services (5 services failed or missing dependencies, 55 services are passive or on-demand)
> Later I see the message that deployment of my WAR failed due to the missing dependency:
> 11:53:42,394 INFO [org.jboss.as.server.deployment] (MSC service thread 1-1) Starting deployment of "TopicIndex.war"
> 11:53:42,394 INFO [org.jboss.as.server] (MSC service thread 1-6) Service status report
> New missing/unsatisfied dependencies:
> service jboss.jdbc-driver._________________________ (missing) required by [service jboss.data-source.java:/TopicIndexDatasource]
> Is there something else I need to be doing here?
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira
More information about the jboss-jira
mailing list