Add listener to persist relationship between job and task
This introduces a listener that stores the association between a Spring Batch job and the task it was executed within. Resolves spring-cloud/spring-cloud-task#46 Merge Changes based on code review.
This commit is contained in:
committed by
Glenn Renfro
parent
bb76cef391
commit
7c8fc5f50e
@@ -40,6 +40,8 @@ import org.springframework.context.annotation.Bean;
|
||||
@EnableConfigurationProperties({ TimestampTaskProperties.class })
|
||||
public class TaskApplication {
|
||||
|
||||
private static final Log logger = LogFactory.getLog(TaskApplication.class);
|
||||
|
||||
@Bean
|
||||
public TimestampTask timeStampTask() {
|
||||
return new TimestampTask();
|
||||
@@ -53,7 +55,6 @@ public class TaskApplication {
|
||||
* A commandline runner that prints a timestamp.
|
||||
*/
|
||||
public class TimestampTask implements CommandLineRunner {
|
||||
private final Log logger = LogFactory.getLog(TimestampTask.class);
|
||||
|
||||
@Autowired
|
||||
private TimestampTaskProperties config;
|
||||
|
||||
Reference in New Issue
Block a user