You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: CHANGELOG.md
+1
Original file line number
Diff line number
Diff line change
@@ -19,6 +19,7 @@
19
19
*[ENHANCEMENT] Query Frontend: Add setting `-frontend.forward-headers-list` in frontend to configure the set of headers from the requests to be forwarded to downstream requests. #4486
20
20
*[ENHANCEMENT] Blocks storage: Add `-blocks-storage.azure.http.*`, `-alertmanager-storage.azure.http.*`, and `-ruler-storage.azure.http.*` to configure the Azure storage client. #4581
21
21
*[ENHANCEMENT] Optimise memberlist receive path when used as a backing store for rings with a large number of members. #4601
22
+
*[ENHANCEMENT] Add length and limit to labelNameTooLongError and labelValueTooLongError #4595
22
23
*[BUGFIX] AlertManager: remove stale template files. #4495
23
24
*[BUGFIX] Distributor: fix bug in query-exemplar where some results would get dropped. #4582
message: "label name too long: %.200q metric %.200q",
33
-
cause: labelName,
34
-
series: series,
30
+
// labelNameTooLongError is a customized ValidationError, in that the cause and the series are
31
+
// formatted in different order in Error.
32
+
typelabelNameTooLongErrorstruct {
33
+
labelNamestring
34
+
series []cortexpb.LabelAdapter
35
+
limitint
36
+
}
37
+
38
+
func (e*labelNameTooLongError) Error() string {
39
+
returnfmt.Sprintf("label name too long for metric (actual: %d, limit: %d) metric: %.200q label name: %.200q", len(e.labelName), e.limit, formatLabelSet(e.series), e.labelName)
// labelValueTooLongError is a customized ValidationError, in that the cause and the series are
39
-
// are formatted in different order in Error.
51
+
// formatted in different order in Error.
40
52
typelabelValueTooLongErrorstruct {
41
53
labelValuestring
42
54
series []cortexpb.LabelAdapter
55
+
limitint
43
56
}
44
57
45
58
func (e*labelValueTooLongError) Error() string {
46
-
returnfmt.Sprintf("label value too long for metric: %.200q label value: %.200q", formatLabelSet(e.series), e.labelValue)
59
+
returnfmt.Sprintf("label value too long for metric (actual: %d, limit: %d) metric: %.200q label value: %.200q", len(e.labelValue), e.limit, formatLabelSet(e.series), e.labelValue)
0 commit comments