Version 1

    I was working on integrating the mysql data source with wild fly and I had wasted quiet a bit of time and I thought to share the details here so that some one else don't waste time on figuring out trivial thing.


    1. configure just like any module



    <?xml version="1.0" encoding="UTF-8"?>

    <module xmlns="urn:jboss:module:1.3" name="com.mysql">


         <resource-root path="mysql-connector-java-5.0.8-bin.jar"/>



          <module name="javax.api"/>

          <module name="javax.transaction.api"/>

       <module name="javax.servlet.api" optional="true"/>




    module/com.mysql/main/<mysql jar file>


    2 . configure the standalone.xml with driver and datasource detials.


    <datasource jta="true" jndi-name="java:jboss/datasources/jbpmDS" pool-name="mysql-pool" enabled="true" use-java-context="true" use-ccm="true">








    <driver name="mysql" module="com.mysql">




    Above setting although correct will not work and this is due to the error in the jdbc driver and please refer to the details below .


    Use the latest driver and correct the config to below


    Driver Jar which Doesnt Not Work : mysql-connector-java-5.0.8-bin.jar

    Driver Jar which Works : mysql-connector-java-5.1.34-bin.jar


    Hope this helpful  to others .



    Sanjay Gautam