{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE DuplicateRecordFields #-}
{-# LANGUAGE NamedFieldPuns #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE StrictData #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-unused-matches #-}

-- Derived from AWS service descriptions, licensed under Apache 2.0.

-- |
-- Module      : Amazonka.Firehose.Types.AmazonopensearchserviceDestinationDescription
-- Copyright   : (c) 2013-2023 Brendan Hay
-- License     : Mozilla Public License, v. 2.0.
-- Maintainer  : Brendan Hay
-- Stability   : auto-generated
-- Portability : non-portable (GHC extensions)
module Amazonka.Firehose.Types.AmazonopensearchserviceDestinationDescription where

import qualified Amazonka.Core as Core
import qualified Amazonka.Core.Lens.Internal as Lens
import qualified Amazonka.Data as Data
import Amazonka.Firehose.Types.AmazonopensearchserviceBufferingHints
import Amazonka.Firehose.Types.AmazonopensearchserviceIndexRotationPeriod
import Amazonka.Firehose.Types.AmazonopensearchserviceRetryOptions
import Amazonka.Firehose.Types.AmazonopensearchserviceS3BackupMode
import Amazonka.Firehose.Types.CloudWatchLoggingOptions
import Amazonka.Firehose.Types.ProcessingConfiguration
import Amazonka.Firehose.Types.S3DestinationDescription
import Amazonka.Firehose.Types.VpcConfigurationDescription
import qualified Amazonka.Prelude as Prelude

-- | The destination description in Amazon OpenSearch Service.
--
-- /See:/ 'newAmazonopensearchserviceDestinationDescription' smart constructor.
data AmazonopensearchserviceDestinationDescription = AmazonopensearchserviceDestinationDescription'
  { -- | The buffering options.
    AmazonopensearchserviceDestinationDescription
-> Maybe AmazonopensearchserviceBufferingHints
bufferingHints :: Prelude.Maybe AmazonopensearchserviceBufferingHints,
    AmazonopensearchserviceDestinationDescription
-> Maybe CloudWatchLoggingOptions
cloudWatchLoggingOptions :: Prelude.Maybe CloudWatchLoggingOptions,
    -- | The endpoint to use when communicating with the cluster. Kinesis Data
    -- Firehose uses either this ClusterEndpoint or the DomainARN field to send
    -- data to Amazon OpenSearch Service.
    AmazonopensearchserviceDestinationDescription -> Maybe Text
clusterEndpoint :: Prelude.Maybe Prelude.Text,
    -- | The ARN of the Amazon OpenSearch Service domain.
    AmazonopensearchserviceDestinationDescription -> Maybe Text
domainARN :: Prelude.Maybe Prelude.Text,
    -- | The Amazon OpenSearch Service index name.
    AmazonopensearchserviceDestinationDescription -> Maybe Text
indexName :: Prelude.Maybe Prelude.Text,
    -- | The Amazon OpenSearch Service index rotation period
    AmazonopensearchserviceDestinationDescription
-> Maybe AmazonopensearchserviceIndexRotationPeriod
indexRotationPeriod :: Prelude.Maybe AmazonopensearchserviceIndexRotationPeriod,
    AmazonopensearchserviceDestinationDescription
-> Maybe ProcessingConfiguration
processingConfiguration :: Prelude.Maybe ProcessingConfiguration,
    -- | The Amazon OpenSearch Service retry options.
    AmazonopensearchserviceDestinationDescription
-> Maybe AmazonopensearchserviceRetryOptions
retryOptions :: Prelude.Maybe AmazonopensearchserviceRetryOptions,
    -- | The Amazon Resource Name (ARN) of the Amazon Web Services credentials.
    AmazonopensearchserviceDestinationDescription -> Maybe Text
roleARN :: Prelude.Maybe Prelude.Text,
    -- | The Amazon S3 backup mode.
    AmazonopensearchserviceDestinationDescription
-> Maybe AmazonopensearchserviceS3BackupMode
s3BackupMode :: Prelude.Maybe AmazonopensearchserviceS3BackupMode,
    AmazonopensearchserviceDestinationDescription
-> Maybe S3DestinationDescription
s3DestinationDescription :: Prelude.Maybe S3DestinationDescription,
    -- | The Amazon OpenSearch Service type name. This applies to Elasticsearch
    -- 6.x and lower versions. For Elasticsearch 7.x and OpenSearch Service
    -- 1.x, there\'s no value for TypeName.
    AmazonopensearchserviceDestinationDescription -> Maybe Text
typeName :: Prelude.Maybe Prelude.Text,
    AmazonopensearchserviceDestinationDescription
-> Maybe VpcConfigurationDescription
vpcConfigurationDescription :: Prelude.Maybe VpcConfigurationDescription
  }
  deriving (AmazonopensearchserviceDestinationDescription
-> AmazonopensearchserviceDestinationDescription -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: AmazonopensearchserviceDestinationDescription
-> AmazonopensearchserviceDestinationDescription -> Bool
$c/= :: AmazonopensearchserviceDestinationDescription
-> AmazonopensearchserviceDestinationDescription -> Bool
== :: AmazonopensearchserviceDestinationDescription
-> AmazonopensearchserviceDestinationDescription -> Bool
$c== :: AmazonopensearchserviceDestinationDescription
-> AmazonopensearchserviceDestinationDescription -> Bool
Prelude.Eq, ReadPrec [AmazonopensearchserviceDestinationDescription]
ReadPrec AmazonopensearchserviceDestinationDescription
Int -> ReadS AmazonopensearchserviceDestinationDescription
ReadS [AmazonopensearchserviceDestinationDescription]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [AmazonopensearchserviceDestinationDescription]
$creadListPrec :: ReadPrec [AmazonopensearchserviceDestinationDescription]
readPrec :: ReadPrec AmazonopensearchserviceDestinationDescription
$creadPrec :: ReadPrec AmazonopensearchserviceDestinationDescription
readList :: ReadS [AmazonopensearchserviceDestinationDescription]
$creadList :: ReadS [AmazonopensearchserviceDestinationDescription]
readsPrec :: Int -> ReadS AmazonopensearchserviceDestinationDescription
$creadsPrec :: Int -> ReadS AmazonopensearchserviceDestinationDescription
Prelude.Read, Int -> AmazonopensearchserviceDestinationDescription -> ShowS
[AmazonopensearchserviceDestinationDescription] -> ShowS
AmazonopensearchserviceDestinationDescription -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [AmazonopensearchserviceDestinationDescription] -> ShowS
$cshowList :: [AmazonopensearchserviceDestinationDescription] -> ShowS
show :: AmazonopensearchserviceDestinationDescription -> String
$cshow :: AmazonopensearchserviceDestinationDescription -> String
showsPrec :: Int -> AmazonopensearchserviceDestinationDescription -> ShowS
$cshowsPrec :: Int -> AmazonopensearchserviceDestinationDescription -> ShowS
Prelude.Show, forall x.
Rep AmazonopensearchserviceDestinationDescription x
-> AmazonopensearchserviceDestinationDescription
forall x.
AmazonopensearchserviceDestinationDescription
-> Rep AmazonopensearchserviceDestinationDescription x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep AmazonopensearchserviceDestinationDescription x
-> AmazonopensearchserviceDestinationDescription
$cfrom :: forall x.
AmazonopensearchserviceDestinationDescription
-> Rep AmazonopensearchserviceDestinationDescription x
Prelude.Generic)

-- |
-- Create a value of 'AmazonopensearchserviceDestinationDescription' with all optional fields omitted.
--
-- Use <https://hackage.haskell.org/package/generic-lens generic-lens> or <https://hackage.haskell.org/package/optics optics> to modify other optional fields.
--
-- The following record fields are available, with the corresponding lenses provided
-- for backwards compatibility:
--
-- 'bufferingHints', 'amazonopensearchserviceDestinationDescription_bufferingHints' - The buffering options.
--
-- 'cloudWatchLoggingOptions', 'amazonopensearchserviceDestinationDescription_cloudWatchLoggingOptions' - Undocumented member.
--
-- 'clusterEndpoint', 'amazonopensearchserviceDestinationDescription_clusterEndpoint' - The endpoint to use when communicating with the cluster. Kinesis Data
-- Firehose uses either this ClusterEndpoint or the DomainARN field to send
-- data to Amazon OpenSearch Service.
--
-- 'domainARN', 'amazonopensearchserviceDestinationDescription_domainARN' - The ARN of the Amazon OpenSearch Service domain.
--
-- 'indexName', 'amazonopensearchserviceDestinationDescription_indexName' - The Amazon OpenSearch Service index name.
--
-- 'indexRotationPeriod', 'amazonopensearchserviceDestinationDescription_indexRotationPeriod' - The Amazon OpenSearch Service index rotation period
--
-- 'processingConfiguration', 'amazonopensearchserviceDestinationDescription_processingConfiguration' - Undocumented member.
--
-- 'retryOptions', 'amazonopensearchserviceDestinationDescription_retryOptions' - The Amazon OpenSearch Service retry options.
--
-- 'roleARN', 'amazonopensearchserviceDestinationDescription_roleARN' - The Amazon Resource Name (ARN) of the Amazon Web Services credentials.
--
-- 's3BackupMode', 'amazonopensearchserviceDestinationDescription_s3BackupMode' - The Amazon S3 backup mode.
--
-- 's3DestinationDescription', 'amazonopensearchserviceDestinationDescription_s3DestinationDescription' - Undocumented member.
--
-- 'typeName', 'amazonopensearchserviceDestinationDescription_typeName' - The Amazon OpenSearch Service type name. This applies to Elasticsearch
-- 6.x and lower versions. For Elasticsearch 7.x and OpenSearch Service
-- 1.x, there\'s no value for TypeName.
--
-- 'vpcConfigurationDescription', 'amazonopensearchserviceDestinationDescription_vpcConfigurationDescription' - Undocumented member.
newAmazonopensearchserviceDestinationDescription ::
  AmazonopensearchserviceDestinationDescription
newAmazonopensearchserviceDestinationDescription :: AmazonopensearchserviceDestinationDescription
newAmazonopensearchserviceDestinationDescription =
  AmazonopensearchserviceDestinationDescription'
    { $sel:bufferingHints:AmazonopensearchserviceDestinationDescription' :: Maybe AmazonopensearchserviceBufferingHints
bufferingHints =
        forall a. Maybe a
Prelude.Nothing,
      $sel:cloudWatchLoggingOptions:AmazonopensearchserviceDestinationDescription' :: Maybe CloudWatchLoggingOptions
cloudWatchLoggingOptions =
        forall a. Maybe a
Prelude.Nothing,
      $sel:clusterEndpoint:AmazonopensearchserviceDestinationDescription' :: Maybe Text
clusterEndpoint =
        forall a. Maybe a
Prelude.Nothing,
      $sel:domainARN:AmazonopensearchserviceDestinationDescription' :: Maybe Text
domainARN = forall a. Maybe a
Prelude.Nothing,
      $sel:indexName:AmazonopensearchserviceDestinationDescription' :: Maybe Text
indexName = forall a. Maybe a
Prelude.Nothing,
      $sel:indexRotationPeriod:AmazonopensearchserviceDestinationDescription' :: Maybe AmazonopensearchserviceIndexRotationPeriod
indexRotationPeriod =
        forall a. Maybe a
Prelude.Nothing,
      $sel:processingConfiguration:AmazonopensearchserviceDestinationDescription' :: Maybe ProcessingConfiguration
processingConfiguration =
        forall a. Maybe a
Prelude.Nothing,
      $sel:retryOptions:AmazonopensearchserviceDestinationDescription' :: Maybe AmazonopensearchserviceRetryOptions
retryOptions =
        forall a. Maybe a
Prelude.Nothing,
      $sel:roleARN:AmazonopensearchserviceDestinationDescription' :: Maybe Text
roleARN = forall a. Maybe a
Prelude.Nothing,
      $sel:s3BackupMode:AmazonopensearchserviceDestinationDescription' :: Maybe AmazonopensearchserviceS3BackupMode
s3BackupMode =
        forall a. Maybe a
Prelude.Nothing,
      $sel:s3DestinationDescription:AmazonopensearchserviceDestinationDescription' :: Maybe S3DestinationDescription
s3DestinationDescription =
        forall a. Maybe a
Prelude.Nothing,
      $sel:typeName:AmazonopensearchserviceDestinationDescription' :: Maybe Text
typeName = forall a. Maybe a
Prelude.Nothing,
      $sel:vpcConfigurationDescription:AmazonopensearchserviceDestinationDescription' :: Maybe VpcConfigurationDescription
vpcConfigurationDescription =
        forall a. Maybe a
Prelude.Nothing
    }

-- | The buffering options.
amazonopensearchserviceDestinationDescription_bufferingHints :: Lens.Lens' AmazonopensearchserviceDestinationDescription (Prelude.Maybe AmazonopensearchserviceBufferingHints)
amazonopensearchserviceDestinationDescription_bufferingHints :: Lens'
  AmazonopensearchserviceDestinationDescription
  (Maybe AmazonopensearchserviceBufferingHints)
amazonopensearchserviceDestinationDescription_bufferingHints = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AmazonopensearchserviceDestinationDescription' {Maybe AmazonopensearchserviceBufferingHints
bufferingHints :: Maybe AmazonopensearchserviceBufferingHints
$sel:bufferingHints:AmazonopensearchserviceDestinationDescription' :: AmazonopensearchserviceDestinationDescription
-> Maybe AmazonopensearchserviceBufferingHints
bufferingHints} -> Maybe AmazonopensearchserviceBufferingHints
bufferingHints) (\s :: AmazonopensearchserviceDestinationDescription
s@AmazonopensearchserviceDestinationDescription' {} Maybe AmazonopensearchserviceBufferingHints
a -> AmazonopensearchserviceDestinationDescription
s {$sel:bufferingHints:AmazonopensearchserviceDestinationDescription' :: Maybe AmazonopensearchserviceBufferingHints
bufferingHints = Maybe AmazonopensearchserviceBufferingHints
a} :: AmazonopensearchserviceDestinationDescription)

