Error "Error loading module" for Firebird datasource on WildFly 8.1.0.Final
Server start error message:
16:08:37,829 ERROR [org.jboss.as.controller.management-operation] (ServerService
Thread Pool -- 27) JBAS014613: Operation ("add") failed - address: ([
("subsystem" => "datasources"),
("jdbc-driver" => "firebird")
]) - failure description: "JBAS010441: Failed to load module for driver [org.fir
ebirdsql]"
Module.xml content :
<?xml version="1.0" encoding="UTF-8"?>
<module xmlns="urn:jboss:module:1.3" name="org.firebirdsql">
<resources>
<resource-root path="jaybird-2.2.5.jar"/>
</resources>
<dependencies>
<module name="javax.api"/>
<module name="javax.resource"/>
<module name="javax.transaction.api"/>
</dependencies>
</module>
Driver definition in standalone.xml :
<driver name="firebird" module="org.firebirdsql">
<driver-class>org.firebirdsql.jdbc.FBDriver</driver-class>
</driver>
(Based on http://masterjboss.blogspot.de/2014/03/how-to-configure-mysql-jdbc-driver-in.html )
Similar issue (no accepted answer): Db2 Driver / datasource setup to wildfly: Could not load module for driver [com.ibm]
source to share
I installed WildFly 8.1 and added a module under:
<wildfly-root>\modules\org\firebirdsql\main\
module.xml
jaybird-2.2.5.jar
Please note that this does not match the location used in the tutorial you are linking to. Tutorial - Wrong root custom modules in modules\system\layers\base
instead modules\
, but when I place the module in there, it also works.
There module.xml
is content in my definition :
<?xml version="1.0" encoding="UTF-8"?>
<module xmlns="urn:jboss:module:1.0" name="org.firebirdsql">
<resources>
<resource-root path="jaybird-2.2.5.jar"/>
</resources>
<dependencies>
<module name="javax.api"/>
<module name="javax.transaction.api"/>
<module name="javax.resource.api"/>
</dependencies>
</module>
I added the driver entry in standalone.xml
exactly the same way you posted. Then we added the data source to the management console and tested the connection.
It works. My previous theory in the comments that it doesn't work for you due to the web profile not including resource connectors seems to be wrong. I also tested using Java 8 version of Jaybird when WildFly is running on Java 7, but it gives UnsupportedClassVersionError
as expected.
The only way I could get the error in your question was by intentionally misusing the module (e.g. deleting it completely, having a spelling error in the folder names, or putting it in the wrong place). I would advise you to carefully check the location of your module (see above).
See asohun's answer for a solution to your specific problem. I'll leave this answer in place as it contains the correct configuration and an alternate failure mode that generates the same error.
source to share