-
Notifications
You must be signed in to change notification settings - Fork 179
[FLINK-30371] Fix the problem of JdbcOutputFormat database connection leak #75
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
base: main
Are you sure you want to change the base?
Conversation
Thanks for opening this pull request! Please check out our contributing guidelines. (https://flink.apache.org/contributing/how-to-contribute.html) |
Any news on that? |
Hi @KevDi , |
Hi @eskabetxe is there a format that should be used for the Commits? |
Should be on same format that you put on title of PT And merge commits should be avoided.. Current you have 3 commit messages, the ideal is 1 The commit in the middle is ok, the other 2 no |
Ok i try to compress the commits to one single commit :) |
@eskabetxe had to experience a little bit but now it seems that only one commit is there =) |
@MartijnVisser could you approve the workflow please |
@eskabetxe @MartijnVisser i looked into this error but i was unable to resolve it. I removed the mentioned import with explicit imports but then i get an error telling me that some of the static imports are imported before others. If i used the |
@KevDi You'll need to rebase, the Flink project doesn't do merge commits. |
…Method. This Problem leads to Connection Leaks if some problem occurs.
@MartijnVisser i have done the rebase. |
@MartijnVisser any updates on this? |
Hi, @KevDi. |
@fapaul i can try to take a look at it. Question would be if it is still enough to do the fix like i provided it here or if the solution from @tamirsagi here #5 (comment) would also work. I'm not sure about it because the error seems to come when the |
I prefer the solution via the autoclosable block because your current fix changes the semantics slightly. In case the In general, can you maybe share a full stack trace or how you are using the |
@fapaul Ok i check if i found the old code. In general the question that i have is what happens if the |
You are correct that in case an error is thrown during calling To fully confirm your scenario that, it would be helpful to understand which |
@fapaul would it make sense to change both |
I don't think that is necessary. The flush is either retried if configured or the exception fails the job, and eventually, With the current architecture of different sink implementations all depending on the |
Ok but how should the connection leak beeing fixed then? |
Sorry my previous message wasn't well-formatted (fixed now). The try-catch block around the |
I have redone the Fix from #5 because no more action is going on there.
I updated to the latest version of the main branch and also added the needed tests.
Hope this is fine so far.