Java Reference
In-Depth Information
/subsystem=datasources/
data-source=PostgreSQLDS:add(jndi-name=java:jboss/
datasources/PostgreSQLDS , driver-name=postgresql,
connection-url=jdbc:postgresql://localhost:5432/
ticketsystem,user-name=jboss,password=jboss)
The first line of the script, after the connection, installs a new module named
org.postgresql in your server modules' directory, including the PostgreSQL JDBC
driver and the required dependencies.
The second line installs the JDBC driver for the org.postgresql module into the
datasources/jdbc-driver subsystem.
Finally, a data source is added to jndi java:jboss/datasources/Post-
greSQLDS with the required URL and credentials.
Adding JMS resources
Adding a new JMS destination is quite easy since it does not require a lengthy set of com-
mands. However, it is sometimes your application that needs to set up lots of JMS destina-
tions in order to work, so why not create a script for it too? The following is a tiny script
that adds a JMS queue to the server configuration:
connect
jms-queue add --queue-address=queue1 --entries=queues/
queue1
The following is the corresponding script you can use to create a JMS topic:
connect
jms-topic add --topic-address=topic1 --entries=topics/
topic1
Search WWH ::




Custom Search