diff --git a/batch-processing/configure-server.cli b/batch-processing/configure-server.cli new file mode 100644 index 0000000000..fda2656dde --- /dev/null +++ b/batch-processing/configure-server.cli @@ -0,0 +1,15 @@ +# Batch script to configure the datasource +batch + +# Start by creating the JDBC datasource +/subsystem=datasources/data-source=batch-processingDS:add(connection-url="jdbc:h2:mem:batch-processingDS;DB_CLOSE_ON_EXIT=FALSE;DB_CLOSE_DELAY=-1", jndi-name="java:jboss/datasources/batch-processingDS", driver-name=h2, user-name="sa", password="sa", enabled="true", use-java-context=true) +/subsystem=batch-jberet/jdbc-job-repository=jdbc:add(data-source=batch-processingDS) +/subsystem=batch-jberet:write-attribute(name=default-job-repository,value=jdbc) + +# Run the batch commands +run-batch + +# Reload the server configuration +#reload + + diff --git a/batch-processing/pom.xml b/batch-processing/pom.xml index e5c11c62d7..1608cf113b 100644 --- a/batch-processing/pom.xml +++ b/batch-processing/pom.xml @@ -209,6 +209,15 @@ application is deployed in the root web context. --> ROOT.war + + + + + + + false + + @@ -241,6 +250,15 @@ application is deployed in the root web context. Add ROOT.war to the server. --> ROOT.war + + + + + + + false + + diff --git a/batch-processing/src/main/resources/META-INF/persistence.xml b/batch-processing/src/main/resources/META-INF/persistence.xml index a9c09a5e52..a422aae63e 100644 --- a/batch-processing/src/main/resources/META-INF/persistence.xml +++ b/batch-processing/src/main/resources/META-INF/persistence.xml @@ -25,8 +25,6 @@ - java:jboss/datasources/batch-processingDS diff --git a/batch-processing/src/main/webapp/WEB-INF/jboss-batch-processing-ds.xml b/batch-processing/src/main/webapp/WEB-INF/jboss-batch-processing-ds.xml deleted file mode 100644 index fb23f37023..0000000000 --- a/batch-processing/src/main/webapp/WEB-INF/jboss-batch-processing-ds.xml +++ /dev/null @@ -1,38 +0,0 @@ - - - - - - - - jdbc:h2:mem:batch-processing;DB_CLOSE_ON_EXIT=FALSE;DB_CLOSE_DELAY=-1 - h2 - - sa - sa - - - -