All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.pulumi.kubernetes.events.v1.EventArgs Maven / Gradle / Ivy

There is a newer version: 4.19.0-alpha.1730750641
Show newest version
// *** WARNING: this file was generated by pulumi-java-gen. ***
// *** Do not edit by hand unless you're certain you know what you are doing! ***

package com.pulumi.kubernetes.events.v1;

import com.pulumi.core.Output;
import com.pulumi.core.annotations.Import;
import com.pulumi.core.internal.Codegen;
import com.pulumi.exceptions.MissingRequiredPropertyException;
import com.pulumi.kubernetes.core.v1.inputs.EventSourceArgs;
import com.pulumi.kubernetes.core.v1.inputs.ObjectReferenceArgs;
import com.pulumi.kubernetes.events.v1.inputs.EventSeriesArgs;
import com.pulumi.kubernetes.meta.v1.inputs.ObjectMetaArgs;
import java.lang.Integer;
import java.lang.String;
import java.util.Objects;
import java.util.Optional;
import javax.annotation.Nullable;


public final class EventArgs extends com.pulumi.resources.ResourceArgs {

    public static final EventArgs Empty = new EventArgs();

    /**
     * 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.
     * 
     */
    @Import(name="action")
    private @Nullable Output action;

    /**
     * @return 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.
     * 
     */
    public Optional> action() {
        return Optional.ofNullable(this.action);
    }

    /**
     * APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources
     * 
     */
    @Import(name="apiVersion")
    private @Nullable Output apiVersion;

    /**
     * @return APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources
     * 
     */
    public Optional> apiVersion() {
        return Optional.ofNullable(this.apiVersion);
    }

    /**
     * deprecatedCount is the deprecated field assuring backward compatibility with core.v1 Event type.
     * 
     */
    @Import(name="deprecatedCount")
    private @Nullable Output deprecatedCount;

    /**
     * @return deprecatedCount is the deprecated field assuring backward compatibility with core.v1 Event type.
     * 
     */
    public Optional> deprecatedCount() {
        return Optional.ofNullable(this.deprecatedCount);
    }

    /**
     * deprecatedFirstTimestamp is the deprecated field assuring backward compatibility with core.v1 Event type.
     * 
     */
    @Import(name="deprecatedFirstTimestamp")
    private @Nullable Output deprecatedFirstTimestamp;

    /**
     * @return deprecatedFirstTimestamp is the deprecated field assuring backward compatibility with core.v1 Event type.
     * 
     */
    public Optional> deprecatedFirstTimestamp() {
        return Optional.ofNullable(this.deprecatedFirstTimestamp);
    }

    /**
     * deprecatedLastTimestamp is the deprecated field assuring backward compatibility with core.v1 Event type.
     * 
     */
    @Import(name="deprecatedLastTimestamp")
    private @Nullable Output deprecatedLastTimestamp;

    /**
     * @return deprecatedLastTimestamp is the deprecated field assuring backward compatibility with core.v1 Event type.
     * 
     */
    public Optional> deprecatedLastTimestamp() {
        return Optional.ofNullable(this.deprecatedLastTimestamp);
    }

    /**
     * deprecatedSource is the deprecated field assuring backward compatibility with core.v1 Event type.
     * 
     */
    @Import(name="deprecatedSource")
    private @Nullable Output deprecatedSource;

    /**
     * @return deprecatedSource is the deprecated field assuring backward compatibility with core.v1 Event type.
     * 
     */
    public Optional> deprecatedSource() {
        return Optional.ofNullable(this.deprecatedSource);
    }

    /**
     * eventTime is the time when this Event was first observed. It is required.
     * 
     */
    @Import(name="eventTime", required=true)
    private Output eventTime;

    /**
     * @return eventTime is the time when this Event was first observed. It is required.
     * 
     */
    public Output eventTime() {
        return this.eventTime;
    }

    /**
     * Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds
     * 
     */
    @Import(name="kind")
    private @Nullable Output kind;

    /**
     * @return Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds
     * 
     */
    public Optional> kind() {
        return Optional.ofNullable(this.kind);
    }

    /**
     * Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata
     * 
     */
    @Import(name="metadata")
    private @Nullable Output metadata;

    /**
     * @return Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata
     * 
     */
    public Optional> metadata() {
        return Optional.ofNullable(this.metadata);
    }

    /**
     * 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.
     * 
     */
    @Import(name="note")
    private @Nullable Output note;

    /**
     * @return 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.
     * 
     */
    public Optional> note() {
        return Optional.ofNullable(this.note);
    }

    /**
     * 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.
     * 
     */
    @Import(name="reason")
    private @Nullable Output reason;

    /**
     * @return 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.
     * 
     */
    public Optional> reason() {
        return Optional.ofNullable(this.reason);
    }

    /**
     * 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.
     * 
     */
    @Import(name="regarding")
    private @Nullable Output regarding;

    /**
     * @return 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.
     * 
     */
    public Optional> regarding() {
        return Optional.ofNullable(this.regarding);
    }

    /**
     * related is the optional secondary object for more complex actions. E.g. when regarding object triggers a creation or deletion of related object.
     * 
     */
    @Import(name="related")
    private @Nullable Output related;

    /**
     * @return related is the optional secondary object for more complex actions. E.g. when regarding object triggers a creation or deletion of related object.
     * 
     */
    public Optional> related() {
        return Optional.ofNullable(this.related);
    }

    /**
     * reportingController is the name of the controller that emitted this Event, e.g. `kubernetes.io/kubelet`. This field cannot be empty for new Events.
     * 
     */
    @Import(name="reportingController")
    private @Nullable Output reportingController;

    /**
     * @return reportingController is the name of the controller that emitted this Event, e.g. `kubernetes.io/kubelet`. This field cannot be empty for new Events.
     * 
     */
    public Optional> reportingController() {
        return Optional.ofNullable(this.reportingController);
    }

    /**
     * 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.
     * 
     */
    @Import(name="reportingInstance")
    private @Nullable Output reportingInstance;

    /**
     * @return 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.
     * 
     */
    public Optional> reportingInstance() {
        return Optional.ofNullable(this.reportingInstance);
    }

    /**
     * series is data about the Event series this event represents or nil if it's a singleton Event.
     * 
     */
    @Import(name="series")
    private @Nullable Output series;

    /**
     * @return series is data about the Event series this event represents or nil if it's a singleton Event.
     * 
     */
    public Optional> series() {
        return Optional.ofNullable(this.series);
    }

    /**
     * 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.
     * 
     */
    @Import(name="type")
    private @Nullable Output type;

    /**
     * @return 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.
     * 
     */
    public Optional> type() {
        return Optional.ofNullable(this.type);
    }

    private EventArgs() {}

    private EventArgs(EventArgs $) {
        this.action = $.action;
        this.apiVersion = $.apiVersion;
        this.deprecatedCount = $.deprecatedCount;
        this.deprecatedFirstTimestamp = $.deprecatedFirstTimestamp;
        this.deprecatedLastTimestamp = $.deprecatedLastTimestamp;
        this.deprecatedSource = $.deprecatedSource;
        this.eventTime = $.eventTime;
        this.kind = $.kind;
        this.metadata = $.metadata;
        this.note = $.note;
        this.reason = $.reason;
        this.regarding = $.regarding;
        this.related = $.related;
        this.reportingController = $.reportingController;
        this.reportingInstance = $.reportingInstance;
        this.series = $.series;
        this.type = $.type;
    }

    public static Builder builder() {
        return new Builder();
    }
    public static Builder builder(EventArgs defaults) {
        return new Builder(defaults);
    }

    public static final class Builder {
        private EventArgs $;

        public Builder() {
            $ = new EventArgs();
        }

        public Builder(EventArgs defaults) {
            $ = new EventArgs(Objects.requireNonNull(defaults));
        }

        /**
         * @param 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.
         * 
         * @return builder
         * 
         */
        public Builder action(@Nullable Output action) {
            $.action = action;
            return this;
        }

        /**
         * @param 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.
         * 
         * @return builder
         * 
         */
        public Builder action(String action) {
            return action(Output.of(action));
        }

        /**
         * @param apiVersion APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources
         * 
         * @return builder
         * 
         */
        public Builder apiVersion(@Nullable Output apiVersion) {
            $.apiVersion = apiVersion;
            return this;
        }

        /**
         * @param apiVersion APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources
         * 
         * @return builder
         * 
         */
        public Builder apiVersion(String apiVersion) {
            return apiVersion(Output.of(apiVersion));
        }

        /**
         * @param deprecatedCount deprecatedCount is the deprecated field assuring backward compatibility with core.v1 Event type.
         * 
         * @return builder
         * 
         */
        public Builder deprecatedCount(@Nullable Output deprecatedCount) {
            $.deprecatedCount = deprecatedCount;
            return this;
        }

        /**
         * @param deprecatedCount deprecatedCount is the deprecated field assuring backward compatibility with core.v1 Event type.
         * 
         * @return builder
         * 
         */
        public Builder deprecatedCount(Integer deprecatedCount) {
            return deprecatedCount(Output.of(deprecatedCount));
        }

        /**
         * @param deprecatedFirstTimestamp deprecatedFirstTimestamp is the deprecated field assuring backward compatibility with core.v1 Event type.
         * 
         * @return builder
         * 
         */
        public Builder deprecatedFirstTimestamp(@Nullable Output deprecatedFirstTimestamp) {
            $.deprecatedFirstTimestamp = deprecatedFirstTimestamp;
            return this;
        }

        /**
         * @param deprecatedFirstTimestamp deprecatedFirstTimestamp is the deprecated field assuring backward compatibility with core.v1 Event type.
         * 
         * @return builder
         * 
         */
        public Builder deprecatedFirstTimestamp(String deprecatedFirstTimestamp) {
            return deprecatedFirstTimestamp(Output.of(deprecatedFirstTimestamp));
        }

        /**
         * @param deprecatedLastTimestamp deprecatedLastTimestamp is the deprecated field assuring backward compatibility with core.v1 Event type.
         * 
         * @return builder
         * 
         */
        public Builder deprecatedLastTimestamp(@Nullable Output deprecatedLastTimestamp) {
            $.deprecatedLastTimestamp = deprecatedLastTimestamp;
            return this;
        }

        /**
         * @param deprecatedLastTimestamp deprecatedLastTimestamp is the deprecated field assuring backward compatibility with core.v1 Event type.
         * 
         * @return builder
         * 
         */
        public Builder deprecatedLastTimestamp(String deprecatedLastTimestamp) {
            return deprecatedLastTimestamp(Output.of(deprecatedLastTimestamp));
        }

        /**
         * @param deprecatedSource deprecatedSource is the deprecated field assuring backward compatibility with core.v1 Event type.
         * 
         * @return builder
         * 
         */
        public Builder deprecatedSource(@Nullable Output deprecatedSource) {
            $.deprecatedSource = deprecatedSource;
            return this;
        }

        /**
         * @param deprecatedSource deprecatedSource is the deprecated field assuring backward compatibility with core.v1 Event type.
         * 
         * @return builder
         * 
         */
        public Builder deprecatedSource(EventSourceArgs deprecatedSource) {
            return deprecatedSource(Output.of(deprecatedSource));
        }

        /**
         * @param eventTime eventTime is the time when this Event was first observed. It is required.
         * 
         * @return builder
         * 
         */
        public Builder eventTime(Output eventTime) {
            $.eventTime = eventTime;
            return this;
        }

        /**
         * @param eventTime eventTime is the time when this Event was first observed. It is required.
         * 
         * @return builder
         * 
         */
        public Builder eventTime(String eventTime) {
            return eventTime(Output.of(eventTime));
        }

        /**
         * @param kind Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds
         * 
         * @return builder
         * 
         */
        public Builder kind(@Nullable Output kind) {
            $.kind = kind;
            return this;
        }

