Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8476915
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 10, 20262026-06-10T18:18:37+00:00 2026-06-10T18:18:37+00:00

While deploying my app I’m getting the following errors (I’ve also included subjectively significant

  • 0

While deploying my app I’m getting the following errors (I’ve also included subjectively significant warnings):

03:36:42,113 WARN  [org.jboss.resource.connectionmanager.JBossManagedConnectionPool] Throwable while attempting to get a new connection: null: org.jboss.resource.JBossResourceException: Could not create connection; - nested throwable: (org.jboss.resource.JBossResourceException: Failed to register driver for: com.mysql.jdbc.Driver; - nested throwable: (java.lang.ClassNotFoundException: com.mysql.jdbc.Driver from BaseClassLoader@66a8c396{vfs:///D:/MobilnyPodroznik/workspace/.metadata/.plugins/org.jboss.ide.eclipse.as.core/JBoss_6.x_Runtime_Server1345902635716/deploy/MP01.jar}))
(...)
Caused by: org.jboss.resource.JBossResourceException: Failed to register driver for: com.mysql.jdbc.Driver; - nested throwable: (java.lang.ClassNotFoundException: com.mysql.jdbc.Driver from BaseClassLoader@66a8c396{vfs:///D:/MobilnyPodroznik/workspace/.metadata/.plugins/org.jboss.ide.eclipse.as.core/JBoss_6.x_Runtime_Server1345902635716/deploy/MP01.jar})
(..)
Caused by: java.lang.ClassNotFoundException: com.mysql.jdbc.Driver from BaseClassLoader@66a8c396{vfs:///D:/MobilnyPodroznik/workspace/.metadata/.plugins/org.jboss.ide.eclipse.as.core/JBoss_6.x_Runtime_Server1345902635716/deploy/MP01.jar}

03:36:42,122 WARN  [org.hibernate.cfg.SettingsFactory] Could not obtain connection to query metadata: org.jboss.util.NestedSQLException: Unable to get managed connection for MP01Local; - nested throwable: (javax.resource.ResourceException: Unable to get managed connection for MP01Local)
(...)
Caused by: javax.resource.ResourceException: Unable to get managed connection for MP01Local
(...)
Caused by: org.jboss.resource.JBossResourceException: Could not create connection; - nested throwable: (org.jboss.resource.JBossResourceException: Failed to register driver for: com.mysql.jdbc.Driver; - nested throwable: (java.lang.ClassNotFoundException: com.mysql.jdbc.Driver from BaseClassLoader@66a8c396{vfs:///D:/MobilnyPodroznik/workspace/.metadata/.plugins/org.jboss.ide.eclipse.as.core/JBoss_6.x_Runtime_Server1345902635716/deploy/MP01.jar}))
(...)
Caused by: org.jboss.resource.JBossResourceException: Failed to register driver for: com.mysql.jdbc.Driver; - nested throwable: (java.lang.ClassNotFoundException: com.mysql.jdbc.Driver from BaseClassLoader@66a8c396{vfs:///D:/MobilnyPodroznik/workspace/.metadata/.plugins/org.jboss.ide.eclipse.as.core/JBoss_6.x_Runtime_Server1345902635716/deploy/MP01.jar})
(...)
Caused by: java.lang.ClassNotFoundException: com.mysql.jdbc.Driver from BaseClassLoader@66a8c396{vfs:///D:/MobilnyPodroznik/workspace/.metadata/.plugins/org.jboss.ide.eclipse.as.core/JBoss_6.x_Runtime_Server1345902635716/deploy/MP01.jar}

03:36:42,143 WARN  [org.jboss.resource.connectionmanager.JBossManagedConnectionPool] Throwable while attempting to get a new connection: null: org.jboss.resource.JBossResourceException: Could not create connection; - nested throwable: (org.jboss.resource.JBossResourceException: Failed to register driver for: com.mysql.jdbc.Driver; - nested throwable: (java.lang.ClassNotFoundException: com.mysql.jdbc.Driver from BaseClassLoader@66a8c396{vfs:///D:/MobilnyPodroznik/workspace/.metadata/.plugins/org.jboss.ide.eclipse.as.core/JBoss_6.x_Runtime_Server1345902635716/deploy/MP01.jar}))
(...)
Caused by: org.jboss.resource.JBossResourceException: Failed to register driver for: com.mysql.jdbc.Driver; - nested throwable: (java.lang.ClassNotFoundException: com.mysql.jdbc.Driver from BaseClassLoader@66a8c396{vfs:///D:/MobilnyPodroznik/workspace/.metadata/.plugins/org.jboss.ide.eclipse.as.core/JBoss_6.x_Runtime_Server1345902635716/deploy/MP01.jar})
(...)
Caused by: java.lang.ClassNotFoundException: com.mysql.jdbc.Driver from BaseClassLoader@66a8c396{vfs:///D:/MobilnyPodroznik/workspace/.metadata/.plugins/org.jboss.ide.eclipse.as.core/JBoss_6.x_Runtime_Server1345902635716/deploy/MP01.jar}

03:36:42,147 ERROR [org.hibernate.tool.hbm2ddl.SchemaExport] schema export unsuccessful: org.jboss.util.NestedSQLException: Unable to get managed connection for MP01Local; - nested throwable: (javax.resource.ResourceException: Unable to get managed connection for MP01Local)
(...)
Caused by: javax.resource.ResourceException: Unable to get managed connection for MP01Local
(...)
Caused by: org.jboss.resource.JBossResourceException: Could not create connection; - nested throwable: (org.jboss.resource.JBossResourceException: Failed to register driver for: com.mysql.jdbc.Driver; - nested throwable: (java.lang.ClassNotFoundException: com.mysql.jdbc.Driver from BaseClassLoader@66a8c396{vfs:///D:/MobilnyPodroznik/workspace/.metadata/.plugins/org.jboss.ide.eclipse.as.core/JBoss_6.x_Runtime_Server1345902635716/deploy/MP01.jar}))
(...)
Caused by: org.jboss.resource.JBossResourceException: Failed to register driver for: com.mysql.jdbc.Driver; - nested throwable: (java.lang.ClassNotFoundException: com.mysql.jdbc.Driver from BaseClassLoader@66a8c396{vfs:///D:/MobilnyPodroznik/workspace/.metadata/.plugins/org.jboss.ide.eclipse.as.core/JBoss_6.x_Runtime_Server1345902635716/deploy/MP01.jar})
(...)
Caused by: java.lang.ClassNotFoundException: com.mysql.jdbc.Driver from BaseClassLoader@66a8c396{vfs:///D:/MobilnyPodroznik/workspace/.metadata/.plugins/org.jboss.ide.eclipse.as.core/JBoss_6.x_Runtime_Server1345902635716/deploy/MP01.jar}

As for the whole console output: http://pastebin.com/de2Br9xL

Basically, it seems as if my JDBC driver is not visible, but I have placed the .jar both in the server’s default/lib folder and in project’s build path, thus I’m clueless now.

persistence.xml

<?xml version="1.0" encoding="UTF-8"?>
<persistence xmlns="http://java.sun.com/xml/ns/persistence" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
       xsi:schemaLocation="http://java.sun.com/xml/ns/persistence http://java.sun.com/xml/ns/persistence/persistence_2_0.xsd"
       version="2.0">
  <persistence-unit name="mp" transaction-type="JTA">
    <jta-data-source>java:/MP01Local</jta-data-source>

           <properties>
       <!--s
       <property name="hibernate.dialect" value="org.hibernate.dialect.HSQLDialect"/>
       -->
       <property name="hibernate.dialect" value="org.hibernate.dialect.MySQLDialect"/>
       <property name="hibernate.hbm2ddl.auto" value="create-drop"/>
   </properties>
  </persistence-unit>
</persistence>

mysqllocal-ds.xml

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE datasources
    PUBLIC "-//JBoss//DTD JBOSS JCA Config 1.5//EN"
    "http://www.jboss.org/j2ee/dtd/jboss-ds_1_5.dtd">
<datasources>

   <local-tx-datasource>
      <jndi-name>MP01Local</jndi-name>
      <connection-url>jdbc:mysql://localhost:3306/mp</connection-url>
      <driver-class>com.mysql.jdbc.Driver</driver-class>
      <user-name>login</user-name>
      <password>pass</password>
   </local-tx-datasource>

</datasources>

I have placed the DS XML file in default/deploy path of the JBoss server and mysql-connector-java-5.0.8-bin in default/lib, as indicated in the JBoss manual.

I’m using

  • Eclipse, build 20120614-1722,
  • JBoss AS 6,
  • mysql-connector-java-5.0.8-bin driver.
  • As for the MySQL, mysql –version prints out “mysql Ver 14.14 Distrib 5.5.25a, for Win32 (X86)”.

My project build path

  1. jre6
  2. JBoss 6.x Runtime
  3. MySQL JDBC Driver 5.0.8, including mysql-connector-java-5.0.8-bin.jar [I have created it in Data Source Explorer)
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-10T18:18:39+00:00Added an answer on June 10, 2026 at 6:18 pm

    All right, I’ve repeated all the steps from the beginning as a fresh morning man and it worked. Still don’t know why, but here’re a few things that might’ve solved the problem. Hope this helps to anyone who’s struggling to deploy his first Java EE + JPA application.

    Here’re the steps I’ve followed:

    • Downloaded mysql-connector-java-5.0.8-bin.jar from
      http://www.mysql.com/downloads/connector/j/5.0.html#downloads
    • Placed it in jboss-6.0.0.Final\server\default\lib
    • Created a new Connection Profile in Eclipse using Data Source Explorer (I don’t know if that
      step is even necessary). In the wizard I’ve also created a new Driver
      Definition using the 5.0.8 connector. The ping succeeded and my
      database is visible from within the Data Source Explorer.
    • Generated
      -ds.xml file from the CP mentioned in 3) using File->New->Other…->JBoss Tools Web->JBoss Datasource (-ds.xml)
      (using AS5 format) and placed it in
      jboss-6.0.0.Final\server\default\deploy\Mysql_local-ds.xml as well as
      project’s META-INF\Mysql_local-ds.xml (corrected: when I placed it in
      both places simultaneously, I received ERROR
      [org.jboss.kernel.plugins.dependency.AbstractKernelController] Error
      installing to Real: (…) Caused by: java.lang.IllegalStateException:
      jboss.jca:name=MP01Datasource2,service=ManagedConnectionFactory is
      already installed.)
    • I’ve added the db’s jar to build path usign [rmb
      on project]->Build Path->Configure Build Path…->Add
      Library->Connectivity Driver Definition and chose the one I’ve
      defined in 3)

    I have also deleted some old .jar deployments from my other test projects that got stuck in the workspace.metadata.plugins\org.jboss.ide.eclipse.as.core\JBoss_6.x_Runtime_Server1345902635716\deploy folder (supposedly due to incorrect shutdown), but I sincerely doubt that was what helped.

    I suppose the main cause might’ve been that as I was swapping the drivers and Driver Definitions (I’ve been moving from 5.1.sth to 5.0.8) I forgot to swap them in the pj’s build path as well and involuntarily left the old one.

    My current persistence.xml

    <?xml version="1.0" encoding="UTF-8"?>
    <persistence xmlns="http://java.sun.com/xml/ns/persistence" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
           xsi:schemaLocation="http://java.sun.com/xml/ns/persistence http://java.sun.com/xml/ns/persistence/persistence_2_0.xsd"
           version="2.0">
      <persistence-unit name="mp" transaction-type="JTA">
        <jta-data-source>java:/MP01Datasource2</jta-data-source>
               <properties>
           <!--s
           <property name="hibernate.dialect" value="org.hibernate.dialect.HSQLDialect"/>
           -->
           <property name="hibernate.dialect" value="org.hibernate.dialect.MySQLDialect"/>
           <property name="hibernate.hbm2ddl.auto" value="create-drop"/>
       </properties>
      </persistence-unit>
    </persistence>
    

    Mysql_local-ds.xml

    <?xml version="1.0" encoding="UTF-8"?>
    <!DOCTYPE datasources
        PUBLIC "-//JBoss//DTD JBOSS JCA Config 1.5//EN"
        "http://www.jboss.org/j2ee/dtd/jboss-ds_1_5.dtd">
    <datasources>
    
       <local-tx-datasource>
          <jndi-name>MP01Datasource2</jndi-name>
          <use-java-context>true</use-java-context>
          <connection-url>jdbc:mysql://localhost:3306/mp</connection-url>
          <driver-class>com.mysql.jdbc.Driver</driver-class>
          <user-name>x</user-name>
          <password>y</password>
       </local-tx-datasource>
    
    </datasources>
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

WHILE DEPLOYING aPP IN VISUAL STUDIO 2012 EXPRESS.I AM GETTING THE FOLLOWING ERROR: Error
While deploying a dwr web app, i'm continuously getting this error. I dont know
I am getting an error while deploying code for the first time. I used
I'm deploying a Rails app on Heroku (for now) via git, and would also
I'm running Rails 3.1 apps on 3 app servers (3 nodes). While deploying, the
While deploying my app in JBOSS5 (earlier i was deploying in JBOSS4), I get
I'm getting the following error when deploying the application in the Glassfish server, Error
While deploying my application, I got the error message: Thread 1:Program received signal: EXC_BAD_ACCESS.
I am encountering issues while deploying an ASP web application to HostMySite. The application
I'm having an odd problem while deploying a Django site using Fabric. I've configured

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.