[ https://issues.apache.org/jira/browse/FLINK-35278?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Márton Balassi closed FLINK-35278. ---------------------------------- Resolution: Fixed [e73363f|https://github.com/apache/flink-kubernetes-operator/commit/e73363f3486ed9e1df5cc05c9d0baec7c8c3a37f] in main. > Occasional NPE on k8s operator status replacement > ------------------------------------------------- > > Key: FLINK-35278 > URL: https://issues.apache.org/jira/browse/FLINK-35278 > Project: Flink > Issue Type: Bug > Components: Kubernetes Operator > Reporter: Márton Balassi > Assignee: Ferenc Csaky > Priority: Minor > Labels: pull-request-available > Fix For: kubernetes-operator-1.9.0 > > > Infrequently we get a null pointer exception on status replacement: > {noformat} > logger: io.javaoperatorsdk.operator.processing.event.ReconciliationDispatcher > message: Error during error status handling. > throwable: { [-] > class: java.lang.NullPointerException > msg: null > stack: [ [-] > > org.apache.flink.kubernetes.operator.utils.StatusRecorder.replaceStatus(StatusRecorder.java:136) > > org.apache.flink.kubernetes.operator.utils.StatusRecorder.patchAndCacheStatus(StatusRecorder.java:97) > > org.apache.flink.kubernetes.operator.reconciler.ReconciliationUtils.toErrorStatusUpdateControl(ReconciliationUtils.java:438) > > org.apache.flink.kubernetes.operator.controller.FlinkDeploymentController.updateErrorStatus(FlinkDeploymentController.java:213) > > org.apache.flink.kubernetes.operator.controller.FlinkDeploymentController.updateErrorStatus(FlinkDeploymentController.java:60) > > io.javaoperatorsdk.operator.processing.event.ReconciliationDispatcher.handleErrorStatusHandler(ReconciliationDispatcher.java:194) > > io.javaoperatorsdk.operator.processing.event.ReconciliationDispatcher.handleReconcile(ReconciliationDispatcher.java:123) > > io.javaoperatorsdk.operator.processing.event.ReconciliationDispatcher.handleDispatch(ReconciliationDispatcher.java:91) > > io.javaoperatorsdk.operator.processing.event.ReconciliationDispatcher.handleExecution(ReconciliationDispatcher.java:64) > > io.javaoperatorsdk.operator.processing.event.EventProcessor$ReconcilerExecutor.run(EventProcessor.java:452) > > java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128) > > java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628) > java.lang.Thread.run(Thread.java:829) > ] > }{noformat} > I suspect it probably is thrown by getResourceVersion() here: > [https://github.com/apache/flink-kubernetes-operator/blob/main/flink-kubernetes-operator/src/main/java/org/apache/flink/kubernetes/operator/utils/StatusRecorder.java#L136] -- This message was sent by Atlassian Jira (v8.20.10#820010)