@@ -2427,33 +2427,45 @@ type RemoteConfigConfiguration struct {
24272427}
24282428
24292429// ExperimentPhase is the lifecycle phase of a Fleet Automation experiment.
2430- // +kubebuilder:validation:Enum=running;stopped;rollback;timeout ;promoted;aborted
2430+ // +kubebuilder:validation:Enum=running;terminated ;promoted;aborted
24312431type ExperimentPhase string
24322432
24332433const (
2434- // ExperimentPhaseRunning is set by RC when an experiment starts (startExperiment) .
2434+ // ExperimentPhaseRunning is set by the reconciler when it processes a start signal .
24352435 ExperimentPhaseRunning ExperimentPhase = "running"
2436- // ExperimentPhaseStopped is set by RC to request a rollback (stopExperiment).
2437- ExperimentPhaseStopped ExperimentPhase = "stopped"
2438- // ExperimentPhaseRollback is set by the operator after processing a stopped signal and restoring the previous spec.
2439- ExperimentPhaseRollback ExperimentPhase = "rollback"
2440- // ExperimentPhaseTimeout is set by the operator when the experiment exceeds the timeout and is auto-rolled back.
2441- ExperimentPhaseTimeout ExperimentPhase = "timeout"
2442- // ExperimentPhasePromoted is set by RC when an experiment succeeds (promoteExperiment).
2436+ // ExperimentPhaseTerminated is set by the reconciler after restoring the previous spec,
2437+ // either due to an explicit rollback signal or a timeout. The TerminationReason field
2438+ // distinguishes the cause.
2439+ ExperimentPhaseTerminated ExperimentPhase = "terminated"
2440+ // ExperimentPhasePromoted is set by the reconciler when a promote signal is processed.
24432441 ExperimentPhasePromoted ExperimentPhase = "promoted"
2444- // ExperimentPhaseAborted is set by the operator when a manual spec change is detected during a running experiment.
2442+ // ExperimentPhaseAborted is set by the reconciler when a manual spec change is detected during a running experiment.
24452443 ExperimentPhaseAborted ExperimentPhase = "aborted"
24462444)
24472445
2446+ // Experiment signal values written to the AnnotationExperimentSignal annotation.
2447+ const (
2448+ // ExperimentSignalStart requests a new experiment to begin.
2449+ ExperimentSignalStart = "start"
2450+ // ExperimentSignalRollback requests the current experiment to roll back.
2451+ ExperimentSignalRollback = "rollback"
2452+ // ExperimentSignalPromote requests the current experiment to be promoted.
2453+ ExperimentSignalPromote = "promote"
2454+ )
2455+
24482456// ExperimentStatus defines the state of a Fleet Automation experiment.
24492457// +k8s:openapi-gen=true
24502458type ExperimentStatus struct {
24512459 // Phase is the current state of the experiment.
24522460 // +optional
24532461 Phase ExperimentPhase `json:"phase,omitempty"`
2454- // ID is the unique experiment ID sent by Fleet Automation .
2462+ // ID is the RC task ID that triggered this experiment state .
24552463 // +optional
24562464 ID string `json:"id,omitempty"`
2465+ // TerminationReason distinguishes why the experiment was terminated.
2466+ // Only set when Phase is "terminated".
2467+ // +optional
2468+ TerminationReason string `json:"terminationReason,omitempty"`
24572469}
24582470
24592471// DatadogAgentStatus defines the observed state of DatadogAgent.
0 commit comments