-- | Undocumented member.
amazonopensearchserviceDestinationDescription_cloudWatchLoggingOptions :: Lens.Lens' AmazonopensearchserviceDestinationDescription (Prelude.Maybe CloudWatchLoggingOptions)
amazonopensearchserviceDestinationDescription_cloudWatchLoggingOptions :: Lens'
  AmazonopensearchserviceDestinationDescription
  (Maybe CloudWatchLoggingOptions)
amazonopensearchserviceDestinationDescription_cloudWatchLoggingOptions = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AmazonopensearchserviceDestinationDescription' {Maybe CloudWatchLoggingOptions
cloudWatchLoggingOptions :: Maybe CloudWatchLoggingOptions
$sel:cloudWatchLoggingOptions:AmazonopensearchserviceDestinationDescription' :: AmazonopensearchserviceDestinationDescription
-> Maybe CloudWatchLoggingOptions
cloudWatchLoggingOptions} -> Maybe CloudWatchLoggingOptions
cloudWatchLoggingOptions) (\s :: AmazonopensearchserviceDestinationDescription
s@AmazonopensearchserviceDestinationDescription' {} Maybe CloudWatchLoggingOptions
a -> AmazonopensearchserviceDestinationDescription
s {$sel:cloudWatchLoggingOptions:AmazonopensearchserviceDestinationDescription' :: Maybe CloudWatchLoggingOptions
cloudWatchLoggingOptions = Maybe CloudWatchLoggingOptions
a} :: AmazonopensearchserviceDestinationDescription)

