flink operator version is v1.5 Deployment recovery has been turned off in the configuration by setting kubernetes.operator.jm-deployment-recovery.enabled to false.
apiVersion: flink.apache.org/v1beta1
kind: FlinkDeployment
metadata:
name:
labels:
upgradeMode: savepoint
spec:
image:
flinkVersion: v1_17
flinkConfiguration:
taskmanager.numberOfTaskSlots: "3"
# taskmanager.memory.managed.size: 2m
jobmanager.memory.jvm-metaspace.size: "256mb"
# classloader.resolve-order: parent-first
kubernetes.decorator.hadoop-conf-mount.enabled: "false"
serviceAccount: flink
podTemplate:
apiVersion: v1
kind: Pod
metadata:
name: pod-template
spec:
imagePullSecrets:
- name: regsecret
containers:
# Do not change the main container name
- name: flink-main-container
volumeMounts:
- mountPath: /opt/flink/application.properties
name: flink-config
subPath: application.properties
volumes:
- configMap:
defaultMode: 420
name: flink-config-rcmd
name: flink-config
jobManager:
replicas: 1
resource:
cpu: 0.2
memory: 1024m
taskManager:
resource:
cpu: 0.2
memory: 2048m
job:
args:
- --path
- /opt/flink/application.properties
entryClass:
jarURI:
parallelism: 3
state: running
upgradeMode: stateless
the log
2023-11-16 02:54:09,485 o.a.f.k.o.c.FlinkDeploymentController [INFO ][xxx] Starting reconciliation 2023-11-16 02:54:09,485 o.a.f.k.o.s.FlinkResourceContextFactory [INFO ][xxx] Getting service for xxx 2023-11-16 02:54:09,485 o.a.f.k.o.o.JobStatusObserver [INFO ][xxx] Observing job status 2023-11-16 02:54:09,492 o.a.f.k.o.o.JobStatusObserver [INFO ][xxx] Job status changed from RUNNING to FINISHED 2023-11-16 02:54:09,505 o.a.f.k.o.l.AuditUtils [INFO ][xxx] >>> Event | Info | JOBSTATUSCHANGED | Job status changed from RUNNING to FINISHED 2023-11-16 02:54:09,510 o.a.f.k.o.o.SavepointObserver [ERROR][xxx] Could not observe latest savepoint information. java.lang.NullPointerException 2023-11-16 02:54:09,522 o.a.f.k.o.l.AuditUtils [INFO ][xxx] >>> Event | Warning | CLUSTERDEPLOYMENTEXCEPTION | java.lang.NullPointerException 2023-11-16 02:54:09,522 o.a.f.k.o.r.ReconciliationUtils [WARN ][xxx] Attempt count: 5, last attempt: false 2023-11-16 02:54:09,523 i.j.o.p.e.ReconciliationDispatcher [ERROR][tms-test/content-agg] Error during event processing ExecutionScope{ resource id: ResourceID{name='content-agg', namespace='tms-test'}, version: 1943523107} failed. org.apache.flink.kubernetes.operator.exception.ReconciliationException: org.apache.flink.kubernetes.operator.exception.ReconciliationException: java.lang.NullPointerException 2023-11-16T10:54:09.523616673+08:00 at org.apache.flink.kubernetes.operator.controller.FlinkDeploymentController.reconcile(FlinkDeploymentController.java:156) 2023-11-16T10:54:09.523618777+08:00 at org.apache.flink.kubernetes.operator.controller.FlinkDeploymentController.reconcile(FlinkDeploymentController.java:57)
This is a scheduled job. If the problem has not solved, the job cannot be executed next time.