From 7374aaa7116c9e0adabbf5de92af306a42df1284 Mon Sep 17 00:00:00 2001 From: qmhu Date: Wed, 6 Jul 2022 11:41:59 +0800 Subject: [PATCH] ready status for tsp --- .../deploy/prediction.crane.io_timeseriespredictions.yaml | 5 +++++ prediction/v1alpha1/types.go | 2 ++ 2 files changed, 7 insertions(+) diff --git a/artifacts/deploy/prediction.crane.io_timeseriespredictions.yaml b/artifacts/deploy/prediction.crane.io_timeseriespredictions.yaml index f28621e..f21839a 100644 --- a/artifacts/deploy/prediction.crane.io_timeseriespredictions.yaml +++ b/artifacts/deploy/prediction.crane.io_timeseriespredictions.yaml @@ -367,11 +367,16 @@ spec: type: array type: object type: array + ready: + description: Specifies whether the prediction is Ready. + type: boolean resourceIdentifier: description: ResourceIdentifier is a resource to identify the metric, but now it is just an identifier now. such as cpu, memory type: string + required: + - ready type: object type: array type: object diff --git a/prediction/v1alpha1/types.go b/prediction/v1alpha1/types.go index 4ca764e..8d402df 100644 --- a/prediction/v1alpha1/types.go +++ b/prediction/v1alpha1/types.go @@ -257,6 +257,8 @@ type PredictionMetricStatus struct { ResourceIdentifier string `json:"resourceIdentifier,omitempty"` // Prediction is the predicted time series data of the metric Prediction []*MetricTimeSeries `json:"prediction,omitempty"` + // Specifies whether the prediction is Ready. + Ready bool `json:"ready"` } // MetricTimeSeries is a stream of samples that belong to a metric with a set of labels