        /**
         * @param kind Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds
         * 
         * @return builder
         * 
         */
        public Builder kind(String kind) {
            return kind(Output.of(kind));
        }

        /**
         * @param metadata Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata
         * 
         * @return builder
         * 
         */
        public Builder metadata(@Nullable Output metadata) {
            $.metadata = metadata;
            return this;
        }

        /**
         * @param metadata Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata
         * 
         * @return builder
         * 
         */
        public Builder metadata(ObjectMetaArgs metadata) {
            return metadata(Output.of(metadata));
        }

        /**
         * @param 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.
         * 
         * @return builder
         * 
         */
        public Builder note(@Nullable Output note) {
            $.note = note;
            return this;
        }

        /**
         * @param 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.
         * 
         * @return builder
         * 
         */
        public Builder note(String note) {
            return note(Output.of(note));
        }

        /**
         * @param 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.
         * 
         * @return builder
         * 
         */
        public Builder reason(@Nullable Output reason) {
            $.reason = reason;
            return this;
        }

        /**
         * @param 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.
         * 
         * @return builder
         * 
         */
        public Builder reason(String reason) {
            return reason(Output.of(reason));
        }

        /**
         * @param 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.
         * 
         * @return builder
         * 
         */
        public Builder regarding(@Nullable Output regarding) {
            $.regarding = regarding;
            return this;
        }

        /**
         * @param 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.
         * 
         * @return builder
         * 
         */
        public Builder regarding(ObjectReferenceArgs regarding) {
            return regarding(Output.of(regarding));
        }

        /**
         * @param related related is the optional secondary object for more complex actions. E.g. when regarding object triggers a creation or deletion of related object.
         * 
         * @return builder
         * 
         */
        public Builder related(@Nullable Output related) {
            $.related = related;
            return this;
        }

        /**
         * @param related related is the optional secondary object for more complex actions. E.g. when regarding object triggers a creation or deletion of related object.
         * 
         * @return builder
         * 
         */
        public Builder related(ObjectReferenceArgs related) {
            return related(Output.of(related));
        }

        /**
         * @param 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.
         * 
         * @return builder
         * 
         */
        public Builder reportingController(@Nullable Output reportingController) {
            $.reportingController = reportingController;
            return this;
        }

        /**
         * @param 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.
         * 
         * @return builder
         * 
         */
        public Builder reportingController(String reportingController) {
            return reportingController(Output.of(reportingController));
        }

        /**
         * @param 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.
         * 
         * @return builder
         * 
         */
        public Builder reportingInstance(@Nullable Output reportingInstance) {
            $.reportingInstance = reportingInstance;
            return this;
        }

        /**
         * @param 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.
         * 
         * @return builder
         * 
         */
        public Builder reportingInstance(String reportingInstance) {
            return reportingInstance(Output.of(reportingInstance));
        }

        /**
         * @param series series is data about the Event series this event represents or nil if it's a singleton Event.
         * 
         * @return builder
         * 
         */
        public Builder series(@Nullable Output series) {
            $.series = series;
            return this;
        }

        /**
         * @param series series is data about the Event series this event represents or nil if it's a singleton Event.
         * 
         * @return builder
         * 
         */
        public Builder series(EventSeriesArgs series) {
            return series(Output.of(series));
        }

        /**
         * @param 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.
         * 
         * @return builder
         * 
         */
        public Builder type(@Nullable Output type) {
            $.type = type;
            return this;
        }

        /**
         * @param 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.
         * 
         * @return builder
         * 
         */
        public Builder type(String type) {
            return type(Output.of(type));
        }

        public EventArgs build() {
            $.apiVersion = Codegen.stringProp("apiVersion").output().arg($.apiVersion).getNullable();
            if ($.eventTime == null) {
                throw new MissingRequiredPropertyException("EventArgs", "eventTime");
            }
            $.kind = Codegen.stringProp("kind").output().arg($.kind).getNullable();
            return $;
        }
    }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy