Skip to content
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

Feature: Optimize the replica delay api logic #45148

Merged
merged 17 commits into from
Feb 14, 2023

Conversation

mateng0915
Copy link
Contributor

@mateng0915 mateng0915 commented Jan 11, 2023

Changelog category (leave one):

  • Improvement

Changelog entry (a user-readable short description of the changes that goes to CHANGELOG.md):

Optimize behavior for a replica delay api logic in case the replica is read-only.

Description:

Currently if in the Whole CK instance has one table is read only status then the API /replicas_status will throw error, xxx table is read only and can not get other normal ReplicatedMergeTree table's delay value

Solution:

Return other normal table's delay value even if the CK instance has readonly Replicatedxxx table

Please enter the commit message for your changes. Lines starting

Information about CI checks: https://clickhouse.com/docs/en/development/continuous-integration/

Description:
============
Currently if in the Whole CK instance has one table is read only status
then the API  /replicas_status will throw error, xxx table is read only

For make this monitor can work in prod env, we can catch the read only
status instead of directly throw error

Solution:
=========
Return other normal table's delay value even if the CK instance has readonly Replicatedxxx table

Please enter the commit message for your changes. Lines starting
@robot-ch-test-poll3 robot-ch-test-poll3 added the pr-improvement Pull request with some product improvements label Jan 13, 2023
@alexey-milovidov alexey-milovidov added the can be tested Allows running workflows for external contributors label Jan 29, 2023
src/Server/ReplicasStatusHandler.cpp Outdated Show resolved Hide resolved
src/Server/ReplicasStatusHandler.cpp Outdated Show resolved Hide resolved
@mateng0915
Copy link
Contributor Author

@pufit Hello pufit can you help merge this PR, thx

@pufit
Copy link
Member

pufit commented Feb 14, 2023

@pufit Hello pufit, can you help merge this PR, thx

Yes, sure. Just wanted to run CI before merging. It's not that I've expected any bug in your commit, just a good practice in general.

@pufit pufit self-assigned this Feb 14, 2023
@pufit pufit merged commit e914e7c into ClickHouse:master Feb 14, 2023
@mateng0915 mateng0915 deleted the replicas_status_api_optimize branch February 15, 2023 03:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
can be tested Allows running workflows for external contributors pr-improvement Pull request with some product improvements
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants