Skip to content

Refactor Ruler/Alertmanager API & Decouple configdb #1513

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

Closed
wants to merge 60 commits into from
Closed
Changes from 1 commit
Commits
Show all changes
60 commits
Select commit Hold shift + click to select a range
10f3000
basic version of gcs backed ruler
jtlisi Jun 14, 2019
c7aafaf
fix gcs configdb config function receiver to be pointer
jtlisi Jun 14, 2019
f8c9eaf
don't return error if no config for user is currenty set
jtlisi Jun 14, 2019
1ba663c
fix adding configs when none exist
jtlisi Jun 14, 2019
fb55660
ensure setting configs in gcs performs cas
jtlisi Jun 14, 2019
9656eb3
add debug logging to gcs configdb
jtlisi Jun 14, 2019
865008d
fix unmarshalling rules from gcs
jtlisi Jun 14, 2019
dfcbc2f
initial refactor of config backend apis
jtlisi Jun 25, 2019
2bd16dc
add debug logging and fix yaml response for rules
jtlisi Jun 25, 2019
fcfcc9b
return 404 when no rule groups are found
jtlisi Jun 26, 2019
eebd400
add set rule group api and fix rule gcs backend
jtlisi Jun 27, 2019
f4a78aa
add logging statements to read logging api
jtlisi Jun 27, 2019
c2a70f3
fix list rules for GCS rule store
jtlisi Jun 27, 2019
228a898
fix listing rule namesaces
jtlisi Jun 27, 2019
502e70a
fix polling and add xtra logging
jtlisi Jun 27, 2019
e768c31
fix double printing api response
jtlisi Jun 27, 2019
a13f738
fix listing rules with namespace
jtlisi Jun 27, 2019
3e68394
fix gcs listing rules by namespace
jtlisi Jun 27, 2019
a7621f4
fix test cases
jtlisi Jun 27, 2019
2dbc85e
return map instead of array for rules api
jtlisi Jun 28, 2019
cd902a2
fix alert prefix for gcs config backend
jtlisi Jun 28, 2019
343bf9b
fix ruler test
jtlisi Jun 28, 2019
13c6b00
fix setting namespace for rule creation
jtlisi Jun 30, 2019
4bdee83
update rule group creation endpoint
jtlisi Jul 2, 2019
2b474f9
remove unused metrics and add user metric for evaluation failures
jtlisi Jul 6, 2019
71984c9
add comment for later group instrumentation
jtlisi Jul 7, 2019
299f4d2
use promauto to register metrics
jtlisi Jul 7, 2019
5fbc094
fix log messages for owning rules
jtlisi Jul 8, 2019
516da88
fix typos
jtlisi Jul 8, 2019
0a9f184
keep namespace in struct for file parsing, unexport gcs error
jtlisi Jul 8, 2019
ae19f69
use rulegroup in groupfn function
jtlisi Jul 9, 2019
325861d
refactor package names and function names
jtlisi Jul 9, 2019
4d6b5e6
rename things
jtlisi Jul 10, 2019
f9763e5
fix s3 client to panic until implemented
jtlisi Jul 11, 2019
f374d63
refactor configdb and config storage clients
jtlisi Jul 11, 2019
03e722d
update poller to return storage
jtlisi Jul 12, 2019
109f65f
fix client tests
jtlisi Jul 12, 2019
f4cc733
remove unused config client
jtlisi Jul 12, 2019
ef85704
refactor configdb client package
jtlisi Jul 12, 2019
d0ebeef
add debug log line with rule eval latency
jtlisi Jul 12, 2019
ec7aabb
update eval latency bucket sizes
jtlisi Jul 12, 2019
440fbb5
update rule eval timestamp when iteration is missed
jtlisi Jul 14, 2019
ef0ec50
reorganize scheduling instrumentation
jtlisi Jul 14, 2019
e78e356
increase size of eval duration buckets
jtlisi Jul 14, 2019
3c94e10
readd total configs metric
jtlisi Jul 15, 2019
eaa6bf1
pass user id as label to the rule group metrics
jtlisi Jul 15, 2019
f7f28bb
pass user id to prometheus rule group metrics
jtlisi Jul 16, 2019
ad0dd20
refactor to use kv store to check for config updates
jtlisi Jul 18, 2019
962db79
add logs and comments
jtlisi Jul 19, 2019
e6d8952
return 404 when rule group is not found
jtlisi Jul 19, 2019
18f96ce
add delete rule group feature
jtlisi Jul 19, 2019
1c04055
fix linting and tests
jtlisi Jul 22, 2019
8ea8cc7
fix ruler tests by adding mutex to mock store
jtlisi Jul 22, 2019
234411b
mod tidy
jtlisi Jul 22, 2019
5172d08
remove aws config backend until later
jtlisi Jul 22, 2019
12d98fc
remove unused package
jtlisi Jul 23, 2019
7f3d836
move storage definitions to storage subpackages
jtlisi Jul 23, 2019
4e0c50c
ensure alertmanager config flags are registered
jtlisi Jul 23, 2019
559771f
fix rebase error
jtlisi Jul 23, 2019
0fff90b
add lateness to work item debug log line
jtlisi Jul 23, 2019
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
fix double printing api response
Signed-off-by: Jacob Lisi <jacob.t.lisi@gmail.com>
  • Loading branch information
jtlisi committed Jul 23, 2019
commit e768c3197f296c7271f53f44f7780aa50c0f32cb
2 changes: 0 additions & 2 deletions pkg/ruler/api.go
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,6 @@ func (a *API) listRules(w http.ResponseWriter, r *http.Request) {
}

w.Header().Set("Content-Type", "application/yaml")
w.Write(d)
if _, err := w.Write(d); err != nil {
level.Error(logger).Log("msg", "error writing yaml response", "err", err)
http.Error(w, err.Error(), http.StatusInternalServerError)
Expand Down Expand Up @@ -159,7 +158,6 @@ func (a *API) getRuleGroup(w http.ResponseWriter, r *http.Request) {
}

w.Header().Set("Content-Type", "application/yaml")
w.Write(d)
if _, err := w.Write(d); err != nil {
level.Error(logger).Log("msg", "error writing yaml response", "err", err)
http.Error(w, err.Error(), http.StatusInternalServerError)
Expand Down