how extactly do you define dependency?
you are probably missing importing of services.
instead of manifest.mf add jboss-deployment-structure.xml and add dependancy there together with service="import"
Thanks for your answer Tomaz! I have defined the dependency in Manifest.MF like this:
And that's the name I put in the module.xml also.
Is there a difference between the way the dependencies specified in MANIFEST are loaded from the ones mentioned in jboss-deployment-structure.xml?
Does your directory structure match the dot-notation of the module name (plus the main dir)?
Yes. I guess I wouldn't be able to do a successful Class.forName otherwise, right? I mean the classes in the module are in the classpath of my app but somwhow resteasy doesn't pickup the provider unless the module is set as global.
Hmm. My guess would be that the deployer scans the application, sees that it uses hibernate and adds the hibernate dependecy and the classloader goes from there. Tried filtering out hibernate in jboss-deployment-structure.xml and pull it in through your own module?