-
Notifications
You must be signed in to change notification settings - Fork 1k
[skip-ci] [WIP] feat: implement PostgreSQL cluster synchronization with architectural improvements #5234
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
Open
renecannao
wants to merge
19
commits into
v3.0
Choose a base branch
from
fix/postgresql-cluster-sync
base: v3.0
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
+2,006
β520
Open
[skip-ci] [WIP] feat: implement PostgreSQL cluster synchronization with architectural improvements #5234
Changes from all commits
Commits
Show all changes
19 commits
Select commit
Hold shift + click to select a range
b67c7c1
feat: Implement PostgreSQL cluster synchronization for issue #5147
renecannao d96be35
fix: Add pgsql_servers_v2 to runtime_checksums_values table and creatβ¦
renecannao e0dec1c
fix: Complete pgsql_servers_v2 checksum integration in runtime_checksβ¦
renecannao 958d250
fix: Correct PostgreSQL query rules cluster sync implementation
renecannao 7a08167
fix: Correct PostgreSQL checksum structure field names
renecannao 87a64b7
fix: Add missing PostgreSQL includes and fix type conversion warnings
renecannao 187b71e
fix: Correct TAP test syntax according to TAP_TESTS_GUIDE.md
renecannao 697b68e
docs: Add comprehensive Doxygen documentation for PostgreSQL cluster β¦
renecannao 2444456
refactor: Add memory management helper to reduce code duplication
renecannao 1d73967
refactor: Add safe_update_peer_info helper function
renecannao 9ec6bef
refactor: Eliminate massive duplication in set_checksums() and fix crβ¦
renecannao a3130ca
feat: Complete PostgreSQL cluster synchronization with pgsql_variableβ¦
renecannao e2d6411
Refactor ProxySQL_Cluster: Eliminate code duplication and modernize aβ¦
renecannao 2c9bb51
refactor: Optimize process_component_checksum() and eliminate repetitβ¦
renecannao 2c08e77
refactor: Implement loop-based sync decision optimization for admin_vβ¦
renecannao c2a05ae
refactor: Apply enabled_check() pattern to ChecksumModuleInfo for uniβ¦
renecannao c97cca0
refactor: unify ChecksumModuleInfo and SyncModuleConfig structures
renecannao c37481a
feat: add missing PostgreSQL variables sync metrics counters
renecannao 4503c58
refactor: unify duplicate get_peer_to_sync_* variables functions
renecannao File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or 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 hidden or 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
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
The
WHEREclause inCLUSTER_QUERY_RUNTIME_PGSQL_SERVERSappears to be incorrect. It usesWHERE status<>'OFFLINE_HARD', comparing the integerstatuscolumn with a string literal. In SQLite, this comparison will likely convert the string to0, resulting in an effective clause ofWHERE status <> 0, which is not the intent. This will fail to filter out servers withstatus=3(OFFLINE_HARD).The clause should be
WHERE status <> 3to correctly filter by the integer status code.Additionally, the Doxygen comment for this query is misleading as it lists
OFFLINE_HARDas a possible output status, while the query intends to filter it out.