diff --git a/internal/api/v1/docs/swagger.json b/internal/api/v1/docs/swagger.json index 9cea7db6..290a8eee 100644 --- a/internal/api/v1/docs/swagger.json +++ b/internal/api/v1/docs/swagger.json @@ -4555,6 +4555,11 @@ "x-nullable": false, "x-omitempty": false }, + "is_excluded": { + "type": "boolean", + "x-nullable": false, + "x-omitempty": false + }, "statuses": { "type": "array", "items": { diff --git a/internal/api/v1/docs/swagger.yaml b/internal/api/v1/docs/swagger.yaml index e6744d88..f6065c92 100644 --- a/internal/api/v1/docs/swagger.yaml +++ b/internal/api/v1/docs/swagger.yaml @@ -1056,6 +1056,8 @@ definitions: type: number is_docker: type: boolean + is_excluded: + type: boolean statuses: items: $ref: '#/definitions/RouteStatus' diff --git a/internal/metrics/uptime/uptime.go b/internal/metrics/uptime/uptime.go index 11dc0718..18baf000 100644 --- a/internal/metrics/uptime/uptime.go +++ b/internal/metrics/uptime/uptime.go @@ -33,6 +33,7 @@ type ( Idle float32 `json:"idle"` AvgLatency float32 `json:"avg_latency"` IsDocker bool `json:"is_docker"` + IsExcluded bool `json:"is_excluded"` CurrentStatus types.HealthStatus `json:"current_status" swaggertype:"string" enums:"healthy,unhealthy,unknown,napping,starting"` Statuses []Status `json:"statuses"` } // @name RouteUptimeAggregate @@ -156,6 +157,7 @@ func (rs RouteStatuses) aggregate(limit int, offset int) Aggregated { CurrentStatus: status, Statuses: statuses, IsDocker: r != nil && r.IsDocker(), + IsExcluded: r == nil || r.ShouldExclude(), } } return result