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

com.cloudsnorkel.cdk.github.runners.LogOptions Maven / Gradle / Ivy

Go to download

CDK construct to create GitHub Actions self-hosted runners. A webhook listens to events and creates ephemeral runners on the fly.

There is a newer version: 0.14.6
Show newest version
package com.cloudsnorkel.cdk.github.runners;

/**
 * (experimental) Defines what execution history events are logged and where they are logged.
 */
@javax.annotation.Generated(value = "jsii-pacmak/1.103.1 (build bef2dea)", date = "2024-09-14T02:42:19.529Z")
@software.amazon.jsii.Jsii(module = com.cloudsnorkel.cdk.github.runners.$Module.class, fqn = "@cloudsnorkel/cdk-github-runners.LogOptions")
@software.amazon.jsii.Jsii.Proxy(LogOptions.Jsii$Proxy.class)
@software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental)
public interface LogOptions extends software.amazon.jsii.JsiiSerializable {

    /**
     * (experimental) Determines whether execution data is included in your log.
     * 

* Default: false */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental) default @org.jetbrains.annotations.Nullable java.lang.Boolean getIncludeExecutionData() { return null; } /** * (experimental) Defines which category of execution history events are logged. *

* Default: ERROR */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental) default @org.jetbrains.annotations.Nullable software.amazon.awscdk.services.stepfunctions.LogLevel getLevel() { return null; } /** * (experimental) The log group where the execution history events will be logged. */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental) default @org.jetbrains.annotations.Nullable java.lang.String getLogGroupName() { return null; } /** * (experimental) The number of days log events are kept in CloudWatch Logs. *

* When updating * this property, unsetting it doesn't remove the log retention policy. To * remove the retention policy, set the value to INFINITE. *

* Default: logs.RetentionDays.ONE_MONTH */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental) default @org.jetbrains.annotations.Nullable software.amazon.awscdk.services.logs.RetentionDays getLogRetention() { return null; } /** * @return a {@link Builder} of {@link LogOptions} */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental) static Builder builder() { return new Builder(); } /** * A builder for {@link LogOptions} */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental) public static final class Builder implements software.amazon.jsii.Builder { java.lang.Boolean includeExecutionData; software.amazon.awscdk.services.stepfunctions.LogLevel level; java.lang.String logGroupName; software.amazon.awscdk.services.logs.RetentionDays logRetention; /** * Sets the value of {@link LogOptions#getIncludeExecutionData} * @param includeExecutionData Determines whether execution data is included in your log. * @return {@code this} */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental) public Builder includeExecutionData(java.lang.Boolean includeExecutionData) { this.includeExecutionData = includeExecutionData; return this; } /** * Sets the value of {@link LogOptions#getLevel} * @param level Defines which category of execution history events are logged. * @return {@code this} */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental) public Builder level(software.amazon.awscdk.services.stepfunctions.LogLevel level) { this.level = level; return this; } /** * Sets the value of {@link LogOptions#getLogGroupName} * @param logGroupName The log group where the execution history events will be logged. * @return {@code this} */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental) public Builder logGroupName(java.lang.String logGroupName) { this.logGroupName = logGroupName; return this; } /** * Sets the value of {@link LogOptions#getLogRetention} * @param logRetention The number of days log events are kept in CloudWatch Logs. * When updating * this property, unsetting it doesn't remove the log retention policy. To * remove the retention policy, set the value to INFINITE. * @return {@code this} */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental) public Builder logRetention(software.amazon.awscdk.services.logs.RetentionDays logRetention) { this.logRetention = logRetention; return this; } /** * Builds the configured instance. * @return a new instance of {@link LogOptions} * @throws NullPointerException if any required attribute was not provided */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental) @Override public LogOptions build() { return new Jsii$Proxy(this); } } /** * An implementation for {@link LogOptions} */ @software.amazon.jsii.Stability(software.amazon.jsii.Stability.Level.Experimental) @software.amazon.jsii.Internal final class Jsii$Proxy extends software.amazon.jsii.JsiiObject implements LogOptions { private final java.lang.Boolean includeExecutionData; private final software.amazon.awscdk.services.stepfunctions.LogLevel level; private final java.lang.String logGroupName; private final software.amazon.awscdk.services.logs.RetentionDays logRetention; /** * Constructor that initializes the object based on values retrieved from the JsiiObject. * @param objRef Reference to the JSII managed object. */ protected Jsii$Proxy(final software.amazon.jsii.JsiiObjectRef objRef) { super(objRef); this.includeExecutionData = software.amazon.jsii.Kernel.get(this, "includeExecutionData", software.amazon.jsii.NativeType.forClass(java.lang.Boolean.class)); this.level = software.amazon.jsii.Kernel.get(this, "level", software.amazon.jsii.NativeType.forClass(software.amazon.awscdk.services.stepfunctions.LogLevel.class)); this.logGroupName = software.amazon.jsii.Kernel.get(this, "logGroupName", software.amazon.jsii.NativeType.forClass(java.lang.String.class)); this.logRetention = software.amazon.jsii.Kernel.get(this, "logRetention", software.amazon.jsii.NativeType.forClass(software.amazon.awscdk.services.logs.RetentionDays.class)); } /** * Constructor that initializes the object based on literal property values passed by the {@link Builder}. */ protected Jsii$Proxy(final Builder builder) { super(software.amazon.jsii.JsiiObject.InitializationMode.JSII); this.includeExecutionData = builder.includeExecutionData; this.level = builder.level; this.logGroupName = builder.logGroupName; this.logRetention = builder.logRetention; } @Override public final java.lang.Boolean getIncludeExecutionData() { return this.includeExecutionData; } @Override public final software.amazon.awscdk.services.stepfunctions.LogLevel getLevel() { return this.level; } @Override public final java.lang.String getLogGroupName() { return this.logGroupName; } @Override public final software.amazon.awscdk.services.logs.RetentionDays getLogRetention() { return this.logRetention; } @Override @software.amazon.jsii.Internal public com.fasterxml.jackson.databind.JsonNode $jsii$toJson() { final com.fasterxml.jackson.databind.ObjectMapper om = software.amazon.jsii.JsiiObjectMapper.INSTANCE; final com.fasterxml.jackson.databind.node.ObjectNode data = com.fasterxml.jackson.databind.node.JsonNodeFactory.instance.objectNode(); if (this.getIncludeExecutionData() != null) { data.set("includeExecutionData", om.valueToTree(this.getIncludeExecutionData())); } if (this.getLevel() != null) { data.set("level", om.valueToTree(this.getLevel())); } if (this.getLogGroupName() != null) { data.set("logGroupName", om.valueToTree(this.getLogGroupName())); } if (this.getLogRetention() != null) { data.set("logRetention", om.valueToTree(this.getLogRetention())); } final com.fasterxml.jackson.databind.node.ObjectNode struct = com.fasterxml.jackson.databind.node.JsonNodeFactory.instance.objectNode(); struct.set("fqn", om.valueToTree("@cloudsnorkel/cdk-github-runners.LogOptions")); struct.set("data", data); final com.fasterxml.jackson.databind.node.ObjectNode obj = com.fasterxml.jackson.databind.node.JsonNodeFactory.instance.objectNode(); obj.set("$jsii.struct", struct); return obj; } @Override public final boolean equals(final Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; LogOptions.Jsii$Proxy that = (LogOptions.Jsii$Proxy) o; if (this.includeExecutionData != null ? !this.includeExecutionData.equals(that.includeExecutionData) : that.includeExecutionData != null) return false; if (this.level != null ? !this.level.equals(that.level) : that.level != null) return false; if (this.logGroupName != null ? !this.logGroupName.equals(that.logGroupName) : that.logGroupName != null) return false; return this.logRetention != null ? this.logRetention.equals(that.logRetention) : that.logRetention == null; } @Override public final int hashCode() { int result = this.includeExecutionData != null ? this.includeExecutionData.hashCode() : 0; result = 31 * result + (this.level != null ? this.level.hashCode() : 0); result = 31 * result + (this.logGroupName != null ? this.logGroupName.hashCode() : 0); result = 31 * result + (this.logRetention != null ? this.logRetention.hashCode() : 0); return result; } } }





© 2015 - 2024 Weber Informatics LLC | Privacy Policy