-- | The endpoint to use when communicating with the cluster. Kinesis Data
-- Firehose uses either this ClusterEndpoint or the DomainARN field to send
-- data to Amazon OpenSearch Service.
amazonopensearchserviceDestinationDescription_clusterEndpoint :: Lens.Lens' AmazonopensearchserviceDestinationDescription (Prelude.Maybe Prelude.Text)
amazonopensearchserviceDestinationDescription_clusterEndpoint :: Lens' AmazonopensearchserviceDestinationDescription (Maybe Text)
amazonopensearchserviceDestinationDescription_clusterEndpoint = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AmazonopensearchserviceDestinationDescription' {Maybe Text
clusterEndpoint :: Maybe Text
$sel:clusterEndpoint:AmazonopensearchserviceDestinationDescription' :: AmazonopensearchserviceDestinationDescription -> Maybe Text
clusterEndpoint} -> Maybe Text
clusterEndpoint) (\s :: AmazonopensearchserviceDestinationDescription
s@AmazonopensearchserviceDestinationDescription' {} Maybe Text
a -> AmazonopensearchserviceDestinationDescription
s {$sel:clusterEndpoint:AmazonopensearchserviceDestinationDescription' :: Maybe Text
clusterEndpoint = Maybe Text
a} :: AmazonopensearchserviceDestinationDescription)

