Implement graceful shutdown for batch tasks
-------------------------------------------
Key: WFLY-3769
URL:
https://issues.jboss.org/browse/WFLY-3769
Project: WildFly
Issue Type: Sub-task
Components: Batch
Reporter: Stuart Douglas
Assignee: James Perkins
Fix For: 10.0.0.Alpha4
This should make sure that all batch jobs have completed before the container shuts down,
and not allow new jobs to start while the container is suspended.