You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The "onChannelDisconnect" function in class NettyHttpRdsCdcReaderConnection will enqueue another state object into "messageQueue" of the fetch thread When the netty connection is lost.
privatevoidonChannelDisconnect() {
log.warn("Fetch thread disconnected from remote server " + targetServer);
if (!this.getState()
.equals(State.CLOSING) && !this.getState()
.equals(State.CLOSED)) {
this.fetchThreadState.setStateId(FetchThreadState.StateId.PICK_SERVER);
this.fetchThread.enqueueMessage(this.fetchThreadState); // it isthis.setState(State.CLOSED);
} else {
log.warn("Fetch thread connection is already closed.");
}
}
The bug may cause a data loss risk. Because two state in "messageQueue" of the fetch thread will cause two fetching reader event in a short time. Meanwhile, the dispatch class is a a non-thread-safe while doing events distribution.
Expected Behavior
Only one state object contains in the "messageQueue" of the fetch thread.
Actual Behavior
There is more than one state object exists in "messageQueue" of the fetch thread.
The text was updated successfully, but these errors were encountered:
Environment
Ptubes version: 1.0.0
Operating System version: Linux
Java version: 1.8
Steps to reproduce this issue
The "onChannelDisconnect" function in class NettyHttpRdsCdcReaderConnection will enqueue another state object into "messageQueue" of the fetch thread When the netty connection is lost.
The bug may cause a data loss risk. Because two state in "messageQueue" of the fetch thread will cause two fetching reader event in a short time. Meanwhile, the dispatch class is a a non-thread-safe while doing events distribution.
Expected Behavior
Only one state object contains in the "messageQueue" of the fetch thread.
Actual Behavior
There is more than one state object exists in "messageQueue" of the fetch thread.
The text was updated successfully, but these errors were encountered: