-
Notifications
You must be signed in to change notification settings - Fork 816
Split alertmanager & ruler configs #619
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
Comments
What is the expected gain from this change? |
Not a great deal (which is why we've not done it yet). Gains are:
Expanding on 2. Currently, all the configurations for an organization share a row. If you want to set the alertmanager config without affecting the recording/alerting rules config, you have to:
All our clients now do this, so you could argue that it's a solved problem. I feel it's a wart, that it's hard for newcomers to the code-base to understand, and that it's likely to break with some future change (e.g. to the UI). With this change, the way to change an alertmanager config will be:
Which is simpler. Writing the above, I recalled #330, which demonstrates a clear user-facing benefit: less likelihood of losing your edits to a concurrent editor. Currently, #620 does not add CAS apis. Perhaps it should. |
This issue has been automatically marked as stale because it has not had any activity in the past 30 days. It will be closed in 7 days if no further activity occurs. Thank you for your contributions. |
Currently there's one table,
configs
, keyed by (id
,orgID
), whereid
is a version number. The value is a JSON blob which has both the alertmanager config and the rules. Further, although there are separate endpoints, the implementations behind these endpoints are identical.Instead, the config systems for alertmanager and ruler should be fully disjoint.
This means we should have:
We should also separate the client libraries, embedding them in their respective call-sites (move ruler config client to ruler, alertmanager config client to alertmanager).
This will need to be multiple PRs in order to handle backwards compatibility between UI <-> configs <-> DB.
At a guess:
LMK if that needs refining (can we do it in fewer steps? would even these steps have backwards compat problems?).
I'd kind of like to kill off the configs service completely by moving the endpoints to alertmanager and ruler respectively, and having both of those services connect directly to the database. The most convenient place to make that decision is in PR 1 above, since we'll have to update UI endpoints. It will also require more PRs for juggling flags to our deployed versions.
Other stuff that we might want to consider:
The text was updated successfully, but these errors were encountered: