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

software.amazon.awssdk.services.firehose.model.AmazonopensearchserviceDestinationUpdate Maven / Gradle / Ivy

/*
 * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
 * 
 * Licensed under the Apache License, Version 2.0 (the "License"). You may not use this file except in compliance with
 * the License. A copy of the License is located at
 * 
 * http://aws.amazon.com/apache2.0
 * 
 * or in the "license" file accompanying this file. This file is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
 * CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions
 * and limitations under the License.
 */

package software.amazon.awssdk.services.firehose.model;

import java.io.Serializable;
import java.util.Arrays;
import java.util.Collections;
import java.util.List;
import java.util.Objects;
import java.util.Optional;
import java.util.function.BiConsumer;
import java.util.function.Consumer;
import java.util.function.Function;
import software.amazon.awssdk.annotations.Generated;
import software.amazon.awssdk.core.SdkField;
import software.amazon.awssdk.core.SdkPojo;
import software.amazon.awssdk.core.protocol.MarshallLocation;
import software.amazon.awssdk.core.protocol.MarshallingType;
import software.amazon.awssdk.core.traits.LocationTrait;
import software.amazon.awssdk.utils.ToString;
import software.amazon.awssdk.utils.builder.CopyableBuilder;
import software.amazon.awssdk.utils.builder.ToCopyableBuilder;

