Class KubeEvent.Builder
- java.lang.Object
-
- org.cdk8s.plus24.k8s.KubeEvent.Builder
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description KubeEvent.Builder
action(String action)
action is what action was taken/failed regarding to the regarding object.KubeEvent
build()
static KubeEvent.Builder
create(software.constructs.Construct scope, String id)
KubeEvent.Builder
deprecatedCount(Number deprecatedCount)
deprecatedCount is the deprecated field assuring backward compatibility with core.v1 Event type.KubeEvent.Builder
deprecatedFirstTimestamp(Instant deprecatedFirstTimestamp)
deprecatedFirstTimestamp is the deprecated field assuring backward compatibility with core.v1 Event type.KubeEvent.Builder
deprecatedLastTimestamp(Instant deprecatedLastTimestamp)
deprecatedLastTimestamp is the deprecated field assuring backward compatibility with core.v1 Event type.KubeEvent.Builder
deprecatedSource(EventSource deprecatedSource)
deprecatedSource is the deprecated field assuring backward compatibility with core.v1 Event type.KubeEvent.Builder
eventTime(Instant eventTime)
eventTime is the time when this Event was first observed.KubeEvent.Builder
metadata(ObjectMeta metadata)
Standard object's metadata.KubeEvent.Builder
note(String note)
note is a human-readable description of the status of this operation.KubeEvent.Builder
reason(String reason)
reason is why the action was taken.KubeEvent.Builder
regarding(ObjectReference regarding)
regarding contains the object this Event is about.KubeEvent.Builder
related(ObjectReference related)
related is the optional secondary object for more complex actions.KubeEvent.Builder
reportingController(String reportingController)
reportingController is the name of the controller that emitted this Event, e.g.KubeEvent.Builder
reportingInstance(String reportingInstance)
reportingInstance is the ID of the controller instance, e.g.KubeEvent.Builder
series(EventSeries series)
series is data about the Event series this event represents or nil if it's a singleton Event.KubeEvent.Builder
type(String type)
type is the type of this event (Normal, Warning), new types could be added in the future.
-
-
-
Method Detail
-
create
@Stability(Stable) public static KubeEvent.Builder create(software.constructs.Construct scope, String id)
- Parameters:
scope
- the scope in which to define this object. This parameter is required.id
- a scope-local name for the object. This parameter is required.- Returns:
- a new instance of
KubeEvent.Builder
.
-
eventTime
@Stability(Stable) public KubeEvent.Builder eventTime(Instant eventTime)
eventTime is the time when this Event was first observed.It is required.
- Parameters:
eventTime
- eventTime is the time when this Event was first observed. This parameter is required.- Returns:
this
-
action
@Stability(Stable) public KubeEvent.Builder action(String action)
action is what action was taken/failed regarding to the regarding object.It is machine-readable. This field cannot be empty for new Events and it can have at most 128 characters.
- Parameters:
action
- action is what action was taken/failed regarding to the regarding object. This parameter is required.- Returns:
this
-
deprecatedCount
@Stability(Stable) public KubeEvent.Builder deprecatedCount(Number deprecatedCount)
deprecatedCount is the deprecated field assuring backward compatibility with core.v1 Event type.- Parameters:
deprecatedCount
- deprecatedCount is the deprecated field assuring backward compatibility with core.v1 Event type. This parameter is required.- Returns:
this
-
deprecatedFirstTimestamp
@Stability(Stable) public KubeEvent.Builder deprecatedFirstTimestamp(Instant deprecatedFirstTimestamp)
deprecatedFirstTimestamp is the deprecated field assuring backward compatibility with core.v1 Event type.- Parameters:
deprecatedFirstTimestamp
- deprecatedFirstTimestamp is the deprecated field assuring backward compatibility with core.v1 Event type. This parameter is required.- Returns:
this
-
deprecatedLastTimestamp
@Stability(Stable) public KubeEvent.Builder deprecatedLastTimestamp(Instant deprecatedLastTimestamp)
deprecatedLastTimestamp is the deprecated field assuring backward compatibility with core.v1 Event type.- Parameters:
deprecatedLastTimestamp
- deprecatedLastTimestamp is the deprecated field assuring backward compatibility with core.v1 Event type. This parameter is required.- Returns:
this
-
deprecatedSource
@Stability(Stable) public KubeEvent.Builder deprecatedSource(EventSource deprecatedSource)
deprecatedSource is the deprecated field assuring backward compatibility with core.v1 Event type.- Parameters:
deprecatedSource
- deprecatedSource is the deprecated field assuring backward compatibility with core.v1 Event type. This parameter is required.- Returns:
this
-
metadata
@Stability(Stable) public KubeEvent.Builder metadata(ObjectMeta metadata)
Standard object's metadata.More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata
- Parameters:
metadata
- Standard object's metadata. This parameter is required.- Returns:
this
-
note
@Stability(Stable) public KubeEvent.Builder note(String note)
note is a human-readable description of the status of this operation.Maximal length of the note is 1kB, but libraries should be prepared to handle values up to 64kB.
- Parameters:
note
- note is a human-readable description of the status of this operation. This parameter is required.- Returns:
this
-
reason
@Stability(Stable) public KubeEvent.Builder reason(String reason)
reason is why the action was taken.It is human-readable. This field cannot be empty for new Events and it can have at most 128 characters.
- Parameters:
reason
- reason is why the action was taken. This parameter is required.- Returns:
this
-
regarding
@Stability(Stable) public KubeEvent.Builder regarding(ObjectReference regarding)
regarding contains the object this Event is about.In most cases it's an Object reporting controller implements, e.g. ReplicaSetController implements ReplicaSets and this event is emitted because it acts on some changes in a ReplicaSet object.
- Parameters:
regarding
- regarding contains the object this Event is about. This parameter is required.- Returns:
this
-
related
@Stability(Stable) public KubeEvent.Builder related(ObjectReference related)
related is the optional secondary object for more complex actions.E.g. when regarding object triggers a creation or deletion of related object.
- Parameters:
related
- related is the optional secondary object for more complex actions. This parameter is required.- Returns:
this
-
reportingController
@Stability(Stable) public KubeEvent.Builder reportingController(String reportingController)
reportingController is the name of the controller that emitted this Event, e.g. `kubernetes.io/kubelet`. This field cannot be empty for new Events.- Parameters:
reportingController
- reportingController is the name of the controller that emitted this Event, e.g. `kubernetes.io/kubelet`. This field cannot be empty for new Events. This parameter is required.- Returns:
this
-
reportingInstance
@Stability(Stable) public KubeEvent.Builder reportingInstance(String reportingInstance)
reportingInstance is the ID of the controller instance, e.g. `kubelet-xyzf`. This field cannot be empty for new Events and it can have at most 128 characters.- Parameters:
reportingInstance
- reportingInstance is the ID of the controller instance, e.g. `kubelet-xyzf`. This field cannot be empty for new Events and it can have at most 128 characters. This parameter is required.- Returns:
this
-
series
@Stability(Stable) public KubeEvent.Builder series(EventSeries series)
series is data about the Event series this event represents or nil if it's a singleton Event.- Parameters:
series
- series is data about the Event series this event represents or nil if it's a singleton Event. This parameter is required.- Returns:
this
-
type
@Stability(Stable) public KubeEvent.Builder type(String type)
type is the type of this event (Normal, Warning), new types could be added in the future.It is machine-readable. This field cannot be empty for new Events.
- Parameters:
type
- type is the type of this event (Normal, Warning), new types could be added in the future. This parameter is required.- Returns:
this
-
-