I'm trying to find a way to add a mail session resource to my jboss-as-maven-plugin but I'm not really making a lot of progress.. Anyone has got some tutorial or something? I can't find any..
I've already created a stack overflow for it but there isn't a lot of response..
Right now I'm trying to get it up and running with CLI commands. But for testing purposes I'm first trying to add my datasource to jBoss using the commands but even that isn't working. I've placed the following execution before the deploy goal:
<command>/subsystem=datasources/data-source="java:jboss/datasources/eCadWSDS":add(jndi-name="java:jboss/datasources/eCadWSDS", driver-name="h2", connection-url="jdbc:h2:mem:testdb;DB_CLOSE_DELAY=-1")</command>
The first plugin (start) is still there. The add-resources executions have been removed to be able to test the cli commands. But now I'm getting the "no datasource" exception although I'm adding it with the CLI command??? It looks as if it isn't really executed? But it's failing when I type some mistake in the command..
If there is another way to add a mail session (without cli commands) then that is also fine for me.