You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@streampark.apache.org by "cygnusdark (via GitHub)" <gi...@apache.org> on 2023/05/05 08:05:49 UTC

[GitHub] [incubator-streampark] cygnusdark opened a new issue, #2729: [Bug] Cannot restore job from last savepoint when determined MySQL Binlog offset

cygnusdark opened a new issue, #2729:
URL: https://github.com/apache/incubator-streampark/issues/2729

   ### Search before asking
   
   - [X] I had searched in the [issues](https://github.com/apache/incubator-streampark/issues?q=is%3Aissue+label%3A%22bug%22) and found no similar issues.
   
   
   ### Java Version
   
   1.8
   
   ### Scala Version
   
   2.12.x
   
   ### StreamPark Version
   
   2.1.0
   
   ### Flink Version
   
   1.17
   
   ### deploy mode
   
   yarn-application
   
   ### What happened
   
   Cannot restore job from last savepoint when you appoint MySQL Binlog offset at the beginning.
   Steps:
   1. use "specific-offset" scan startup mode to start a job, for example:
   `'scan.startup.mode' = 'specific-offset',  'scan.startup.specific-offset.file' = 'mysql-bin.003127', 'scan.startup.specific-offset.pos' = '146217118'`
   2. Stop the job with savepoint
   3. restore the job with savepoint
   
   The error exception mentioned the binlog is no longer available on the server, but actually it exists. If you manually appoint this Binlog offset in the code, and start a new job without savepoint, the problem fixed.
   
   If the job failed again, you need to repeatedly do this procedure, which means the job loses the ability to recover itself when you appoint a Binlog offset in the code at the beginning.
   
   ### Error Exception
   
   ```log
   java.lang.runtimeexception: One or more fetchers have encountered exceptionat org.apache.flink.connector.base.source.reader.fetcher.SplitFetcherManager.checkErrors(SplitFetcherManager.java:225)at org.apache.flink.connector.base.source.reader.SourceReaderBase.getNextFetch(SourceReaderBase.java:169)at org.apache.flink.connector.base.source.reader.SourceReaderBase.pollNext(SourceReaderBase.java:130)at org.apache.flink.streaming.api.operators.SourceOperator.emitNext(SourceOperator.java:385)at org.apache.flink.streaming.runtime.io.StreamTaskSourceInput.emitNext(StreamTaskSourceInput.java:68)at org.apache.flink.streaming.runtime.io.StreamOneInputProcessor.processInput(StreamOneInputProcessor.java:65)at org.apache.flink.streaming.runtime.tasks.StreamTask.processInput(StreamTask.java:542)at org.apache.flink.streaming.runtime.tasks.mailbox.MailboxProcessor.runMailboxLoop(MailboxProcessor.java:231)at org.apache.flink.streaming.runtime.tasks.StreamTask.runMailboxLoop(StreamTask.java:831)at o
 rg.apache.flink.streaming.runtime.tasks.StreamTask.invoke(StreamTask.java:780)at org.apache.flink.runtime.taskmanager.Task.runWithSystemExitMonitoring(Task.java:935)at org.apache.flink.runtime.taskmanager.Task.restoreAndInvoke(Task.java:914)at org.apache.flink.runtime.taskmanager.Task.doRun(Task.java:728)at org.apache.flink.runtime.taskmanager.Task.run(Task.java:550)at java.lang.Thread.run(Thread.java:745)Caused by: java.lang.RuntimeException: SplitFetcher thread 0 received unexpected exception while polling the recordsat org.apache.flink.connector.base.source.reader.fetcher.SplitFetcher.runOnce(SplitFetcher.java:150)at org.apache.flink.connector.base.source.reader.fetcher.SplitFetcher.run(SplitFetcher.java:105)at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)at java.util.concurrent.FutureTask.run(FutureTask.java:266)at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadP
 oolExecutor.java:617)... 1 moreCaused by: java.lang.IllegalStateException: The connector is trying to read binlog starting at Struct{version=1.6.4.Final,connector=mysql,name=mysql_binlog_source,ts_ms=1683272027706,db=,server_id=0,file=mysql-bin.003193,pos=139496763,row=0}, but this is no longer available on the server. Reconfigure the connector to use a snapshot when needed.at com.ververica.cdc.connectors.mysql.debezium.task.context.StatefulTaskContext.loadStartingOffsetState(StatefulTaskContext.java:194)at com.ververica.cdc.connectors.mysql.debezium.task.context.StatefulTaskContext.configure(StatefulTaskContext.java:117)at com.ververica.cdc.connectors.mysql.debezium.reader.BinlogSplitReader.submitSplit(BinlogSplitReader.java:103)at com.ververica.cdc.connectors.mysql.debezium.reader.BinlogSplitReader.submitSplit(BinlogSplitReader.java:71)at com.ververica.cdc.connectors.mysql.source.reader.MySqlSplitReader.checkSplitOrStartNext(MySqlSplitReader.java:159)at com.ververica.cdc.connector
 s.mysql.source.reader.MySqlSplitReader.fetch(MySqlSplitReader.java:71)at org.apache.flink.connector.base.source.reader.fetcher.FetchTask.run(FetchTask.java:58)at org.apache.flink.connector.base.source.reader.fetcher.SplitFetcher.runOnce(SplitFetcher.java:142)... 6 more
   ```
   
   
   ### Screenshots
   
   _No response_
   
   ### Are you willing to submit PR?
   
   - [X] Yes I am willing to submit a PR!(您是否要贡献这个PR?)
   
   ### Code of Conduct
   
   - [X] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
   


-- 
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: issues-unsubscribe@streampark.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [incubator-streampark] cygnusdark closed issue #2729: [Bug] Cannot restore job from last savepoint when appoint MySQL Binlog offset at the beginning

Posted by "cygnusdark (via GitHub)" <gi...@apache.org>.
cygnusdark closed issue #2729: [Bug] Cannot restore job from last savepoint when appoint MySQL Binlog offset at the beginning
URL: https://github.com/apache/incubator-streampark/issues/2729


-- 
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: issues-unsubscribe@streampark.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org