Skip to content

Conversation

@loserwang1024
Copy link
Contributor

Fix #2980. Now that PostgresSourceFetchTaskContext can only be contained by single thread now, it is no need to put into AtomicReference.

@loserwang1024
Copy link
Contributor Author

@leonardBang , @ruanhang1993 , CC

Comment on lines 305 to 308
public void close() {
public void close() throws Exception {
jdbcConnection.close();
if (replicationConnection != null) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

check null for jdbcConnection as well ?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done it

Copy link
Contributor

@leonardBang leonardBang left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @loserwang1024 for the update, LGTM

@leonardBang leonardBang merged commit 3be3417 into apache:master Jan 24, 2024
joyCurry30 pushed a commit to joyCurry30/flink-cdc-connectors that referenced this pull request Mar 22, 2024
ChaomingZhangCN pushed a commit to ChaomingZhangCN/flink-cdc that referenced this pull request Jan 13, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug] [Postgres CDC] postgresSQL database connection leak

2 participants