@@ -19,42 +19,48 @@ var (
1919)
2020
2121type IncMetricPayload struct {
22- Name string `json:"name"`
23- Labels []string `json:"labels"`
22+ Name string `json:"name"`
23+ Labels IncMetricPayloadLabels `json:"labels"`
24+ }
25+
26+ type IncMetricPayloadLabels struct {
27+ Type * string `json:"type"`
2428}
2529
2630func NewUpdateDetected () error {
2731 return sendMetrics (& IncMetricPayload {
2832 Name : "new_update_detected" ,
29- Labels : make ([] string , 0 ) ,
33+ Labels : IncMetricPayloadLabels {} ,
3034 })
3135}
3236
3337func NewUpdateProccessed () error {
3438 return sendMetrics (& IncMetricPayload {
3539 Name : "new_update_processed" ,
36- Labels : make ([] string , 0 ) ,
40+ Labels : IncMetricPayloadLabels {} ,
3741 })
3842}
3943
4044func NewUpdatePublishedKV () error {
4145 return sendMetrics (& IncMetricPayload {
4246 Name : "new_update_published_kv" ,
43- Labels : make ([] string , 0 ) ,
47+ Labels : IncMetricPayloadLabels {} ,
4448 })
4549}
4650
4751func NewUpdatePublishedR2 (ext string ) error {
4852 return sendMetrics (& IncMetricPayload {
49- Name : "new_update_published_r2" ,
50- Labels : []string {ext },
53+ Name : "new_update_published_r2" ,
54+ Labels : IncMetricPayloadLabels {
55+ Type : & ext ,
56+ },
5157 })
5258}
5359
5460func NewUpdatePublishedAlgolia () error {
5561 return sendMetrics (& IncMetricPayload {
5662 Name : "new_update_published_algolia" ,
57- Labels : make ([] string , 0 ) ,
63+ Labels : IncMetricPayloadLabels {} ,
5864 })
5965}
6066
0 commit comments