com.amazonaws.services.kinesisfirehose.model.ElasticsearchDestinationConfiguration Maven / Gradle / Ivy
Show all versions of aws-java-sdk-kinesis Show documentation
/*
* Copyright 2017-2022 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 com.amazonaws.services.kinesisfirehose.model;
import java.io.Serializable;
import javax.annotation.Generated;
import com.amazonaws.protocol.StructuredPojo;
import com.amazonaws.protocol.ProtocolMarshaller;
/**
*
* Describes the configuration of a destination in Amazon ES.
*
*
* @see AWS API Documentation
*/
@Generated("com.amazonaws:aws-java-sdk-code-generator")
public class ElasticsearchDestinationConfiguration implements Serializable, Cloneable, StructuredPojo {
/**
*
* The Amazon Resource Name (ARN) of the IAM role to be assumed by Kinesis Data Firehose for calling the Amazon ES
* Configuration API and for indexing documents. For more information, see Grant Kinesis Data
* Firehose Access to an Amazon S3 Destination and Amazon Resource Names (ARNs)
* and AWS Service Namespaces.
*
*/
private String roleARN;
/**
*
* The ARN of the Amazon ES domain. The IAM role must have permissions for DescribeElasticsearchDomain
,
* DescribeElasticsearchDomains
, and DescribeElasticsearchDomainConfig
after assuming the
* role specified in RoleARN. For more information, see Amazon Resource Names (ARNs)
* and AWS Service Namespaces.
*
*
* Specify either ClusterEndpoint
or DomainARN
.
*
*/
private String domainARN;
/**
*
* The endpoint to use when communicating with the cluster. Specify either this ClusterEndpoint
or the
* DomainARN
field.
*
*/
private String clusterEndpoint;
/**
*
* The Elasticsearch index name.
*
*/
private String indexName;
/**
*
* The Elasticsearch 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 run
* time.
*
*
* For Elasticsearch 7.x, don't specify a TypeName
.
*
*/
private String typeName;
/**
*
* The Elasticsearch index rotation period. Index rotation appends a timestamp to the IndexName
to
* facilitate the expiration of old data. For more information, see Index Rotation for
* the Amazon ES Destination. The default value is OneDay
.
*
*/
private String indexRotationPeriod;
/**
*
* The buffering options. If no value is specified, the default values for ElasticsearchBufferingHints
* are used.
*
*/
private ElasticsearchBufferingHints bufferingHints;
/**
*
* The retry behavior in case Kinesis Data Firehose is unable to deliver documents to Amazon ES. The default value
* is 300 (5 minutes).
*
*/
private ElasticsearchRetryOptions retryOptions;
/**
*
* Defines how documents should be delivered to Amazon S3. When it is set to FailedDocumentsOnly
,
* Kinesis Data Firehose writes any documents that could not be indexed to the configured Amazon S3 destination,
* with elasticsearch-failed/
appended to the key prefix. When set to AllDocuments
,
* Kinesis Data Firehose delivers all incoming records to Amazon S3, and also writes failed documents with
* elasticsearch-failed/
appended to the prefix. For more information, see Amazon S3 Backup for the
* Amazon ES Destination. Default value is FailedDocumentsOnly
.
*
*
* You can't change this backup mode after you create the delivery stream.
*
*/
private String s3BackupMode;
/**
*
* The configuration for the backup Amazon S3 location.
*
*/
private S3DestinationConfiguration s3Configuration;
/**
*
* The data processing configuration.
*
*/
private ProcessingConfiguration processingConfiguration;
/**
*
* The Amazon CloudWatch logging options for your delivery stream.
*
*/
private CloudWatchLoggingOptions cloudWatchLoggingOptions;
/**
*
* The details of the VPC of the Amazon ES destination.
*
*/
private VpcConfiguration vpcConfiguration;
/**
*
* The Amazon Resource Name (ARN) of the IAM role to be assumed by Kinesis Data Firehose for calling the Amazon ES
* Configuration API and for indexing documents. For more information, see Grant Kinesis Data
* Firehose Access to an Amazon S3 Destination and Amazon Resource Names (ARNs)
* and AWS Service Namespaces.
*
*
* @param roleARN
* The Amazon Resource Name (ARN) of the IAM role to be assumed by Kinesis Data Firehose for calling the
* Amazon ES Configuration API and for indexing documents. For more information, see Grant Kinesis
* Data Firehose Access to an Amazon S3 Destination and Amazon Resource Names
* (ARNs) and AWS Service Namespaces.
*/
public void setRoleARN(String roleARN) {
this.roleARN = roleARN;
}
/**
*
* The Amazon Resource Name (ARN) of the IAM role to be assumed by Kinesis Data Firehose for calling the Amazon ES
* Configuration API and for indexing documents. For more information, see Grant Kinesis Data
* Firehose Access to an Amazon S3 Destination and Amazon Resource Names (ARNs)
* and AWS Service Namespaces.
*
*
* @return The Amazon Resource Name (ARN) of the IAM role to be assumed by Kinesis Data Firehose for calling the
* Amazon ES Configuration API and for indexing documents. For more information, see Grant Kinesis
* Data Firehose Access to an Amazon S3 Destination and Amazon Resource Names
* (ARNs) and AWS Service Namespaces.
*/
public String getRoleARN() {
return this.roleARN;
}
/**
*
* The Amazon Resource Name (ARN) of the IAM role to be assumed by Kinesis Data Firehose for calling the Amazon ES
* Configuration API and for indexing documents. For more information, see Grant Kinesis Data
* Firehose Access to an Amazon S3 Destination and Amazon Resource Names (ARNs)
* and AWS Service Namespaces.
*
*
* @param roleARN
* The Amazon Resource Name (ARN) of the IAM role to be assumed by Kinesis Data Firehose for calling the
* Amazon ES Configuration API and for indexing documents. For more information, see Grant Kinesis
* Data Firehose Access to an Amazon S3 Destination and Amazon Resource Names
* (ARNs) and AWS Service Namespaces.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public ElasticsearchDestinationConfiguration withRoleARN(String roleARN) {
setRoleARN(roleARN);
return this;
}
/**
*
* The ARN of the Amazon ES domain. The IAM role must have permissions for DescribeElasticsearchDomain
,
* DescribeElasticsearchDomains
, and DescribeElasticsearchDomainConfig
after assuming the
* role specified in RoleARN. For more information, see Amazon Resource Names (ARNs)
* and AWS Service Namespaces.
*
*
* Specify either ClusterEndpoint
or DomainARN
.
*
*
* @param domainARN
* The ARN of the Amazon ES domain. The IAM role must have permissions for
* DescribeElasticsearchDomain
, DescribeElasticsearchDomains
, and
* DescribeElasticsearchDomainConfig
after assuming the role specified in RoleARN. For
* more information, see Amazon Resource Names
* (ARNs) and AWS Service Namespaces.
*
* Specify either ClusterEndpoint
or DomainARN
.
*/
public void setDomainARN(String domainARN) {
this.domainARN = domainARN;
}
/**
*
* The ARN of the Amazon ES domain. The IAM role must have permissions for DescribeElasticsearchDomain
,
* DescribeElasticsearchDomains
, and DescribeElasticsearchDomainConfig
after assuming the
* role specified in RoleARN. For more information, see Amazon Resource Names (ARNs)
* and AWS Service Namespaces.
*
*
* Specify either ClusterEndpoint
or DomainARN
.
*
*
* @return The ARN of the Amazon ES domain. The IAM role must have permissions for
* DescribeElasticsearchDomain
, DescribeElasticsearchDomains
, and
* DescribeElasticsearchDomainConfig
after assuming the role specified in RoleARN. For
* more information, see Amazon Resource Names
* (ARNs) and AWS Service Namespaces.
*
* Specify either ClusterEndpoint
or DomainARN
.
*/
public String getDomainARN() {
return this.domainARN;
}
/**
*
* The ARN of the Amazon ES domain. The IAM role must have permissions for DescribeElasticsearchDomain
,
* DescribeElasticsearchDomains
, and DescribeElasticsearchDomainConfig
after assuming the
* role specified in RoleARN. For more information, see Amazon Resource Names (ARNs)
* and AWS Service Namespaces.
*
*
* Specify either ClusterEndpoint
or DomainARN
.
*
*
* @param domainARN
* The ARN of the Amazon ES domain. The IAM role must have permissions for
* DescribeElasticsearchDomain
, DescribeElasticsearchDomains
, and
* DescribeElasticsearchDomainConfig
after assuming the role specified in RoleARN. For
* more information, see Amazon Resource Names
* (ARNs) and AWS Service Namespaces.
*
* Specify either ClusterEndpoint
or DomainARN
.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public ElasticsearchDestinationConfiguration withDomainARN(String domainARN) {
setDomainARN(domainARN);
return this;
}
/**
*
* 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.
*/
public void setClusterEndpoint(String clusterEndpoint) {
this.clusterEndpoint = clusterEndpoint;
}
/**
*
* 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 String getClusterEndpoint() {
return this.clusterEndpoint;
}
/**
*
* 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.
*/
public ElasticsearchDestinationConfiguration withClusterEndpoint(String clusterEndpoint) {
setClusterEndpoint(clusterEndpoint);
return this;
}
/**
*
* The Elasticsearch index name.
*
*
* @param indexName
* The Elasticsearch index name.
*/
public void setIndexName(String indexName) {
this.indexName = indexName;
}
/**
*
* The Elasticsearch index name.
*
*
* @return The Elasticsearch index name.
*/
public String getIndexName() {
return this.indexName;
}
/**
*
* The Elasticsearch index name.
*
*
* @param indexName
* The Elasticsearch index name.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public ElasticsearchDestinationConfiguration withIndexName(String indexName) {
setIndexName(indexName);
return this;
}
/**
*
* The Elasticsearch 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 run
* time.
*
*
* For Elasticsearch 7.x, don't specify a TypeName
.
*
*
* @param typeName
* The Elasticsearch 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 run time.
*
* For Elasticsearch 7.x, don't specify a TypeName
.
*/
public void setTypeName(String typeName) {
this.typeName = typeName;
}
/**
*
* The Elasticsearch 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 run
* time.
*
*
* For Elasticsearch 7.x, don't specify a TypeName
.
*
*
* @return The Elasticsearch 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 run time.
*
* For Elasticsearch 7.x, don't specify a TypeName
.
*/
public String getTypeName() {
return this.typeName;
}
/**
*
* The Elasticsearch 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 run
* time.
*
*
* For Elasticsearch 7.x, don't specify a TypeName
.
*
*
* @param typeName
* The Elasticsearch 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 run time.
*
* For Elasticsearch 7.x, don't specify a TypeName
.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public ElasticsearchDestinationConfiguration withTypeName(String typeName) {
setTypeName(typeName);
return this;
}
/**
*
* The Elasticsearch index rotation period. Index rotation appends a timestamp to the IndexName
to
* facilitate the expiration of old data. For more information, see Index Rotation for
* the Amazon ES Destination. The default value is OneDay
.
*
*
* @param indexRotationPeriod
* The Elasticsearch index rotation period. Index rotation appends a timestamp to the IndexName
* to facilitate the expiration of old data. For more information, see Index Rotation
* for the Amazon ES Destination. The default value is OneDay
.
* @see ElasticsearchIndexRotationPeriod
*/
public void setIndexRotationPeriod(String indexRotationPeriod) {
this.indexRotationPeriod = indexRotationPeriod;
}
/**
*
* The Elasticsearch index rotation period. Index rotation appends a timestamp to the IndexName
to
* facilitate the expiration of old data. For more information, see Index Rotation for
* the Amazon ES Destination. The default value is OneDay
.
*
*
* @return The Elasticsearch index rotation period. Index rotation appends a timestamp to the IndexName
* to facilitate the expiration of old data. For more information, see Index
* Rotation for the Amazon ES Destination. The default value is OneDay
.
* @see ElasticsearchIndexRotationPeriod
*/
public String getIndexRotationPeriod() {
return this.indexRotationPeriod;
}
/**
*
* The Elasticsearch index rotation period. Index rotation appends a timestamp to the IndexName
to
* facilitate the expiration of old data. For more information, see Index Rotation for
* the Amazon ES Destination. The default value is OneDay
.
*
*
* @param indexRotationPeriod
* The Elasticsearch index rotation period. Index rotation appends a timestamp to the IndexName
* to facilitate the expiration of old data. For more information, see Index Rotation
* for the Amazon ES Destination. The default value is OneDay
.
* @return Returns a reference to this object so that method calls can be chained together.
* @see ElasticsearchIndexRotationPeriod
*/
public ElasticsearchDestinationConfiguration withIndexRotationPeriod(String indexRotationPeriod) {
setIndexRotationPeriod(indexRotationPeriod);
return this;
}
/**
*
* The Elasticsearch index rotation period. Index rotation appends a timestamp to the IndexName
to
* facilitate the expiration of old data. For more information, see Index Rotation for
* the Amazon ES Destination. The default value is OneDay
.
*
*
* @param indexRotationPeriod
* The Elasticsearch index rotation period. Index rotation appends a timestamp to the IndexName
* to facilitate the expiration of old data. For more information, see Index Rotation
* for the Amazon ES Destination. The default value is OneDay
.
* @see ElasticsearchIndexRotationPeriod
*/
public void setIndexRotationPeriod(ElasticsearchIndexRotationPeriod indexRotationPeriod) {
withIndexRotationPeriod(indexRotationPeriod);
}
/**
*
* The Elasticsearch index rotation period. Index rotation appends a timestamp to the IndexName
to
* facilitate the expiration of old data. For more information, see Index Rotation for
* the Amazon ES Destination. The default value is OneDay
.
*
*
* @param indexRotationPeriod
* The Elasticsearch index rotation period. Index rotation appends a timestamp to the IndexName
* to facilitate the expiration of old data. For more information, see Index Rotation
* for the Amazon ES Destination. The default value is OneDay
.
* @return Returns a reference to this object so that method calls can be chained together.
* @see ElasticsearchIndexRotationPeriod
*/
public ElasticsearchDestinationConfiguration withIndexRotationPeriod(ElasticsearchIndexRotationPeriod indexRotationPeriod) {
this.indexRotationPeriod = indexRotationPeriod.toString();
return this;
}
/**
*
* The buffering options. If no value is specified, the default values for ElasticsearchBufferingHints
* are used.
*
*
* @param bufferingHints
* The buffering options. If no value is specified, the default values for
* ElasticsearchBufferingHints
are used.
*/
public void setBufferingHints(ElasticsearchBufferingHints bufferingHints) {
this.bufferingHints = bufferingHints;
}
/**
*
* The buffering options. If no value is specified, the default values for ElasticsearchBufferingHints
* are used.
*
*
* @return The buffering options. If no value is specified, the default values for
* ElasticsearchBufferingHints
are used.
*/
public ElasticsearchBufferingHints getBufferingHints() {
return this.bufferingHints;
}
/**
*
* The buffering options. If no value is specified, the default values for ElasticsearchBufferingHints
* are used.
*
*
* @param bufferingHints
* The buffering options. If no value is specified, the default values for
* ElasticsearchBufferingHints
are used.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public ElasticsearchDestinationConfiguration withBufferingHints(ElasticsearchBufferingHints bufferingHints) {
setBufferingHints(bufferingHints);
return this;
}
/**
*
* The retry behavior in case Kinesis Data Firehose is unable to deliver documents to Amazon ES. The default value
* is 300 (5 minutes).
*
*
* @param retryOptions
* The retry behavior in case Kinesis Data Firehose is unable to deliver documents to Amazon ES. The default
* value is 300 (5 minutes).
*/
public void setRetryOptions(ElasticsearchRetryOptions retryOptions) {
this.retryOptions = retryOptions;
}
/**
*
* The retry behavior in case Kinesis Data Firehose is unable to deliver documents to Amazon ES. The default value
* is 300 (5 minutes).
*
*
* @return The retry behavior in case Kinesis Data Firehose is unable to deliver documents to Amazon ES. The default
* value is 300 (5 minutes).
*/
public ElasticsearchRetryOptions getRetryOptions() {
return this.retryOptions;
}
/**
*
* The retry behavior in case Kinesis Data Firehose is unable to deliver documents to Amazon ES. The default value
* is 300 (5 minutes).
*
*
* @param retryOptions
* The retry behavior in case Kinesis Data Firehose is unable to deliver documents to Amazon ES. The default
* value is 300 (5 minutes).
* @return Returns a reference to this object so that method calls can be chained together.
*/
public ElasticsearchDestinationConfiguration withRetryOptions(ElasticsearchRetryOptions retryOptions) {
setRetryOptions(retryOptions);
return this;
}
/**
*
* Defines how documents should be delivered to Amazon S3. When it is set to FailedDocumentsOnly
,
* Kinesis Data Firehose writes any documents that could not be indexed to the configured Amazon S3 destination,
* with elasticsearch-failed/
appended to the key prefix. When set to AllDocuments
,
* Kinesis Data Firehose delivers all incoming records to Amazon S3, and also writes failed documents with
* elasticsearch-failed/
appended to the prefix. For more information, see Amazon S3 Backup for the
* Amazon ES Destination. Default value is FailedDocumentsOnly
.
*
*
* You can't change this backup mode after you create the delivery stream.
*
*
* @param s3BackupMode
* Defines how documents should be delivered to Amazon S3. When it is set to FailedDocumentsOnly
* , Kinesis Data Firehose writes any documents that could not be indexed to the configured Amazon S3
* destination, with elasticsearch-failed/
appended to the key prefix. When set to
* AllDocuments
, Kinesis Data Firehose delivers all incoming records to Amazon S3, and also
* writes failed documents with elasticsearch-failed/
appended to the prefix. For more
* information, see Amazon S3 Backup
* for the Amazon ES Destination. Default value is FailedDocumentsOnly
.
*
* You can't change this backup mode after you create the delivery stream.
* @see ElasticsearchS3BackupMode
*/
public void setS3BackupMode(String s3BackupMode) {
this.s3BackupMode = s3BackupMode;
}
/**
*
* Defines how documents should be delivered to Amazon S3. When it is set to FailedDocumentsOnly
,
* Kinesis Data Firehose writes any documents that could not be indexed to the configured Amazon S3 destination,
* with elasticsearch-failed/
appended to the key prefix. When set to AllDocuments
,
* Kinesis Data Firehose delivers all incoming records to Amazon S3, and also writes failed documents with
* elasticsearch-failed/
appended to the prefix. For more information, see Amazon S3 Backup for the
* Amazon ES Destination. Default value is FailedDocumentsOnly
.
*
*
* You can't change this backup mode after you create the delivery stream.
*
*
* @return Defines how documents should be delivered to Amazon S3. When it is set to
* FailedDocumentsOnly
, Kinesis Data Firehose writes any documents that could not be indexed to
* the configured Amazon S3 destination, with elasticsearch-failed/
appended to the key prefix.
* When set to AllDocuments
, Kinesis Data Firehose delivers all incoming records to Amazon S3,
* and also writes failed documents with elasticsearch-failed/
appended to the prefix. For more
* information, see Amazon S3 Backup
* for the Amazon ES Destination. Default value is FailedDocumentsOnly
.
*
* You can't change this backup mode after you create the delivery stream.
* @see ElasticsearchS3BackupMode
*/
public String getS3BackupMode() {
return this.s3BackupMode;
}
/**
*
* Defines how documents should be delivered to Amazon S3. When it is set to FailedDocumentsOnly
,
* Kinesis Data Firehose writes any documents that could not be indexed to the configured Amazon S3 destination,
* with elasticsearch-failed/
appended to the key prefix. When set to AllDocuments
,
* Kinesis Data Firehose delivers all incoming records to Amazon S3, and also writes failed documents with
* elasticsearch-failed/
appended to the prefix. For more information, see Amazon S3 Backup for the
* Amazon ES Destination. Default value is FailedDocumentsOnly
.
*
*
* You can't change this backup mode after you create the delivery stream.
*
*
* @param s3BackupMode
* Defines how documents should be delivered to Amazon S3. When it is set to FailedDocumentsOnly
* , Kinesis Data Firehose writes any documents that could not be indexed to the configured Amazon S3
* destination, with elasticsearch-failed/
appended to the key prefix. When set to
* AllDocuments
, Kinesis Data Firehose delivers all incoming records to Amazon S3, and also
* writes failed documents with elasticsearch-failed/
appended to the prefix. For more
* information, see Amazon S3 Backup
* for the Amazon ES Destination. Default value is FailedDocumentsOnly
.
*
* You can't change this backup mode after you create the delivery stream.
* @return Returns a reference to this object so that method calls can be chained together.
* @see ElasticsearchS3BackupMode
*/
public ElasticsearchDestinationConfiguration withS3BackupMode(String s3BackupMode) {
setS3BackupMode(s3BackupMode);
return this;
}
/**
*
* Defines how documents should be delivered to Amazon S3. When it is set to FailedDocumentsOnly
,
* Kinesis Data Firehose writes any documents that could not be indexed to the configured Amazon S3 destination,
* with elasticsearch-failed/
appended to the key prefix. When set to AllDocuments
,
* Kinesis Data Firehose delivers all incoming records to Amazon S3, and also writes failed documents with
* elasticsearch-failed/
appended to the prefix. For more information, see Amazon S3 Backup for the
* Amazon ES Destination. Default value is FailedDocumentsOnly
.
*
*
* You can't change this backup mode after you create the delivery stream.
*
*
* @param s3BackupMode
* Defines how documents should be delivered to Amazon S3. When it is set to FailedDocumentsOnly
* , Kinesis Data Firehose writes any documents that could not be indexed to the configured Amazon S3
* destination, with elasticsearch-failed/
appended to the key prefix. When set to
* AllDocuments
, Kinesis Data Firehose delivers all incoming records to Amazon S3, and also
* writes failed documents with elasticsearch-failed/
appended to the prefix. For more
* information, see Amazon S3 Backup
* for the Amazon ES Destination. Default value is FailedDocumentsOnly
.
*
* You can't change this backup mode after you create the delivery stream.
* @see ElasticsearchS3BackupMode
*/
public void setS3BackupMode(ElasticsearchS3BackupMode s3BackupMode) {
withS3BackupMode(s3BackupMode);
}
/**
*
* Defines how documents should be delivered to Amazon S3. When it is set to FailedDocumentsOnly
,
* Kinesis Data Firehose writes any documents that could not be indexed to the configured Amazon S3 destination,
* with elasticsearch-failed/
appended to the key prefix. When set to AllDocuments
,
* Kinesis Data Firehose delivers all incoming records to Amazon S3, and also writes failed documents with
* elasticsearch-failed/
appended to the prefix. For more information, see Amazon S3 Backup for the
* Amazon ES Destination. Default value is FailedDocumentsOnly
.
*
*
* You can't change this backup mode after you create the delivery stream.
*
*
* @param s3BackupMode
* Defines how documents should be delivered to Amazon S3. When it is set to FailedDocumentsOnly
* , Kinesis Data Firehose writes any documents that could not be indexed to the configured Amazon S3
* destination, with elasticsearch-failed/
appended to the key prefix. When set to
* AllDocuments
, Kinesis Data Firehose delivers all incoming records to Amazon S3, and also
* writes failed documents with elasticsearch-failed/
appended to the prefix. For more
* information, see Amazon S3 Backup
* for the Amazon ES Destination. Default value is FailedDocumentsOnly
.
*
* You can't change this backup mode after you create the delivery stream.
* @return Returns a reference to this object so that method calls can be chained together.
* @see ElasticsearchS3BackupMode
*/
public ElasticsearchDestinationConfiguration withS3BackupMode(ElasticsearchS3BackupMode s3BackupMode) {
this.s3BackupMode = s3BackupMode.toString();
return this;
}
/**
*
* The configuration for the backup Amazon S3 location.
*
*
* @param s3Configuration
* The configuration for the backup Amazon S3 location.
*/
public void setS3Configuration(S3DestinationConfiguration s3Configuration) {
this.s3Configuration = s3Configuration;
}
/**
*
* The configuration for the backup Amazon S3 location.
*
*
* @return The configuration for the backup Amazon S3 location.
*/
public S3DestinationConfiguration getS3Configuration() {
return this.s3Configuration;
}
/**
*
* The configuration for the backup Amazon S3 location.
*
*
* @param s3Configuration
* The configuration for the backup Amazon S3 location.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public ElasticsearchDestinationConfiguration withS3Configuration(S3DestinationConfiguration s3Configuration) {
setS3Configuration(s3Configuration);
return this;
}
/**
*
* The data processing configuration.
*
*
* @param processingConfiguration
* The data processing configuration.
*/
public void setProcessingConfiguration(ProcessingConfiguration processingConfiguration) {
this.processingConfiguration = processingConfiguration;
}
/**
*
* The data processing configuration.
*
*
* @return The data processing configuration.
*/
public ProcessingConfiguration getProcessingConfiguration() {
return this.processingConfiguration;
}
/**
*
* The data processing configuration.
*
*
* @param processingConfiguration
* The data processing configuration.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public ElasticsearchDestinationConfiguration withProcessingConfiguration(ProcessingConfiguration processingConfiguration) {
setProcessingConfiguration(processingConfiguration);
return this;
}
/**
*
* The Amazon CloudWatch logging options for your delivery stream.
*
*
* @param cloudWatchLoggingOptions
* The Amazon CloudWatch logging options for your delivery stream.
*/
public void setCloudWatchLoggingOptions(CloudWatchLoggingOptions cloudWatchLoggingOptions) {
this.cloudWatchLoggingOptions = cloudWatchLoggingOptions;
}
/**
*
* The Amazon CloudWatch logging options for your delivery stream.
*
*
* @return The Amazon CloudWatch logging options for your delivery stream.
*/
public CloudWatchLoggingOptions getCloudWatchLoggingOptions() {
return this.cloudWatchLoggingOptions;
}
/**
*
* The Amazon CloudWatch logging options for your delivery stream.
*
*
* @param cloudWatchLoggingOptions
* The Amazon CloudWatch logging options for your delivery stream.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public ElasticsearchDestinationConfiguration withCloudWatchLoggingOptions(CloudWatchLoggingOptions cloudWatchLoggingOptions) {
setCloudWatchLoggingOptions(cloudWatchLoggingOptions);
return this;
}
/**
*
* The details of the VPC of the Amazon ES destination.
*
*
* @param vpcConfiguration
* The details of the VPC of the Amazon ES destination.
*/
public void setVpcConfiguration(VpcConfiguration vpcConfiguration) {
this.vpcConfiguration = vpcConfiguration;
}
/**
*
* The details of the VPC of the Amazon ES destination.
*
*
* @return The details of the VPC of the Amazon ES destination.
*/
public VpcConfiguration getVpcConfiguration() {
return this.vpcConfiguration;
}
/**
*
* The details of the VPC of the Amazon ES destination.
*
*
* @param vpcConfiguration
* The details of the VPC of the Amazon ES destination.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public ElasticsearchDestinationConfiguration withVpcConfiguration(VpcConfiguration vpcConfiguration) {
setVpcConfiguration(vpcConfiguration);
return this;
}
/**
* 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.
*
* @return A string representation of this object.
*
* @see java.lang.Object#toString()
*/
@Override
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append("{");
if (getRoleARN() != null)
sb.append("RoleARN: ").append(getRoleARN()).append(",");
if (getDomainARN() != null)
sb.append("DomainARN: ").append(getDomainARN()).append(",");
if (getClusterEndpoint() != null)
sb.append("ClusterEndpoint: ").append(getClusterEndpoint()).append(",");
if (getIndexName() != null)
sb.append("IndexName: ").append(getIndexName()).append(",");
if (getTypeName() != null)
sb.append("TypeName: ").append(getTypeName()).append(",");
if (getIndexRotationPeriod() != null)
sb.append("IndexRotationPeriod: ").append(getIndexRotationPeriod()).append(",");
if (getBufferingHints() != null)
sb.append("BufferingHints: ").append(getBufferingHints()).append(",");
if (getRetryOptions() != null)
sb.append("RetryOptions: ").append(getRetryOptions()).append(",");
if (getS3BackupMode() != null)
sb.append("S3BackupMode: ").append(getS3BackupMode()).append(",");
if (getS3Configuration() != null)
sb.append("S3Configuration: ").append(getS3Configuration()).append(",");
if (getProcessingConfiguration() != null)
sb.append("ProcessingConfiguration: ").append(getProcessingConfiguration()).append(",");
if (getCloudWatchLoggingOptions() != null)
sb.append("CloudWatchLoggingOptions: ").append(getCloudWatchLoggingOptions()).append(",");
if (getVpcConfiguration() != null)
sb.append("VpcConfiguration: ").append(getVpcConfiguration());
sb.append("}");
return sb.toString();
}
@Override
public boolean equals(Object obj) {
if (this == obj)
return true;
if (obj == null)
return false;
if (obj instanceof ElasticsearchDestinationConfiguration == false)
return false;
ElasticsearchDestinationConfiguration other = (ElasticsearchDestinationConfiguration) obj;
if (other.getRoleARN() == null ^ this.getRoleARN() == null)
return false;
if (other.getRoleARN() != null && other.getRoleARN().equals(this.getRoleARN()) == false)
return false;
if (other.getDomainARN() == null ^ this.getDomainARN() == null)
return false;
if (other.getDomainARN() != null && other.getDomainARN().equals(this.getDomainARN()) == false)
return false;
if (other.getClusterEndpoint() == null ^ this.getClusterEndpoint() == null)
return false;
if (other.getClusterEndpoint() != null && other.getClusterEndpoint().equals(this.getClusterEndpoint()) == false)
return false;
if (other.getIndexName() == null ^ this.getIndexName() == null)
return false;
if (other.getIndexName() != null && other.getIndexName().equals(this.getIndexName()) == false)
return false;
if (other.getTypeName() == null ^ this.getTypeName() == null)
return false;
if (other.getTypeName() != null && other.getTypeName().equals(this.getTypeName()) == false)
return false;
if (other.getIndexRotationPeriod() == null ^ this.getIndexRotationPeriod() == null)
return false;
if (other.getIndexRotationPeriod() != null && other.getIndexRotationPeriod().equals(this.getIndexRotationPeriod()) == false)
return false;
if (other.getBufferingHints() == null ^ this.getBufferingHints() == null)
return false;
if (other.getBufferingHints() != null && other.getBufferingHints().equals(this.getBufferingHints()) == false)
return false;
if (other.getRetryOptions() == null ^ this.getRetryOptions() == null)
return false;
if (other.getRetryOptions() != null && other.getRetryOptions().equals(this.getRetryOptions()) == false)
return false;
if (other.getS3BackupMode() == null ^ this.getS3BackupMode() == null)
return false;
if (other.getS3BackupMode() != null && other.getS3BackupMode().equals(this.getS3BackupMode()) == false)
return false;
if (other.getS3Configuration() == null ^ this.getS3Configuration() == null)
return false;
if (other.getS3Configuration() != null && other.getS3Configuration().equals(this.getS3Configuration()) == false)
return false;
if (other.getProcessingConfiguration() == null ^ this.getProcessingConfiguration() == null)
return false;
if (other.getProcessingConfiguration() != null && other.getProcessingConfiguration().equals(this.getProcessingConfiguration()) == false)
return false;
if (other.getCloudWatchLoggingOptions() == null ^ this.getCloudWatchLoggingOptions() == null)
return false;
if (other.getCloudWatchLoggingOptions() != null && other.getCloudWatchLoggingOptions().equals(this.getCloudWatchLoggingOptions()) == false)
return false;
if (other.getVpcConfiguration() == null ^ this.getVpcConfiguration() == null)
return false;
if (other.getVpcConfiguration() != null && other.getVpcConfiguration().equals(this.getVpcConfiguration()) == false)
return false;
return true;
}
@Override
public int hashCode() {
final int prime = 31;
int hashCode = 1;
hashCode = prime * hashCode + ((getRoleARN() == null) ? 0 : getRoleARN().hashCode());
hashCode = prime * hashCode + ((getDomainARN() == null) ? 0 : getDomainARN().hashCode());
hashCode = prime * hashCode + ((getClusterEndpoint() == null) ? 0 : getClusterEndpoint().hashCode());
hashCode = prime * hashCode + ((getIndexName() == null) ? 0 : getIndexName().hashCode());
hashCode = prime * hashCode + ((getTypeName() == null) ? 0 : getTypeName().hashCode());
hashCode = prime * hashCode + ((getIndexRotationPeriod() == null) ? 0 : getIndexRotationPeriod().hashCode());
hashCode = prime * hashCode + ((getBufferingHints() == null) ? 0 : getBufferingHints().hashCode());
hashCode = prime * hashCode + ((getRetryOptions() == null) ? 0 : getRetryOptions().hashCode());
hashCode = prime * hashCode + ((getS3BackupMode() == null) ? 0 : getS3BackupMode().hashCode());
hashCode = prime * hashCode + ((getS3Configuration() == null) ? 0 : getS3Configuration().hashCode());
hashCode = prime * hashCode + ((getProcessingConfiguration() == null) ? 0 : getProcessingConfiguration().hashCode());
hashCode = prime * hashCode + ((getCloudWatchLoggingOptions() == null) ? 0 : getCloudWatchLoggingOptions().hashCode());
hashCode = prime * hashCode + ((getVpcConfiguration() == null) ? 0 : getVpcConfiguration().hashCode());
return hashCode;
}
@Override
public ElasticsearchDestinationConfiguration clone() {
try {
return (ElasticsearchDestinationConfiguration) super.clone();
} catch (CloneNotSupportedException e) {
throw new IllegalStateException("Got a CloneNotSupportedException from Object.clone() " + "even though we're Cloneable!", e);
}
}
@com.amazonaws.annotation.SdkInternalApi
@Override
public void marshall(ProtocolMarshaller protocolMarshaller) {
com.amazonaws.services.kinesisfirehose.model.transform.ElasticsearchDestinationConfigurationMarshaller.getInstance().marshall(this, protocolMarshaller);
}
}