bithw1 commented on issue #17658:
URL: https://github.com/apache/hudi/issues/17658#issuecomment-3680055921

   Thanks @cshuo for the reply, I run the SQL in the same Flink SQL Client and 
don't modify the sql,but add one extra configuration(specify the savepoint 
dir). Following are the detail steps:
   
   1. In the same Flink SQL Client, I first run the following sql to set the 
configuration
   
   ```
   set execution.checkpointing.interval=10000;
   set 
'state.checkpoints.dir'='hdfs:///flink/checkpoints/test_flink_incremental_second_20251221_03';
   set 
'execution.checkpointing.externalized-checkpoint-retention'='RETAIN_ON_CANCELLATION';
   set 'state.checkpoints.num-retained'='60';
   set execution.checkpointing.num-retained-checkpoint=80;
   ```
   
   2. Then in the same SQL Client, I run the following continuous sql
   
   ```
   insert into test_sink_second_20251221_03  select * from 
test_flink_incremental_second_20251221_03
   /*+ 
   options(
       'read.streaming.enabled'='true',
       'read.streaming.check-interval' = '4',
       'read.start-commit' = '20251215134527179'
   ) 
   */
   ```
   
   3. After a while, I cancel the job from the Flink Web UI, and in the same 
Flink SQL Client
   
   .4 I add the savepoint dir configuration so that Flink SQL could restart 
from the saved checkpoint 
   
   ```
   set 
execution.savepoint.path='hdfs:///flink/checkpoints/test_flink_incremental_second_20251221_03/d7cc6b5d643f3a8976df93f6e9aa0c48/chk-9';
   
   ```
   
   5. I run the same insert select sql again
   
   ```
   insert into test_sink_second_20251221_03  select * from 
test_flink_incremental_second_20251221_03
   /*+ 
   options(
       'read.streaming.enabled'='true',
       'read.streaming.check-interval' = '4',
       'read.start-commit' = '20251215134527179'
   ) 
   */
   ```
   
   6. Error occurred when I run the step 5, complaining 
   ```
   [ERROR] Could not execute SQL statement. Reason:
   java.lang.IllegalStateException: Failed to rollback to checkpoint/savepoint 
hdfs://hadoop.master:9000/flink/checkpoints/test_flink_incremental_second_20251221_03/d7cc6b5d643f3a8976df93f6e9aa0c48/chk-9.
    Cannot map checkpoint/savepoint state for operator 
c43c1940ad62bf3bc996ebfabca09279 to the new program, because the operator is 
not available in the new program. If you want to allow to skip this, you can 
set the --allowNonRestoredState option on the CLI.
   
   ```
   
   
   
   
   
   


-- 
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]

Reply via email to