1 package v1alpha1 2 3 const ( 4 // IdledAtAnnotation indicates that a given object (endpoints or scalable object)) 5 // is currently idled (and the time at which it was idled) 6 IdledAtAnnotation = "idling.alpha.openshift.io/idled-at" 7 8 // UnidleTargetAnnotation contains the references and former scales for the scalable 9 // objects associated with the idled endpoints 10 UnidleTargetAnnotation = "idling.alpha.openshift.io/unidle-targets" 11 12 // PreviousScaleAnnotation contains the previous scale of a scalable object 13 // (currently only applied by the idler) 14 PreviousScaleAnnotation = "idling.alpha.openshift.io/previous-scale" 15 16 // NeedPodsReason is the reason for the event emitted to indicate that endpoints should be unidled 17 NeedPodsReason = "NeedPods" 18 ) 19 20 // NB: if these get changed, you'll need to actually add in the full API machinery for them 21 22 // RecordedScaleReference is a CrossGroupObjectReference to a scale subresource that also 23 // has the previous replica count recorded 24 type RecordedScaleReference struct { 25 // Reference to the idled resource 26 CrossGroupObjectReference `json:",inline" protobuf:"bytes,1,opt,name=crossVersionObjectReference"` 27 // The last seen scale of the idled resource (before idling) 28 Replicas int32 `json:"replicas" protobuf:"varint,2,opt,name=replicas"` 29 } 30 31 // CrossGroupObjectReference is a reference to an object in the same 32 // namespace in the specified group. It is similar to 33 // autoscaling.CrossVersionObjectReference. 34 type CrossGroupObjectReference struct { 35 // Kind of the referent; More info: http://releases.k8s.io/release-1.3/docs/devel/api-conventions.md#types-kinds" 36 Kind string `json:"kind" protobuf:"bytes,1,opt,name=kind"` 37 // Name of the referent; More info: http://releases.k8s.io/release-1.3/docs/user-guide/identifiers.md#names 38 Name string `json:"name" protobuf:"bytes,2,opt,name=name"` 39 // API version of the referent (deprecated, prefer usng Group instead) 40 APIVersion string `json:"apiVersion,omitempty" protobuf:"bytes,3,opt,name=apiVersion"` 41 // Group of the referent 42 Group string `json:"group,omitempty" protobuf:"bytes,3,opt,name=group"` 43 } 44