forked from apache/pulsar
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[fix][broker] Fix out of order data replication (apache#17154)
* [fix][broker] Fix out of order data replication ### Motivation The schema replication will break the data replication order while fetching the schema from the local cluster. https://github.com/apache/pulsar/blob/8a6ecd7d4c9399bb7ce5a224ca854e4a71db79b1/pulsar-broker/src/main/java/org/apache/pulsar/broker/service/persistent/PersistentReplicator.java#L366-L369 The method getSchemaInfo() is an async method that will reverse the order in which messages are written. ### Modification Added a new state for replicator `fetchSchemaInProgress` which means the replicator had detected a new schema that needed to fetch the schema info from the local cluster. During the schema fetching, the replicator should pause the data replicator and resume after the schema has been fetched.
- Loading branch information
1 parent
f6fd6b7
commit 39c1ee1
Showing
2 changed files
with
79 additions
and
21 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters