Avoid NPE.

This commit is contained in:
Michael Lipp 2024-11-12 22:04:15 +01:00
parent 65ceed93b6
commit 40cbeb694b

View file

@ -204,7 +204,7 @@ public class Runner extends Component {
private static final String FW_VARS = "fw-vars.fd"; private static final String FW_VARS = "fw-vars.fd";
private static int exitStatus; private static int exitStatus;
private EventPipeline rep; private final EventPipeline rep = newEventPipeline();
private final ObjectMapper yamlMapper = new ObjectMapper(YAMLFactory private final ObjectMapper yamlMapper = new ObjectMapper(YAMLFactory
.builder().disable(YAMLGenerator.Feature.WRITE_DOC_START_MARKER) .builder().disable(YAMLGenerator.Feature.WRITE_DOC_START_MARKER)
.build()); .build());
@ -446,8 +446,7 @@ public class Runner extends Component {
// https://github.com/kubernetes-client/java/issues/100 // https://github.com/kubernetes-client/java/issues/100
io.kubernetes.client.openapi.Configuration.setDefaultApiClient(null); io.kubernetes.client.openapi.Configuration.setDefaultApiClient(null);
// Prepare specific event pipeline to avoid concurrency. // Provide specific event pipeline to avoid concurrency.
rep = newEventPipeline();
event.setAssociated(EventPipeline.class, rep); event.setAssociated(EventPipeline.class, rep);
try { try {
// Store process id // Store process id