This is an automated email from the ASF dual-hosted git repository.

dataroaring pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/doris.git


The following commit(s) were added to refs/heads/master by this push:
     new c8ba19dca56 [fix](job) set cluster when routine load job replay from 
image (#59135)
c8ba19dca56 is described below

commit c8ba19dca56b266b29f07c2a0f949dea205ea6c2
Author: hui lai <[email protected]>
AuthorDate: Fri Dec 19 04:01:35 2025 +0800

    [fix](job) set cluster when routine load job replay from image (#59135)
    
    ### What problem does this PR solve?
    
    routine load job pause and can not resume when update:
    ```
    mysql> show routine load\G;
    *************************** 1. row ***************************
                      Id: 1765800763597
                    Name: lineitem_dup_persistent_label
              CreateTime: 2025-12-15 20:18:51
               PauseTime: 2025-12-15 20:33:34
                 EndTime: NULL
                  DbName: regression_test_stress_load_release_routine_load
               TableName: lineitem_dup_persistent
            IsMultiTable: false
                   State: PAUSED
          DataSourceType: KAFKA
          CurrentTaskNum: 0
           JobProperties: 
{"max_batch_rows":"300000","timezone":"Asia/Shanghai","send_batch_parallelism":"1","load_to_single_tablet":"false","column_separator":"','","line_delimiter":"\n","delete":"*","current_concurrent_number":"96","partial_columns":"false","merge_type":"APPEND","exec_mem_limit":"2147483648","strict_mode":"false","jsonpaths":"","max_batch_interval":"20","max_batch_size":"209715200","fuzzy_parse":"false","escape":"0","enclose":"0","partitions":"*","columnToColumnExpr":""
 [...]
    DataSourceProperties: 
{"topic":"test-release-topic-persistent690131793","currentKafkaPartitions":"0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95","brokerList":"172.20.48.94:9092"}
        CustomProperties: 
{"kafka_default_offsets":"OFFSET_BEGINNING","group.id":"test-consumer-group","client.id":"test-client-id"}
               Statistic: 
{"receivedBytes":955557901,"runningTxns":[],"errorRows":0,"committedTaskNum":0,"loadedRows":5000000,"loadRowsRate":5657,"abortedTaskNum":0,"errorRowsAfterResumed":0,"totalRows":5000000,"unselectedRows":0,"receivedBytesRate":1081251,"taskExecuteTimeMs":883752}
                Progress: 
{"0":"50620","1":"55664","2":"51135","3":"52169","4":"55413","5":"55355","6":"50806","7":"52994","8":"51368","9":"50639","10":"52749","11":"54719","12":"51991","13":"52286","14":"53822","15":"52359","16":"50858","17":"55055","18":"52334","19":"54346","20":"48332","21":"53804","22":"50136","23":"52355","24":"50488","25":"53128","26":"53798","27":"54857","28":"54381","29":"51395","30":"53017","31":"51399","32":"49111","33":"51818","34":"52621","35":"52366","36":"51
 [...]
                     Lag: 
{"0":5671,"1":0,"2":0,"3":0,"4":0,"5":0,"6":0,"7":0,"8":0,"9":0,"10":0,"11":0,"12":0,"13":0,"14":0,"15":0,"16":0,"17":0,"18":0,"19":0,"20":0,"21":0,"22":0,"23":0,"24":0,"25":0,"26":0,"27":0,"28":0,"29":0,"30":0,"31":0,"32":0,"33":0,"34":0,"35":0,"36":0,"37":0,"38":0,"39":0,"40":0,"41":0,"42":0,"43":0,"44":0,"45":0,"46":0,"47":0,"48":0,"49":0,"50":0,"51":0,"52":0,"53":0,"54":0,"55":1,"56":0,"57":0,"58":0,"59":0,"60":0,"61":0,"62":0,"63":0,"64":0,"65":0,"66":0,"67"
 [...]
    ReasonOfStateChanged: ErrorReason{code=errCode = 103, msg='failed to 
allocate task: Cannot invoke "Object.hashCode()" because "key" is null'}
            ErrorLogUrls:
                OtherMsg: failed to allocate task: Cannot invoke 
"Object.hashCode()" because "key" is null
                    User: root
                 Comment:
    1 row in set (0.01 sec)
    ```
    
    introduced by https://github.com/apache/doris/pull/52911, root cause is
    missing setting cluster when routine load job replay from image.
---
 .../java/org/apache/doris/load/routineload/RoutineLoadManager.java     | 3 +++
 1 file changed, 3 insertions(+)

diff --git 
a/fe/fe-core/src/main/java/org/apache/doris/load/routineload/RoutineLoadManager.java
 
b/fe/fe-core/src/main/java/org/apache/doris/load/routineload/RoutineLoadManager.java
index fcedacec8ad..1c42d8778ef 100644
--- 
a/fe/fe-core/src/main/java/org/apache/doris/load/routineload/RoutineLoadManager.java
+++ 
b/fe/fe-core/src/main/java/org/apache/doris/load/routineload/RoutineLoadManager.java
@@ -953,6 +953,9 @@ public class RoutineLoadManager implements Writable {
             if (!routineLoadJob.getState().isFinalState()) {
                 
Env.getCurrentGlobalTransactionMgr().getCallbackFactory().addCallback(routineLoadJob);
             }
+            if (Config.isCloudMode()) {
+                routineLoadJob.setCloudCluster();
+            }
         }
     }
 


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

Reply via email to