Skip to content

Conversation

@davedwwang
Copy link
Contributor

Why are the changes needed?

I hope to obtain the master-slave status of AMS through HTTP and metrics.

Close #3994.

Brief change log

Introducing a member variable to identify the master/slave status of the AMS. The HealthCheckController and AmsServiceMetrics use this field to retrieve the AMS's master/slave status.

@github-actions github-actions bot added the module:ams-server Ams server module label Dec 6, 2025
@davedwwang davedwwang force-pushed the dev/ams-ha-state branch 2 times, most recently from 44a70ff to f530254 Compare December 7, 2025 09:37
@davedwwang
Copy link
Contributor Author

hi @zhoujinsong Would you mind reviewing this? I’d really appreciate it. Thanks!

Copy link
Contributor

@zhoujinsong zhoujinsong left a comment

Choose a reason for hiding this comment

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

@davedwwang Thanks a lot for your contribution! I left a comment, PTAL.

private TServer optimizingServiceServer;
private Javalin httpServer;
private AmsServiceMetrics amsServiceMetrics;
private HAState haState = HAState.STANDBY;
Copy link
Contributor

Choose a reason for hiding this comment

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

Maybe we can add a method haState in the HighAvailabilityContainer interface.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

module:ams-server Ams server module

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Feature]: Support Exposing AMS High Availability (HA) Status

3 participants