-
Notifications
You must be signed in to change notification settings - Fork 1.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Fix][Connector-V2] Fix paimon sink restore error #8598
base: dev
Are you sure you want to change the base?
Conversation
Hey @uniding , Can you please guide me how did you verify the changes made by you actually solved the bug? I can ping you on the slack channel as well |
@@ -245,7 +245,6 @@ public synchronized void init(long initializationTimestamp, boolean restart) thr | |||
try { | |||
Thread.currentThread().setContextClassLoader(classLoader); | |||
if (!restart | |||
&& !logicalDag.isStartWithSavePoint() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why remove this?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- Execute the following command to start from savepoint, which will result in errors. Please refer to the bug for details
seatunnel.sh -c paimon.config -r 938988912087400449 -n m2p - After analysis and debugging, it was found that starting from savepoint does not execute the JobMaster::handleSaveMode method, so the handleSchemaSaveMode method of the PaimonSaveModeHandler class is not executed,Causing PaimonSink related member variables(paimonTable variable) to not be initialized resulting in a null pointer error when writing paimon
3.The relevant code call stack is shown in the following figure:
![image](https://private-user-images.githubusercontent.com/116274818/410243054-57b394d3-6043-43c4-a67f-4c7de8626790.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MzkxOTQ5NzYsIm5iZiI6MTczOTE5NDY3NiwicGF0aCI6Ii8xMTYyNzQ4MTgvNDEwMjQzMDU0LTU3YjM5NGQzLTYwNDMtNDNjNC1hNjdmLTRjN2RlODYyNjc5MC5wbmc_WC1BbXotQWxnb3JpdGhtPUFXUzQtSE1BQy1TSEEyNTYmWC1BbXotQ3JlZG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AZ2HWqrM9TuILouPibhZhaJtHeOcCEOu4)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we should move setLoadTable
method out from handleSchemaSaveMode
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we should move
setLoadTable
method out fromhandleSchemaSaveMode
.
why add !logicalDag.isStartWithSavePoint()?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
SchemaSaveMode used to create table or truncate table. When job start with savepoint, that's meaning the table already created or truncated. So we can not do it again.
#8460
Purpose of this pull request
Does this PR introduce any user-facing change?
How was this patch tested?
Check list
New License Guide
release-note
.