Open WeekiXu opened 4 years ago
I set executionid to taskProperties in ComposedTaskRunnerConfiguration
, it works.
but failed in 2 tests ComposedTaskRunnerConfigurationNoPropertiesTests
and ComposedTaskRunnerConfigurationWithPropertiesTests
@BeforeTask
public void beforeComposedTask(
TaskExecution taskExecution) {
if (taskProperties.getExecutionid() == null
&& taskExecution.getExecutionId() > 0) {
taskProperties.setExecutionid(taskExecution.getExecutionId());
logger.info(
"set executionid to taskProperties from taskExecution.getExecutionId()");
}
}
Hi. @WeekiXu. Thanks for attempting to use and extend the available options. We will review it on our side to see what and if anything is missing.
composedtask started by schedules on k8s do not have the param executionid.
and parent-execution-id comes from the executionid param when start the composedtaskrunner.
composedtaskrunner images:
springcloudtask/composedtaskrunner-task:2.1.3.RELEASE
params in k8s containercan we add a TaskListener in
ComposedTaskRunnerStepFactory
to set executionid generated by SimpleTaskLauncher when SpringBoot startup