-- | The ARN of the Amazon OpenSearch Service domain.
amazonopensearchserviceDestinationDescription_domainARN :: Lens.Lens' AmazonopensearchserviceDestinationDescription (Prelude.Maybe Prelude.Text)
amazonopensearchserviceDestinationDescription_domainARN :: Lens' AmazonopensearchserviceDestinationDescription (Maybe Text)
amazonopensearchserviceDestinationDescription_domainARN = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AmazonopensearchserviceDestinationDescription' {Maybe Text
domainARN :: Maybe Text
$sel:domainARN:AmazonopensearchserviceDestinationDescription' :: AmazonopensearchserviceDestinationDescription -> Maybe Text
domainARN} -> Maybe Text
domainARN) (\s :: AmazonopensearchserviceDestinationDescription
s@AmazonopensearchserviceDestinationDescription' {} Maybe Text
a -> AmazonopensearchserviceDestinationDescription
s {$sel:domainARN:AmazonopensearchserviceDestinationDescription' :: Maybe Text
domainARN = Maybe Text
a} :: AmazonopensearchserviceDestinationDescription)

-- | The Amazon OpenSearch Service index name.
amazonopensearchserviceDestinationDescription_indexName :: Lens.Lens' AmazonopensearchserviceDestinationDescription (Prelude.Maybe Prelude.Text)
amazonopensearchserviceDestinationDescription_indexName :: Lens' AmazonopensearchserviceDestinationDescription (Maybe Text)
amazonopensearchserviceDestinationDescription_indexName = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AmazonopensearchserviceDestinationDescription' {Maybe Text
indexName :: Maybe Text
$sel:indexName:AmazonopensearchserviceDestinationDescription' :: AmazonopensearchserviceDestinationDescription -> Maybe Text
indexName} -> Maybe Text
indexName) (\s :: AmazonopensearchserviceDestinationDescription
s@AmazonopensearchserviceDestinationDescription' {} Maybe Text
a -> AmazonopensearchserviceDestinationDescription
s {$sel:indexName:AmazonopensearchserviceDestinationDescription' :: Maybe Text
indexName = Maybe Text
a} :: AmazonopensearchserviceDestinationDescription)

-- | The Amazon OpenSearch Service index rotation period
amazonopensearchserviceDestinationDescription_indexRotationPeriod :: Lens.Lens' AmazonopensearchserviceDestinationDescription (Prelude.Maybe AmazonopensearchserviceIndexRotationPeriod)
amazonopensearchserviceDestinationDescription_indexRotationPeriod :: Lens'
  AmazonopensearchserviceDestinationDescription
  (Maybe AmazonopensearchserviceIndexRotationPeriod)
amazonopensearchserviceDestinationDescription_indexRotationPeriod = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AmazonopensearchserviceDestinationDescription' {Maybe AmazonopensearchserviceIndexRotationPeriod
indexRotationPeriod :: Maybe AmazonopensearchserviceIndexRotationPeriod
$sel:indexRotationPeriod:AmazonopensearchserviceDestinationDescription' :: AmazonopensearchserviceDestinationDescription
-> Maybe AmazonopensearchserviceIndexRotationPeriod
indexRotationPeriod} -> Maybe AmazonopensearchserviceIndexRotationPeriod
indexRotationPeriod) (\s :: AmazonopensearchserviceDestinationDescription
s@AmazonopensearchserviceDestinationDescription' {} Maybe AmazonopensearchserviceIndexRotationPeriod
a -> AmazonopensearchserviceDestinationDescription
s {$sel:indexRotationPeriod:AmazonopensearchserviceDestinationDescription' :: Maybe AmazonopensearchserviceIndexRotationPeriod
indexRotationPeriod = Maybe AmazonopensearchserviceIndexRotationPeriod
a} :: AmazonopensearchserviceDestinationDescription)

-- | Undocumented member.
amazonopensearchserviceDestinationDescription_processingConfiguration :: Lens.Lens' AmazonopensearchserviceDestinationDescription (Prelude.Maybe ProcessingConfiguration)
amazonopensearchserviceDestinationDescription_processingConfiguration :: Lens'
  AmazonopensearchserviceDestinationDescription
  (Maybe ProcessingConfiguration)
amazonopensearchserviceDestinationDescription_processingConfiguration = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AmazonopensearchserviceDestinationDescription' {Maybe ProcessingConfiguration
processingConfiguration :: Maybe ProcessingConfiguration
$sel:processingConfiguration:AmazonopensearchserviceDestinationDescription' :: AmazonopensearchserviceDestinationDescription
-> Maybe ProcessingConfiguration
processingConfiguration} -> Maybe ProcessingConfiguration
processingConfiguration) (\s :: AmazonopensearchserviceDestinationDescription
s@AmazonopensearchserviceDestinationDescription' {} Maybe ProcessingConfiguration
a -> AmazonopensearchserviceDestinationDescription
s {$sel:processingConfiguration:AmazonopensearchserviceDestinationDescription' :: Maybe ProcessingConfiguration
processingConfiguration = Maybe ProcessingConfiguration
a} :: AmazonopensearchserviceDestinationDescription)

-- | The Amazon OpenSearch Service retry options.
amazonopensearchserviceDestinationDescription_retryOptions :: Lens.Lens' AmazonopensearchserviceDestinationDescription (Prelude.Maybe AmazonopensearchserviceRetryOptions)
amazonopensearchserviceDestinationDescription_retryOptions :: Lens'
  AmazonopensearchserviceDestinationDescription
  (Maybe AmazonopensearchserviceRetryOptions)
amazonopensearchserviceDestinationDescription_retryOptions = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AmazonopensearchserviceDestinationDescription' {Maybe AmazonopensearchserviceRetryOptions
retryOptions :: Maybe AmazonopensearchserviceRetryOptions
$sel:retryOptions:AmazonopensearchserviceDestinationDescription' :: AmazonopensearchserviceDestinationDescription
-> Maybe AmazonopensearchserviceRetryOptions
retryOptions} -> Maybe AmazonopensearchserviceRetryOptions
retryOptions) (\s :: AmazonopensearchserviceDestinationDescription
s@AmazonopensearchserviceDestinationDescription' {} Maybe AmazonopensearchserviceRetryOptions
a -> AmazonopensearchserviceDestinationDescription
s {$sel:retryOptions:AmazonopensearchserviceDestinationDescription' :: Maybe AmazonopensearchserviceRetryOptions
retryOptions = Maybe AmazonopensearchserviceRetryOptions
a} :: AmazonopensearchserviceDestinationDescription)

-- | The Amazon Resource Name (ARN) of the Amazon Web Services credentials.
amazonopensearchserviceDestinationDescription_roleARN :: Lens.Lens' AmazonopensearchserviceDestinationDescription (Prelude.Maybe Prelude.Text)
amazonopensearchserviceDestinationDescription_roleARN :: Lens' AmazonopensearchserviceDestinationDescription (Maybe Text)
amazonopensearchserviceDestinationDescription_roleARN = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AmazonopensearchserviceDestinationDescription' {Maybe Text
roleARN :: Maybe Text
$sel:roleARN:AmazonopensearchserviceDestinationDescription' :: AmazonopensearchserviceDestinationDescription -> Maybe Text
roleARN} -> Maybe Text
roleARN) (\s :: AmazonopensearchserviceDestinationDescription
s@AmazonopensearchserviceDestinationDescription' {} Maybe Text
a -> AmazonopensearchserviceDestinationDescription
s {$sel:roleARN:AmazonopensearchserviceDestinationDescription' :: Maybe Text
roleARN = Maybe Text
a} :: AmazonopensearchserviceDestinationDescription)

-- | The Amazon S3 backup mode.
amazonopensearchserviceDestinationDescription_s3BackupMode :: Lens.Lens' AmazonopensearchserviceDestinationDescription (Prelude.Maybe AmazonopensearchserviceS3BackupMode)
amazonopensearchserviceDestinationDescription_s3BackupMode :: Lens'
  AmazonopensearchserviceDestinationDescription
  (Maybe AmazonopensearchserviceS3BackupMode)
amazonopensearchserviceDestinationDescription_s3BackupMode = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AmazonopensearchserviceDestinationDescription' {Maybe AmazonopensearchserviceS3BackupMode
s3BackupMode :: Maybe AmazonopensearchserviceS3BackupMode
$sel:s3BackupMode:AmazonopensearchserviceDestinationDescription' :: AmazonopensearchserviceDestinationDescription
-> Maybe AmazonopensearchserviceS3BackupMode
s3BackupMode} -> Maybe AmazonopensearchserviceS3BackupMode
s3BackupMode) (\s :: AmazonopensearchserviceDestinationDescription
s@AmazonopensearchserviceDestinationDescription' {} Maybe AmazonopensearchserviceS3BackupMode
a -> AmazonopensearchserviceDestinationDescription
s {$sel:s3BackupMode:AmazonopensearchserviceDestinationDescription' :: Maybe AmazonopensearchserviceS3BackupMode
s3BackupMode = Maybe AmazonopensearchserviceS3BackupMode
a} :: AmazonopensearchserviceDestinationDescription)

-- | Undocumented member.
amazonopensearchserviceDestinationDescription_s3DestinationDescription :: Lens.Lens' AmazonopensearchserviceDestinationDescription (Prelude.Maybe S3DestinationDescription)
amazonopensearchserviceDestinationDescription_s3DestinationDescription :: Lens'
  AmazonopensearchserviceDestinationDescription
  (Maybe S3DestinationDescription)
amazonopensearchserviceDestinationDescription_s3DestinationDescription = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AmazonopensearchserviceDestinationDescription' {Maybe S3DestinationDescription
s3DestinationDescription :: Maybe S3DestinationDescription
$sel:s3DestinationDescription:AmazonopensearchserviceDestinationDescription' :: AmazonopensearchserviceDestinationDescription
-> Maybe S3DestinationDescription
s3DestinationDescription} -> Maybe S3DestinationDescription
s3DestinationDescription) (\s :: AmazonopensearchserviceDestinationDescription
s@AmazonopensearchserviceDestinationDescription' {} Maybe S3DestinationDescription
a -> AmazonopensearchserviceDestinationDescription
s {$sel:s3DestinationDescription:AmazonopensearchserviceDestinationDescription' :: Maybe S3DestinationDescription
s3DestinationDescription = Maybe S3DestinationDescription
a} :: AmazonopensearchserviceDestinationDescription)

-- | The Amazon OpenSearch Service type name. This applies to Elasticsearch
-- 6.x and lower versions. For Elasticsearch 7.x and OpenSearch Service
-- 1.x, there\'s no value for TypeName.
amazonopensearchserviceDestinationDescription_typeName :: Lens.Lens' AmazonopensearchserviceDestinationDescription (Prelude.Maybe Prelude.Text)
amazonopensearchserviceDestinationDescription_typeName :: Lens' AmazonopensearchserviceDestinationDescription (Maybe Text)
amazonopensearchserviceDestinationDescription_typeName = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AmazonopensearchserviceDestinationDescription' {Maybe Text
typeName :: Maybe Text
$sel:typeName:AmazonopensearchserviceDestinationDescription' :: AmazonopensearchserviceDestinationDescription -> Maybe Text
typeName} -> Maybe Text
typeName) (\s :: AmazonopensearchserviceDestinationDescription
s@AmazonopensearchserviceDestinationDescription' {} Maybe Text
a -> AmazonopensearchserviceDestinationDescription
s {$sel:typeName:AmazonopensearchserviceDestinationDescription' :: Maybe Text
typeName = Maybe Text
a} :: AmazonopensearchserviceDestinationDescription)

-- | Undocumented member.
amazonopensearchserviceDestinationDescription_vpcConfigurationDescription :: Lens.Lens' AmazonopensearchserviceDestinationDescription (Prelude.Maybe VpcConfigurationDescription)
amazonopensearchserviceDestinationDescription_vpcConfigurationDescription :: Lens'
  AmazonopensearchserviceDestinationDescription
  (Maybe VpcConfigurationDescription)
amazonopensearchserviceDestinationDescription_vpcConfigurationDescription = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AmazonopensearchserviceDestinationDescription' {Maybe VpcConfigurationDescription
vpcConfigurationDescription :: Maybe VpcConfigurationDescription
$sel:vpcConfigurationDescription:AmazonopensearchserviceDestinationDescription' :: AmazonopensearchserviceDestinationDescription
-> Maybe VpcConfigurationDescription
vpcConfigurationDescription} -> Maybe VpcConfigurationDescription
vpcConfigurationDescription) (\s :: AmazonopensearchserviceDestinationDescription
s@AmazonopensearchserviceDestinationDescription' {} Maybe VpcConfigurationDescription
a -> AmazonopensearchserviceDestinationDescription
s {$sel:vpcConfigurationDescription:AmazonopensearchserviceDestinationDescription' :: Maybe VpcConfigurationDescription
vpcConfigurationDescription = Maybe VpcConfigurationDescription
a} :: AmazonopensearchserviceDestinationDescription)