/**
 * 

* Describes an update for a destination in Amazon OpenSearch Service. *

*/ @Generated("software.amazon.awssdk:codegen") public final class AmazonopensearchserviceDestinationUpdate implements SdkPojo, Serializable, ToCopyableBuilder { private static final SdkField ROLE_ARN_FIELD = SdkField. builder(MarshallingType.STRING) .memberName("RoleARN").getter(getter(AmazonopensearchserviceDestinationUpdate::roleARN)) .setter(setter(Builder::roleARN)) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("RoleARN").build()).build(); private static final SdkField DOMAIN_ARN_FIELD = SdkField. builder(MarshallingType.STRING) .memberName("DomainARN").getter(getter(AmazonopensearchserviceDestinationUpdate::domainARN)) .setter(setter(Builder::domainARN)) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("DomainARN").build()).build(); private static final SdkField CLUSTER_ENDPOINT_FIELD = SdkField. builder(MarshallingType.STRING) .memberName("ClusterEndpoint").getter(getter(AmazonopensearchserviceDestinationUpdate::clusterEndpoint)) .setter(setter(Builder::clusterEndpoint)) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("ClusterEndpoint").build()).build(); private static final SdkField INDEX_NAME_FIELD = SdkField. builder(MarshallingType.STRING) .memberName("IndexName").getter(getter(AmazonopensearchserviceDestinationUpdate::indexName)) .setter(setter(Builder::indexName)) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("IndexName").build()).build(); private static final SdkField TYPE_NAME_FIELD = SdkField. builder(MarshallingType.STRING) .memberName("TypeName").getter(getter(AmazonopensearchserviceDestinationUpdate::typeName)) .setter(setter(Builder::typeName)) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("TypeName").build()).build(); private static final SdkField INDEX_ROTATION_PERIOD_FIELD = SdkField. builder(MarshallingType.STRING) .memberName("IndexRotationPeriod") .getter(getter(AmazonopensearchserviceDestinationUpdate::indexRotationPeriodAsString)) .setter(setter(Builder::indexRotationPeriod)) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("IndexRotationPeriod").build()) .build(); private static final SdkField BUFFERING_HINTS_FIELD = SdkField . builder(MarshallingType.SDK_POJO).memberName("BufferingHints") .getter(getter(AmazonopensearchserviceDestinationUpdate::bufferingHints)).setter(setter(Builder::bufferingHints)) .constructor(AmazonopensearchserviceBufferingHints::builder) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("BufferingHints").build()).build(); private static final SdkField RETRY_OPTIONS_FIELD = SdkField . builder(MarshallingType.SDK_POJO).memberName("RetryOptions") .getter(getter(AmazonopensearchserviceDestinationUpdate::retryOptions)).setter(setter(Builder::retryOptions)) .constructor(AmazonopensearchserviceRetryOptions::builder) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("RetryOptions").build()).build(); private static final SdkField S3_UPDATE_FIELD = SdkField . builder(MarshallingType.SDK_POJO).memberName("S3Update") .getter(getter(AmazonopensearchserviceDestinationUpdate::s3Update)).setter(setter(Builder::s3Update)) .constructor(S3DestinationUpdate::builder) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("S3Update").build()).build(); private static final SdkField PROCESSING_CONFIGURATION_FIELD = SdkField . builder(MarshallingType.SDK_POJO).memberName("ProcessingConfiguration") .getter(getter(AmazonopensearchserviceDestinationUpdate::processingConfiguration)) .setter(setter(Builder::processingConfiguration)).constructor(ProcessingConfiguration::builder) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("ProcessingConfiguration").build()) .build(); private static final SdkField CLOUD_WATCH_LOGGING_OPTIONS_FIELD = SdkField . builder(MarshallingType.SDK_POJO).memberName("CloudWatchLoggingOptions") .getter(getter(AmazonopensearchserviceDestinationUpdate::cloudWatchLoggingOptions)) .setter(setter(Builder::cloudWatchLoggingOptions)).constructor(CloudWatchLoggingOptions::builder) .traits(LocationTrait.builder().location(MarshallLocation.PAYLOAD).locationName("CloudWatchLoggingOptions").build()) .build(); private static final List> SDK_FIELDS = Collections.unmodifiableList(Arrays.asList(ROLE_ARN_FIELD, DOMAIN_ARN_FIELD, CLUSTER_ENDPOINT_FIELD, INDEX_NAME_FIELD, TYPE_NAME_FIELD, INDEX_ROTATION_PERIOD_FIELD, BUFFERING_HINTS_FIELD, RETRY_OPTIONS_FIELD, S3_UPDATE_FIELD, PROCESSING_CONFIGURATION_FIELD, CLOUD_WATCH_LOGGING_OPTIONS_FIELD)); private static final long serialVersionUID = 1L; private final String roleARN; private final String domainARN; private final String clusterEndpoint; private final String indexName; private final String typeName; private final String indexRotationPeriod; private final AmazonopensearchserviceBufferingHints bufferingHints; private final AmazonopensearchserviceRetryOptions retryOptions; private final S3DestinationUpdate s3Update; private final ProcessingConfiguration processingConfiguration; private final CloudWatchLoggingOptions cloudWatchLoggingOptions; private AmazonopensearchserviceDestinationUpdate(BuilderImpl builder) { this.roleARN = builder.roleARN; this.domainARN = builder.domainARN; this.clusterEndpoint = builder.clusterEndpoint; this.indexName = builder.indexName; this.typeName = builder.typeName; this.indexRotationPeriod = builder.indexRotationPeriod; this.bufferingHints = builder.bufferingHints; this.retryOptions = builder.retryOptions; this.s3Update = builder.s3Update; this.processingConfiguration = builder.processingConfiguration; this.cloudWatchLoggingOptions = builder.cloudWatchLoggingOptions; } /** *

* The Amazon Resource Name (ARN) of the IAM role to be assumed by Kinesis Data Firehose for calling the Amazon * OpenSearch Service Configuration API and for indexing documents. *

* * @return The Amazon Resource Name (ARN) of the IAM role to be assumed by Kinesis Data Firehose for calling the * Amazon OpenSearch Service Configuration API and for indexing documents. */ public final String roleARN() { return roleARN; } /** *

* The ARN of the Amazon OpenSearch Service domain. The IAM role must have permissions for DescribeDomain, * DescribeDomains, and DescribeDomainConfig after assuming the IAM role specified in RoleARN. *

* * @return The ARN of the Amazon OpenSearch Service domain. The IAM role must have permissions for DescribeDomain, * DescribeDomains, and DescribeDomainConfig after assuming the IAM role specified in RoleARN. */ public final String domainARN() { return domainARN; } /** *

* The endpoint to use when communicating with the cluster. Specify either this ClusterEndpoint or the DomainARN * field. *

* * @return The endpoint to use when communicating with the cluster. Specify either this ClusterEndpoint or the * DomainARN field. */ public final String clusterEndpoint() { return clusterEndpoint; } /** *

* The Amazon OpenSearch Service index name. *

* * @return The Amazon OpenSearch Service index name. */ public final String indexName() { return indexName; } /** *

* The Amazon OpenSearch Service type name. For Elasticsearch 6.x, there can be only one type per index. If you try * to specify a new type for an existing index that already has another type, Kinesis Data Firehose returns an error * during runtime. *

*

* If you upgrade Elasticsearch from 6.x to 7.x and don’t update your delivery stream, Kinesis Data Firehose still * delivers data to Elasticsearch with the old index name and type name. If you want to update your delivery stream * with a new index name, provide an empty string for TypeName. *

* * @return The Amazon OpenSearch Service type name. For Elasticsearch 6.x, there can be only one type per index. If * you try to specify a new type for an existing index that already has another type, Kinesis Data Firehose * returns an error during runtime.

*

* If you upgrade Elasticsearch from 6.x to 7.x and don’t update your delivery stream, Kinesis Data Firehose * still delivers data to Elasticsearch with the old index name and type name. If you want to update your * delivery stream with a new index name, provide an empty string for TypeName. */ public final String typeName() { return typeName; } /** *

* The Amazon OpenSearch Service index rotation period. Index rotation appends a timestamp to IndexName to * facilitate the expiration of old data. *

*

* If the service returns an enum value that is not available in the current SDK version, * {@link #indexRotationPeriod} will return * {@link AmazonopensearchserviceIndexRotationPeriod#UNKNOWN_TO_SDK_VERSION}. The raw value returned by the service * is available from {@link #indexRotationPeriodAsString}. *

* * @return The Amazon OpenSearch Service index rotation period. Index rotation appends a timestamp to IndexName to * facilitate the expiration of old data. * @see AmazonopensearchserviceIndexRotationPeriod */ public final AmazonopensearchserviceIndexRotationPeriod indexRotationPeriod() { return AmazonopensearchserviceIndexRotationPeriod.fromValue(indexRotationPeriod); } /** *

* The Amazon OpenSearch Service index rotation period. Index rotation appends a timestamp to IndexName to * facilitate the expiration of old data. *

*

* If the service returns an enum value that is not available in the current SDK version, * {@link #indexRotationPeriod} will return * {@link AmazonopensearchserviceIndexRotationPeriod#UNKNOWN_TO_SDK_VERSION}. The raw value returned by the service * is available from {@link #indexRotationPeriodAsString}. *

* * @return The Amazon OpenSearch Service index rotation period. Index rotation appends a timestamp to IndexName to * facilitate the expiration of old data. * @see AmazonopensearchserviceIndexRotationPeriod */ public final String indexRotationPeriodAsString() { return indexRotationPeriod; } /** *

* The buffering options. If no value is specified, AmazonopensearchBufferingHints object default values are used. *

* * @return The buffering options. If no value is specified, AmazonopensearchBufferingHints object default values are * used. */ public final AmazonopensearchserviceBufferingHints bufferingHints() { return bufferingHints; } /** *

* The retry behavior in case Kinesis Data Firehose is unable to deliver documents to Amazon OpenSearch Service. The * default value is 300 (5 minutes). *

* * @return The retry behavior in case Kinesis Data Firehose is unable to deliver documents to Amazon OpenSearch * Service. The default value is 300 (5 minutes). */ public final AmazonopensearchserviceRetryOptions retryOptions() { return retryOptions; } /** * Returns the value of the S3Update property for this object. * * @return The value of the S3Update property for this object. */ public final S3DestinationUpdate s3Update() { return s3Update; } /** * Returns the value of the ProcessingConfiguration property for this object. * * @return The value of the ProcessingConfiguration property for this object. */ public final ProcessingConfiguration processingConfiguration() { return processingConfiguration; } /** * Returns the value of the CloudWatchLoggingOptions property for this object. * * @return The value of the CloudWatchLoggingOptions property for this object. */ public final CloudWatchLoggingOptions cloudWatchLoggingOptions() { return cloudWatchLoggingOptions; } @Override public Builder toBuilder() { return new BuilderImpl(this); } public static Builder builder() { return new BuilderImpl(); } public static Class serializableBuilderClass() { return BuilderImpl.class; } @Override public final int hashCode() { int hashCode = 1; hashCode = 31 * hashCode + Objects.hashCode(roleARN()); hashCode = 31 * hashCode + Objects.hashCode(domainARN()); hashCode = 31 * hashCode + Objects.hashCode(clusterEndpoint()); hashCode = 31 * hashCode + Objects.hashCode(indexName()); hashCode = 31 * hashCode + Objects.hashCode(typeName()); hashCode = 31 * hashCode + Objects.hashCode(indexRotationPeriodAsString()); hashCode = 31 * hashCode + Objects.hashCode(bufferingHints()); hashCode = 31 * hashCode + Objects.hashCode(retryOptions()); hashCode = 31 * hashCode + Objects.hashCode(s3Update()); hashCode = 31 * hashCode + Objects.hashCode(processingConfiguration()); hashCode = 31 * hashCode + Objects.hashCode(cloudWatchLoggingOptions()); return hashCode; } @Override public final boolean equals(Object obj) { return equalsBySdkFields(obj); } @Override public final boolean equalsBySdkFields(Object obj) { if (this == obj) { return true; } if (obj == null) { return false; } if (!(obj instanceof AmazonopensearchserviceDestinationUpdate)) { return false; } AmazonopensearchserviceDestinationUpdate other = (AmazonopensearchserviceDestinationUpdate) obj; return Objects.equals(roleARN(), other.roleARN()) && Objects.equals(domainARN(), other.domainARN()) && Objects.equals(clusterEndpoint(), other.clusterEndpoint()) && Objects.equals(indexName(), other.indexName()) && Objects.equals(typeName(), other.typeName()) && Objects.equals(indexRotationPeriodAsString(), other.indexRotationPeriodAsString()) && Objects.equals(bufferingHints(), other.bufferingHints()) && Objects.equals(retryOptions(), other.retryOptions()) && Objects.equals(s3Update(), other.s3Update()) && Objects.equals(processingConfiguration(), other.processingConfiguration()) && Objects.equals(cloudWatchLoggingOptions(), other.cloudWatchLoggingOptions()); } /** * Returns a string representation of this object. This is useful for testing and debugging. Sensitive data will be * redacted from this string using a placeholder value. */ @Override public final String toString() { return ToString.builder("AmazonopensearchserviceDestinationUpdate").add("RoleARN", roleARN()) .add("DomainARN", domainARN()).add("ClusterEndpoint", clusterEndpoint()).add("IndexName", indexName()) .add("TypeName", typeName()).add("IndexRotationPeriod", indexRotationPeriodAsString()) .add("BufferingHints", bufferingHints()).add("RetryOptions", retryOptions()).add("S3Update", s3Update()) .add("ProcessingConfiguration", processingConfiguration()) .add("CloudWatchLoggingOptions", cloudWatchLoggingOptions()).build(); } public final Optional getValueForField(String fieldName, Class clazz) { switch (fieldName) { case "RoleARN": return Optional.ofNullable(clazz.cast(roleARN())); case "DomainARN": return Optional.ofNullable(clazz.cast(domainARN())); case "ClusterEndpoint": return Optional.ofNullable(clazz.cast(clusterEndpoint())); case "IndexName": return Optional.ofNullable(clazz.cast(indexName())); case "TypeName": return Optional.ofNullable(clazz.cast(typeName())); case "IndexRotationPeriod": return Optional.ofNullable(clazz.cast(indexRotationPeriodAsString())); case "BufferingHints": return Optional.ofNullable(clazz.cast(bufferingHints())); case "RetryOptions": return Optional.ofNullable(clazz.cast(retryOptions())); case "S3Update": return Optional.ofNullable(clazz.cast(s3Update())); case "ProcessingConfiguration": return Optional.ofNullable(clazz.cast(processingConfiguration())); case "CloudWatchLoggingOptions": return Optional.ofNullable(clazz.cast(cloudWatchLoggingOptions())); default: return Optional.empty(); } } @Override public final List> sdkFields() { return SDK_FIELDS; } private static Function getter(Function g) { return obj -> g.apply((AmazonopensearchserviceDestinationUpdate) obj); } private static BiConsumer setter(BiConsumer s) { return (obj, val) -> s.accept((Builder) obj, val); } public interface Builder extends SdkPojo, CopyableBuilder { /** *

* The Amazon Resource Name (ARN) of the IAM role to be assumed by Kinesis Data Firehose for calling the Amazon * OpenSearch Service Configuration API and for indexing documents. *

* * @param roleARN * The Amazon Resource Name (ARN) of the IAM role to be assumed by Kinesis Data Firehose for calling the * Amazon OpenSearch Service Configuration API and for indexing documents. * @return Returns a reference to this object so that method calls can be chained together. */ Builder roleARN(String roleARN); /** *

* The ARN of the Amazon OpenSearch Service domain. The IAM role must have permissions for DescribeDomain, * DescribeDomains, and DescribeDomainConfig after assuming the IAM role specified in RoleARN. *

* * @param domainARN * The ARN of the Amazon OpenSearch Service domain. The IAM role must have permissions for * DescribeDomain, DescribeDomains, and DescribeDomainConfig after assuming the IAM role specified in * RoleARN. * @return Returns a reference to this object so that method calls can be chained together. */ Builder domainARN(String domainARN); /** *

* The endpoint to use when communicating with the cluster. Specify either this ClusterEndpoint or the DomainARN * field. *

* * @param clusterEndpoint * The endpoint to use when communicating with the cluster. Specify either this ClusterEndpoint or the * DomainARN field. * @return Returns a reference to this object so that method calls can be chained together. */ Builder clusterEndpoint(String clusterEndpoint); /** *

* The Amazon OpenSearch Service index name. *

* * @param indexName * The Amazon OpenSearch Service index name. * @return Returns a reference to this object so that method calls can be chained together. */ Builder indexName(String indexName); /** *

* The Amazon OpenSearch Service type name. For Elasticsearch 6.x, there can be only one type per index. If you * try to specify a new type for an existing index that already has another type, Kinesis Data Firehose returns * an error during runtime. *

*

* If you upgrade Elasticsearch from 6.x to 7.x and don’t update your delivery stream, Kinesis Data Firehose * still delivers data to Elasticsearch with the old index name and type name. If you want to update your * delivery stream with a new index name, provide an empty string for TypeName. *

* * @param typeName * The Amazon OpenSearch Service type name. For Elasticsearch 6.x, there can be only one type per index. * If you try to specify a new type for an existing index that already has another type, Kinesis Data * Firehose returns an error during runtime.

*

* If you upgrade Elasticsearch from 6.x to 7.x and don’t update your delivery stream, Kinesis Data * Firehose still delivers data to Elasticsearch with the old index name and type name. If you want to * update your delivery stream with a new index name, provide an empty string for TypeName. * @return Returns a reference to this object so that method calls can be chained together. */ Builder typeName(String typeName); /** *

* The Amazon OpenSearch Service index rotation period. Index rotation appends a timestamp to IndexName to * facilitate the expiration of old data. *

* * @param indexRotationPeriod * The Amazon OpenSearch Service index rotation period. Index rotation appends a timestamp to IndexName * to facilitate the expiration of old data. * @see AmazonopensearchserviceIndexRotationPeriod * @return Returns a reference to this object so that method calls can be chained together. * @see AmazonopensearchserviceIndexRotationPeriod */ Builder indexRotationPeriod(String indexRotationPeriod); /** *

* The Amazon OpenSearch Service index rotation period. Index rotation appends a timestamp to IndexName to * facilitate the expiration of old data. *

* * @param indexRotationPeriod * The Amazon OpenSearch Service index rotation period. Index rotation appends a timestamp to IndexName * to facilitate the expiration of old data. * @see AmazonopensearchserviceIndexRotationPeriod * @return Returns a reference to this object so that method calls can be chained together. * @see AmazonopensearchserviceIndexRotationPeriod */ Builder indexRotationPeriod(AmazonopensearchserviceIndexRotationPeriod indexRotationPeriod); /** *

* The buffering options. If no value is specified, AmazonopensearchBufferingHints object default values are * used. *

* * @param bufferingHints * The buffering options. If no value is specified, AmazonopensearchBufferingHints object default values * are used. * @return Returns a reference to this object so that method calls can be chained together. */ Builder bufferingHints(AmazonopensearchserviceBufferingHints bufferingHints); /** *

* The buffering options. If no value is specified, AmazonopensearchBufferingHints object default values are * used. *

* This is a convenience method that creates an instance of the * {@link AmazonopensearchserviceBufferingHints.Builder} avoiding the need to create one manually via * {@link AmazonopensearchserviceBufferingHints#builder()}. * *

* When the {@link Consumer} completes, {@link AmazonopensearchserviceBufferingHints.Builder#build()} is called * immediately and its result is passed to {@link #bufferingHints(AmazonopensearchserviceBufferingHints)}. * * @param bufferingHints * a consumer that will call methods on {@link AmazonopensearchserviceBufferingHints.Builder} * @return Returns a reference to this object so that method calls can be chained together. * @see #bufferingHints(AmazonopensearchserviceBufferingHints) */ default Builder bufferingHints(Consumer bufferingHints) { return bufferingHints(AmazonopensearchserviceBufferingHints.builder().applyMutation(bufferingHints).build()); } /** *

* The retry behavior in case Kinesis Data Firehose is unable to deliver documents to Amazon OpenSearch Service. * The default value is 300 (5 minutes). *

* * @param retryOptions * The retry behavior in case Kinesis Data Firehose is unable to deliver documents to Amazon OpenSearch * Service. The default value is 300 (5 minutes). * @return Returns a reference to this object so that method calls can be chained together. */ Builder retryOptions(AmazonopensearchserviceRetryOptions retryOptions); /** *

* The retry behavior in case Kinesis Data Firehose is unable to deliver documents to Amazon OpenSearch Service. * The default value is 300 (5 minutes). *

* This is a convenience method that creates an instance of the * {@link AmazonopensearchserviceRetryOptions.Builder} avoiding the need to create one manually via * {@link AmazonopensearchserviceRetryOptions#builder()}. * *

* When the {@link Consumer} completes, {@link AmazonopensearchserviceRetryOptions.Builder#build()} is called * immediately and its result is passed to {@link #retryOptions(AmazonopensearchserviceRetryOptions)}. * * @param retryOptions * a consumer that will call methods on {@link AmazonopensearchserviceRetryOptions.Builder} * @return Returns a reference to this object so that method calls can be chained together. * @see #retryOptions(AmazonopensearchserviceRetryOptions) */ default Builder retryOptions(Consumer retryOptions) { return retryOptions(AmazonopensearchserviceRetryOptions.builder().applyMutation(retryOptions).build()); } /** * Sets the value of the S3Update property for this object. * * @param s3Update * The new value for the S3Update property for this object. * @return Returns a reference to this object so that method calls can be chained together. */ Builder s3Update(S3DestinationUpdate s3Update); /** * Sets the value of the S3Update property for this object. * * This is a convenience method that creates an instance of the {@link S3DestinationUpdate.Builder} avoiding the * need to create one manually via {@link S3DestinationUpdate#builder()}. * *

* When the {@link Consumer} completes, {@link S3DestinationUpdate.Builder#build()} is called immediately and * its result is passed to {@link #s3Update(S3DestinationUpdate)}. * * @param s3Update * a consumer that will call methods on {@link S3DestinationUpdate.Builder} * @return Returns a reference to this object so that method calls can be chained together. * @see #s3Update(S3DestinationUpdate) */ default Builder s3Update(Consumer s3Update) { return s3Update(S3DestinationUpdate.builder().applyMutation(s3Update).build()); } /** * Sets the value of the ProcessingConfiguration property for this object. * * @param processingConfiguration * The new value for the ProcessingConfiguration property for this object. * @return Returns a reference to this object so that method calls can be chained together. */ Builder processingConfiguration(ProcessingConfiguration processingConfiguration); /** * Sets the value of the ProcessingConfiguration property for this object. * * This is a convenience method that creates an instance of the {@link ProcessingConfiguration.Builder} avoiding * the need to create one manually via {@link ProcessingConfiguration#builder()}. * *

* When the {@link Consumer} completes, {@link ProcessingConfiguration.Builder#build()} is called immediately * and its result is passed to {@link #processingConfiguration(ProcessingConfiguration)}. * * @param processingConfiguration * a consumer that will call methods on {@link ProcessingConfiguration.Builder} * @return Returns a reference to this object so that method calls can be chained together. * @see #processingConfiguration(ProcessingConfiguration) */ default Builder processingConfiguration(Consumer processingConfiguration) { return processingConfiguration(ProcessingConfiguration.builder().applyMutation(processingConfiguration).build()); } /** * Sets the value of the CloudWatchLoggingOptions property for this object. * * @param cloudWatchLoggingOptions * The new value for the CloudWatchLoggingOptions property for this object. * @return Returns a reference to this object so that method calls can be chained together. */ Builder cloudWatchLoggingOptions(CloudWatchLoggingOptions cloudWatchLoggingOptions); /** * Sets the value of the CloudWatchLoggingOptions property for this object. * * This is a convenience method that creates an instance of the {@link CloudWatchLoggingOptions.Builder} * avoiding the need to create one manually via {@link CloudWatchLoggingOptions#builder()}. * *

* When the {@link Consumer} completes, {@link CloudWatchLoggingOptions.Builder#build()} is called immediately * and its result is passed to {@link #cloudWatchLoggingOptions(CloudWatchLoggingOptions)}. * * @param cloudWatchLoggingOptions * a consumer that will call methods on {@link CloudWatchLoggingOptions.Builder} * @return Returns a reference to this object so that method calls can be chained together. * @see #cloudWatchLoggingOptions(CloudWatchLoggingOptions) */ default Builder cloudWatchLoggingOptions(Consumer cloudWatchLoggingOptions) { return cloudWatchLoggingOptions(CloudWatchLoggingOptions.builder().applyMutation(cloudWatchLoggingOptions).build()); } } static final class BuilderImpl implements Builder { private String roleARN; private String domainARN; private String clusterEndpoint; private String indexName; private String typeName; private String indexRotationPeriod; private AmazonopensearchserviceBufferingHints bufferingHints; private AmazonopensearchserviceRetryOptions retryOptions; private S3DestinationUpdate s3Update; private ProcessingConfiguration processingConfiguration; private CloudWatchLoggingOptions cloudWatchLoggingOptions; private BuilderImpl() { } private BuilderImpl(AmazonopensearchserviceDestinationUpdate model) { roleARN(model.roleARN); domainARN(model.domainARN); clusterEndpoint(model.clusterEndpoint); indexName(model.indexName); typeName(model.typeName); indexRotationPeriod(model.indexRotationPeriod); bufferingHints(model.bufferingHints); retryOptions(model.retryOptions); s3Update(model.s3Update); processingConfiguration(model.processingConfiguration); cloudWatchLoggingOptions(model.cloudWatchLoggingOptions); } public final String getRoleARN() { return roleARN; } public final void setRoleARN(String roleARN) { this.roleARN = roleARN; } @Override public final Builder roleARN(String roleARN) { this.roleARN = roleARN; return this; } public final String getDomainARN() { return domainARN; } public final void setDomainARN(String domainARN) { this.domainARN = domainARN; } @Override public final Builder domainARN(String domainARN) { this.domainARN = domainARN; return this; } public final String getClusterEndpoint() { return clusterEndpoint; } public final void setClusterEndpoint(String clusterEndpoint) { this.clusterEndpoint = clusterEndpoint; } @Override public final Builder clusterEndpoint(String clusterEndpoint) { this.clusterEndpoint = clusterEndpoint; return this; } public final String getIndexName() { return indexName; } public final void setIndexName(String indexName) { this.indexName = indexName; } @Override public final Builder indexName(String indexName) { this.indexName = indexName; return this; } public final String getTypeName() { return typeName; } public final void setTypeName(String typeName) { this.typeName = typeName; } @Override public final Builder typeName(String typeName) { this.typeName = typeName; return this; } public final String getIndexRotationPeriod() { return indexRotationPeriod; } public final void setIndexRotationPeriod(String indexRotationPeriod) { this.indexRotationPeriod = indexRotationPeriod; } @Override public final Builder indexRotationPeriod(String indexRotationPeriod) { this.indexRotationPeriod = indexRotationPeriod; return this; } @Override public final Builder indexRotationPeriod(AmazonopensearchserviceIndexRotationPeriod indexRotationPeriod) { this.indexRotationPeriod(indexRotationPeriod == null ? null : indexRotationPeriod.toString()); return this; } public final AmazonopensearchserviceBufferingHints.Builder getBufferingHints() { return bufferingHints != null ? bufferingHints.toBuilder() : null; } public final void setBufferingHints(AmazonopensearchserviceBufferingHints.BuilderImpl bufferingHints) { this.bufferingHints = bufferingHints != null ? bufferingHints.build() : null; } @Override public final Builder bufferingHints(AmazonopensearchserviceBufferingHints bufferingHints) { this.bufferingHints = bufferingHints; return this; } public final AmazonopensearchserviceRetryOptions.Builder getRetryOptions() { return retryOptions != null ? retryOptions.toBuilder() : null; } public final void setRetryOptions(AmazonopensearchserviceRetryOptions.BuilderImpl retryOptions) { this.retryOptions = retryOptions != null ? retryOptions.build() : null; } @Override public final Builder retryOptions(AmazonopensearchserviceRetryOptions retryOptions) { this.retryOptions = retryOptions; return this; } public final S3DestinationUpdate.Builder getS3Update() { return s3Update != null ? s3Update.toBuilder() : null; } public final void setS3Update(S3DestinationUpdate.BuilderImpl s3Update) { this.s3Update = s3Update != null ? s3Update.build() : null; } @Override public final Builder s3Update(S3DestinationUpdate s3Update) { this.s3Update = s3Update; return this; } public final ProcessingConfiguration.Builder getProcessingConfiguration() { return processingConfiguration != null ? processingConfiguration.toBuilder() : null; } public final void setProcessingConfiguration(ProcessingConfiguration.BuilderImpl processingConfiguration) { this.processingConfiguration = processingConfiguration != null ? processingConfiguration.build() : null; } @Override public final Builder processingConfiguration(ProcessingConfiguration processingConfiguration) { this.processingConfiguration = processingConfiguration; return this; } public final CloudWatchLoggingOptions.Builder getCloudWatchLoggingOptions() { return cloudWatchLoggingOptions != null ? cloudWatchLoggingOptions.toBuilder() : null; } public final void setCloudWatchLoggingOptions(CloudWatchLoggingOptions.BuilderImpl cloudWatchLoggingOptions) { this.cloudWatchLoggingOptions = cloudWatchLoggingOptions != null ? cloudWatchLoggingOptions.build() : null; } @Override public final Builder cloudWatchLoggingOptions(CloudWatchLoggingOptions cloudWatchLoggingOptions) { this.cloudWatchLoggingOptions = cloudWatchLoggingOptions; return this; } @Override public AmazonopensearchserviceDestinationUpdate build() { return new AmazonopensearchserviceDestinationUpdate(this); } @Override public List> sdkFields() { return SDK_FIELDS; } } }





© 2015 - 2025 Weber Informatics LLC | Privacy Policy