## Batch file to configure the standalone server for the messaging-clustering-singleton quickstart.

batch

# -- The console is disabled by default in the Full HA profile. Enable the console to allow us to view the quickstart output.
/subsystem=logging/console-handler=CONSOLE:add(level=INFO,formatter="%K{level}%d{HH:mm:ss,SSS} %-5p [%c] (%t) %s%E%n")
/subsystem=logging/root-logger=ROOT:add-handler(name="CONSOLE")

# -- Enable clustering, and set a cluster password
/subsystem=messaging-activemq/server=default:write-attribute(name=cluster-password, value=password)

# -- Add mdb-delivery-group named "my-mdb-delivery-group"
/subsystem=ejb3/mdb-delivery-group=my-mdb-delivery-group:add(active=true)

# -- Deploy the messaging-clustering-singleton.war file
# NOTE: The following command assumes the quickstart is built
#       If that is not the case, run mvn clean install before this script
deploy target/messaging-clustering-singleton.war

# -- Run this batch file
run-batch

# Reload the server
reload