instance
  Data.FromJSON
    AmazonopensearchserviceDestinationDescription
  where
  parseJSON :: Value -> Parser AmazonopensearchserviceDestinationDescription
parseJSON =
    forall a. String -> (Object -> Parser a) -> Value -> Parser a
Data.withObject
      String
"AmazonopensearchserviceDestinationDescription"
      ( \Object
x ->
          Maybe AmazonopensearchserviceBufferingHints
-> Maybe CloudWatchLoggingOptions
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe AmazonopensearchserviceIndexRotationPeriod
-> Maybe ProcessingConfiguration
-> Maybe AmazonopensearchserviceRetryOptions
-> Maybe Text
-> Maybe AmazonopensearchserviceS3BackupMode
-> Maybe S3DestinationDescription
-> Maybe Text
-> Maybe VpcConfigurationDescription
-> AmazonopensearchserviceDestinationDescription
AmazonopensearchserviceDestinationDescription'
            forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"BufferingHints")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"CloudWatchLoggingOptions")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"ClusterEndpoint")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"DomainARN")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"IndexName")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"IndexRotationPeriod")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"ProcessingConfiguration")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"RetryOptions")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"RoleARN")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"S3BackupMode")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"S3DestinationDescription")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"TypeName")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"VpcConfigurationDescription")
      )

instance
  Prelude.Hashable
    AmazonopensearchserviceDestinationDescription
  where
  hashWithSalt :: Int -> AmazonopensearchserviceDestinationDescription -> Int
hashWithSalt
    Int
_salt
    AmazonopensearchserviceDestinationDescription' {Maybe Text
Maybe AmazonopensearchserviceBufferingHints
Maybe AmazonopensearchserviceIndexRotationPeriod
Maybe AmazonopensearchserviceRetryOptions
Maybe AmazonopensearchserviceS3BackupMode
Maybe CloudWatchLoggingOptions
Maybe ProcessingConfiguration
Maybe S3DestinationDescription
Maybe VpcConfigurationDescription
vpcConfigurationDescription :: Maybe VpcConfigurationDescription
typeName :: Maybe Text
s3DestinationDescription :: Maybe S3DestinationDescription
s3BackupMode :: Maybe AmazonopensearchserviceS3BackupMode
roleARN :: Maybe Text
retryOptions :: Maybe AmazonopensearchserviceRetryOptions
processingConfiguration :: Maybe ProcessingConfiguration
indexRotationPeriod :: Maybe AmazonopensearchserviceIndexRotationPeriod
indexName :: Maybe Text
domainARN :: Maybe Text
clusterEndpoint :: Maybe Text
cloudWatchLoggingOptions :: Maybe CloudWatchLoggingOptions
bufferingHints :: Maybe AmazonopensearchserviceBufferingHints
$sel:vpcConfigurationDescription:AmazonopensearchserviceDestinationDescription' :: AmazonopensearchserviceDestinationDescription
-> Maybe VpcConfigurationDescription
$sel:typeName:AmazonopensearchserviceDestinationDescription' :: AmazonopensearchserviceDestinationDescription -> Maybe Text
$sel:s3DestinationDescription:AmazonopensearchserviceDestinationDescription' :: AmazonopensearchserviceDestinationDescription
-> Maybe S3DestinationDescription
$sel:s3BackupMode:AmazonopensearchserviceDestinationDescription' :: AmazonopensearchserviceDestinationDescription
-> Maybe AmazonopensearchserviceS3BackupMode
$sel:roleARN:AmazonopensearchserviceDestinationDescription' :: AmazonopensearchserviceDestinationDescription -> Maybe Text
$sel:retryOptions:AmazonopensearchserviceDestinationDescription' :: AmazonopensearchserviceDestinationDescription
-> Maybe AmazonopensearchserviceRetryOptions
$sel:processingConfiguration:AmazonopensearchserviceDestinationDescription' :: AmazonopensearchserviceDestinationDescription
-> Maybe ProcessingConfiguration
$sel:indexRotationPeriod:AmazonopensearchserviceDestinationDescription' :: AmazonopensearchserviceDestinationDescription
-> Maybe AmazonopensearchserviceIndexRotationPeriod
$sel:indexName:AmazonopensearchserviceDestinationDescription' :: AmazonopensearchserviceDestinationDescription -> Maybe Text
$sel:domainARN:AmazonopensearchserviceDestinationDescription' :: AmazonopensearchserviceDestinationDescription -> Maybe Text
$sel:clusterEndpoint:AmazonopensearchserviceDestinationDescription' :: AmazonopensearchserviceDestinationDescription -> Maybe Text
$sel:cloudWatchLoggingOptions:AmazonopensearchserviceDestinationDescription' :: AmazonopensearchserviceDestinationDescription
-> Maybe CloudWatchLoggingOptions
$sel:bufferingHints:AmazonopensearchserviceDestinationDescription' :: AmazonopensearchserviceDestinationDescription
-> Maybe AmazonopensearchserviceBufferingHints
..} =
      Int
_salt
        forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe AmazonopensearchserviceBufferingHints
bufferingHints
        forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe CloudWatchLoggingOptions
cloudWatchLoggingOptions
        forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
clusterEndpoint
        forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
domainARN
        forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
indexName
        forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe AmazonopensearchserviceIndexRotationPeriod
indexRotationPeriod
        forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe ProcessingConfiguration
processingConfiguration
        forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe AmazonopensearchserviceRetryOptions
retryOptions
        forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
roleARN
        forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe AmazonopensearchserviceS3BackupMode
s3BackupMode
        forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe S3DestinationDescription
s3DestinationDescription
        forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
typeName
        forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe VpcConfigurationDescription
vpcConfigurationDescription

instance
  Prelude.NFData
    AmazonopensearchserviceDestinationDescription
  where
  rnf :: AmazonopensearchserviceDestinationDescription -> ()
rnf
    AmazonopensearchserviceDestinationDescription' {Maybe Text
Maybe AmazonopensearchserviceBufferingHints
Maybe AmazonopensearchserviceIndexRotationPeriod
Maybe AmazonopensearchserviceRetryOptions
Maybe AmazonopensearchserviceS3BackupMode
Maybe CloudWatchLoggingOptions
Maybe ProcessingConfiguration
Maybe S3DestinationDescription
Maybe VpcConfigurationDescription
vpcConfigurationDescription :: Maybe VpcConfigurationDescription
typeName :: Maybe Text
s3DestinationDescription :: Maybe S3DestinationDescription
s3BackupMode :: Maybe AmazonopensearchserviceS3BackupMode
roleARN :: Maybe Text
retryOptions :: Maybe AmazonopensearchserviceRetryOptions
processingConfiguration :: Maybe ProcessingConfiguration
indexRotationPeriod :: Maybe AmazonopensearchserviceIndexRotationPeriod
indexName :: Maybe Text
domainARN :: Maybe Text
clusterEndpoint :: Maybe Text
cloudWatchLoggingOptions :: Maybe CloudWatchLoggingOptions
bufferingHints :: Maybe AmazonopensearchserviceBufferingHints
$sel:vpcConfigurationDescription:AmazonopensearchserviceDestinationDescription' :: AmazonopensearchserviceDestinationDescription
-> Maybe VpcConfigurationDescription
$sel:typeName:AmazonopensearchserviceDestinationDescription' :: AmazonopensearchserviceDestinationDescription -> Maybe Text
$sel:s3DestinationDescription:AmazonopensearchserviceDestinationDescription' :: AmazonopensearchserviceDestinationDescription
-> Maybe S3DestinationDescription
$sel:s3BackupMode:AmazonopensearchserviceDestinationDescription' :: AmazonopensearchserviceDestinationDescription
-> Maybe AmazonopensearchserviceS3BackupMode
$sel:roleARN:AmazonopensearchserviceDestinationDescription' :: AmazonopensearchserviceDestinationDescription -> Maybe Text
$sel:retryOptions:AmazonopensearchserviceDestinationDescription' :: AmazonopensearchserviceDestinationDescription
-> Maybe AmazonopensearchserviceRetryOptions
$sel:processingConfiguration:AmazonopensearchserviceDestinationDescription' :: AmazonopensearchserviceDestinationDescription
-> Maybe ProcessingConfiguration
$sel:indexRotationPeriod:AmazonopensearchserviceDestinationDescription' :: AmazonopensearchserviceDestinationDescription
-> Maybe AmazonopensearchserviceIndexRotationPeriod
$sel:indexName:AmazonopensearchserviceDestinationDescription' :: AmazonopensearchserviceDestinationDescription -> Maybe Text
$sel:domainARN:AmazonopensearchserviceDestinationDescription' :: AmazonopensearchserviceDestinationDescription -> Maybe Text
$sel:clusterEndpoint:AmazonopensearchserviceDestinationDescription' :: AmazonopensearchserviceDestinationDescription -> Maybe Text
$sel:cloudWatchLoggingOptions:AmazonopensearchserviceDestinationDescription' :: AmazonopensearchserviceDestinationDescription
-> Maybe CloudWatchLoggingOptions
$sel:bufferingHints:AmazonopensearchserviceDestinationDescription' :: AmazonopensearchserviceDestinationDescription
-> Maybe AmazonopensearchserviceBufferingHints
..} =
      forall a. NFData a => a -> ()
Prelude.rnf Maybe AmazonopensearchserviceBufferingHints
bufferingHints
        seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe CloudWatchLoggingOptions
cloudWatchLoggingOptions
        seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
clusterEndpoint
        seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
domainARN
        seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
indexName
        seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe AmazonopensearchserviceIndexRotationPeriod
indexRotationPeriod
        seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe ProcessingConfiguration
processingConfiguration
        seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe AmazonopensearchserviceRetryOptions
retryOptions
        seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
roleARN
        seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe AmazonopensearchserviceS3BackupMode
s3BackupMode
        seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe S3DestinationDescription
s3DestinationDescription
        seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
typeName
        seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe VpcConfigurationDescription
vpcConfigurationDescription