This commit adds on an abstraction for the providing unique command line
arugements for each worker. It also updates the partitioned job sample
to be able to successfully be run on CloudFoundry.
Resolvesspring-cloud/spring-cloud-task#193
Updated based on comments
When launching workers as separate tasks, it can be useful to be able to
use additional logic to define environment variables. This commit
provides an abstraction to allow for the customization of environment
variables on a per worker basis as well as two useful implementations:
* A no-op implementation (returns an empty Map).
* An implementation that moves the current environment variable handling
* out of the `DeployerPartitionHandler`.
Resolvesspring-cloud/spring-cloud-task#181
Created a Spring Boot starter that can be used to configure Spring Cloud
Task and it's related functionality.
Updates per code review
Removed autowiring of app context
Refactored DeployerPartitionHandler to correctly use environment variables
Exposed deployment properties of TaskLauncher
Exposed deployment properties via the TaskLaunchRequest
Updated based on code review
- Greater than 20s poll interval check in the assertion might as well needs to be equal to 20s interval as the test could finish before the next second
In testing and other use cases, the ability to keep a context open
beyond the end of a task can be useful. This change provides the
ability to keep the context alive once a task has completed while also
explicitly shutting the context down (by default) once a task has ended.
Resolvesspring-cloud/spring-cloud-task#102
DeployerStepExecutionHandler
Created a PartitionHandler that delegates to a TaskLauncher from Spring
Cloud Deployer to execute workers.
Resolvesspring-cloud/spring-cloud-task#109
Updates per code review
This commit changes the starting point of a task from the point when the
ApplicationContext issues the ContextRefreshedEvent to
SmartLifecycle#start. This is a more accurate point of start for a task
in that all beans should now be available. It also allows us to clean
up many ApplicationContext hacks that were present to get around the
fact that many beans were not ready when a Task was attempting to begin.
Resolvesspring-cloud/spring-cloud-task#107
This introduces a listener that stores the association between a Spring
Batch job and the task it was executed within.
Resolvesspring-cloud/spring-cloud-task#46
Merge Changes based on code review.