github-actions[bot] commented on code in PR #62270:
URL: https://github.com/apache/doris/pull/62270#discussion_r3056387413


##########
fe/fe-core/src/main/java/org/apache/doris/job/extensions/insert/streaming/StreamingInsertJob.java:
##########
@@ -414,13 +417,18 @@ public void updateJobStatus(JobStatus status) throws 
JobException {
         lock.writeLock().lock();
         try {
             super.updateJobStatus(status);
-            if (JobStatus.PAUSED.equals(getJobStatus())) {
+            if (JobStatus.PAUSED.equals(getJobStatus()) || 
JobStatus.RETRYING.equals(getJobStatus())) {
                 clearRunningStreamTask(status);
             }
             if (isFinalStatus()) {
                 
Env.getCurrentGlobalTransactionMgr().getCallbackFactory().removeCallback(getJobId());
             }
             log.info("Streaming insert job {} update status to {}", 
getJobId(), getJobStatus());

Review Comment:
   `RETRYING` is still persisted through checkpoint images, so the 
backward-compatibility guarantee here is not actually true. 
`StreamingInsertJob.write()` still serializes the full object with 
`GsonUtils.GSON.toJson(this)`, and `JobManager.write()` writes every job into 
the image. If the master saves an image while a job is in `RETRYING`, an older 
FE that later loads that image during rollback / mixed-version operation will 
still see the unknown enum value in `jobStatus`, even though the editlog skips 
it.
   
   That means we need to normalize `RETRYING` before image serialization as 
well (for example, serialize it as `PENDING`/`PAUSED` or strip the transient 
status from the checkpoint representation), and ideally add a restart/image 
compatibility test for this path.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to