{-# 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.HttpEndpointDestinationDescription
-- Copyright   : (c) 2013-2021 Brendan Hay
-- License     : Mozilla Public License, v. 2.0.
-- Maintainer  : Brendan Hay <brendan.g.hay+amazonka@gmail.com>
-- Stability   : auto-generated
-- Portability : non-portable (GHC extensions)
module Amazonka.Firehose.Types.HttpEndpointDestinationDescription where

import qualified Amazonka.Core as Core
import Amazonka.Firehose.Types.CloudWatchLoggingOptions
import Amazonka.Firehose.Types.HttpEndpointBufferingHints
import Amazonka.Firehose.Types.HttpEndpointDescription
import Amazonka.Firehose.Types.HttpEndpointRequestConfiguration
import Amazonka.Firehose.Types.HttpEndpointRetryOptions
import Amazonka.Firehose.Types.HttpEndpointS3BackupMode
import Amazonka.Firehose.Types.ProcessingConfiguration
import Amazonka.Firehose.Types.S3DestinationDescription
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude

-- | Describes the HTTP endpoint destination.
--
-- /See:/ 'newHttpEndpointDestinationDescription' smart constructor.
data HttpEndpointDestinationDescription = HttpEndpointDestinationDescription'
  { -- | Describes the S3 bucket backup options for the data that Kinesis
    -- Firehose delivers to the HTTP endpoint destination. You can back up all
    -- documents (@AllData@) or only the documents that Kinesis Data Firehose
    -- could not deliver to the specified HTTP endpoint destination
    -- (@FailedDataOnly@).
    HttpEndpointDestinationDescription
-> Maybe HttpEndpointS3BackupMode
s3BackupMode :: Prelude.Maybe HttpEndpointS3BackupMode,
    HttpEndpointDestinationDescription
-> Maybe CloudWatchLoggingOptions
cloudWatchLoggingOptions :: Prelude.Maybe CloudWatchLoggingOptions,
    HttpEndpointDestinationDescription
-> Maybe S3DestinationDescription
s3DestinationDescription :: Prelude.Maybe S3DestinationDescription,
    -- | Describes buffering options that can be applied to the data before it is
    -- delivered to the HTTPS endpoint destination. Kinesis Data Firehose teats
    -- these options as hints, and it might choose to use more optimal values.
    -- The @SizeInMBs@ and @IntervalInSeconds@ parameters are optional.
    -- However, if specify a value for one of them, you must also provide a
    -- value for the other.
    HttpEndpointDestinationDescription
-> Maybe HttpEndpointBufferingHints
bufferingHints :: Prelude.Maybe HttpEndpointBufferingHints,
    -- | Describes the retry behavior in case Kinesis Data Firehose is unable to
    -- deliver data to the specified HTTP endpoint destination, or if it
    -- doesn\'t receive a valid acknowledgment of receipt from the specified
    -- HTTP endpoint destination.
    HttpEndpointDestinationDescription
-> Maybe HttpEndpointRetryOptions
retryOptions :: Prelude.Maybe HttpEndpointRetryOptions,
    -- | The configuration of the specified HTTP endpoint destination.
    HttpEndpointDestinationDescription -> Maybe HttpEndpointDescription
endpointConfiguration :: Prelude.Maybe HttpEndpointDescription,
    HttpEndpointDestinationDescription -> Maybe ProcessingConfiguration
processingConfiguration :: Prelude.Maybe ProcessingConfiguration,
    -- | The configuration of request sent to the HTTP endpoint specified as the
    -- destination.
    HttpEndpointDestinationDescription
-> Maybe HttpEndpointRequestConfiguration
requestConfiguration :: Prelude.Maybe HttpEndpointRequestConfiguration,
    -- | Kinesis Data Firehose uses this IAM role for all the permissions that
    -- the delivery stream needs.
    HttpEndpointDestinationDescription -> Maybe Text
roleARN :: Prelude.Maybe Prelude.Text
  }
  deriving (HttpEndpointDestinationDescription
-> HttpEndpointDestinationDescription -> Bool
(HttpEndpointDestinationDescription
 -> HttpEndpointDestinationDescription -> Bool)
-> (HttpEndpointDestinationDescription
    -> HttpEndpointDestinationDescription -> Bool)
-> Eq HttpEndpointDestinationDescription
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: HttpEndpointDestinationDescription
-> HttpEndpointDestinationDescription -> Bool
$c/= :: HttpEndpointDestinationDescription
-> HttpEndpointDestinationDescription -> Bool
== :: HttpEndpointDestinationDescription
-> HttpEndpointDestinationDescription -> Bool
$c== :: HttpEndpointDestinationDescription
-> HttpEndpointDestinationDescription -> Bool
Prelude.Eq, Int -> HttpEndpointDestinationDescription -> ShowS
[HttpEndpointDestinationDescription] -> ShowS
HttpEndpointDestinationDescription -> String
(Int -> HttpEndpointDestinationDescription -> ShowS)
-> (HttpEndpointDestinationDescription -> String)
-> ([HttpEndpointDestinationDescription] -> ShowS)
-> Show HttpEndpointDestinationDescription
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [HttpEndpointDestinationDescription] -> ShowS
$cshowList :: [HttpEndpointDestinationDescription] -> ShowS
show :: HttpEndpointDestinationDescription -> String
$cshow :: HttpEndpointDestinationDescription -> String
showsPrec :: Int -> HttpEndpointDestinationDescription -> ShowS
$cshowsPrec :: Int -> HttpEndpointDestinationDescription -> ShowS
Prelude.Show, (forall x.
 HttpEndpointDestinationDescription
 -> Rep HttpEndpointDestinationDescription x)
-> (forall x.
    Rep HttpEndpointDestinationDescription x
    -> HttpEndpointDestinationDescription)
-> Generic HttpEndpointDestinationDescription
forall x.
Rep HttpEndpointDestinationDescription x
-> HttpEndpointDestinationDescription
forall x.
HttpEndpointDestinationDescription
-> Rep HttpEndpointDestinationDescription x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep HttpEndpointDestinationDescription x
-> HttpEndpointDestinationDescription
$cfrom :: forall x.
HttpEndpointDestinationDescription
-> Rep HttpEndpointDestinationDescription x
Prelude.Generic)

-- |
-- Create a value of 'HttpEndpointDestinationDescription' 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:
--
-- 's3BackupMode', 'httpEndpointDestinationDescription_s3BackupMode' - Describes the S3 bucket backup options for the data that Kinesis
-- Firehose delivers to the HTTP endpoint destination. You can back up all
-- documents (@AllData@) or only the documents that Kinesis Data Firehose
-- could not deliver to the specified HTTP endpoint destination
-- (@FailedDataOnly@).
--
-- 'cloudWatchLoggingOptions', 'httpEndpointDestinationDescription_cloudWatchLoggingOptions' - Undocumented member.
--
-- 's3DestinationDescription', 'httpEndpointDestinationDescription_s3DestinationDescription' - Undocumented member.
--
-- 'bufferingHints', 'httpEndpointDestinationDescription_bufferingHints' - Describes buffering options that can be applied to the data before it is
-- delivered to the HTTPS endpoint destination. Kinesis Data Firehose teats
-- these options as hints, and it might choose to use more optimal values.
-- The @SizeInMBs@ and @IntervalInSeconds@ parameters are optional.
-- However, if specify a value for one of them, you must also provide a
-- value for the other.
--
-- 'retryOptions', 'httpEndpointDestinationDescription_retryOptions' - Describes the retry behavior in case Kinesis Data Firehose is unable to
-- deliver data to the specified HTTP endpoint destination, or if it
-- doesn\'t receive a valid acknowledgment of receipt from the specified
-- HTTP endpoint destination.
--
-- 'endpointConfiguration', 'httpEndpointDestinationDescription_endpointConfiguration' - The configuration of the specified HTTP endpoint destination.
--
-- 'processingConfiguration', 'httpEndpointDestinationDescription_processingConfiguration' - Undocumented member.
--
-- 'requestConfiguration', 'httpEndpointDestinationDescription_requestConfiguration' - The configuration of request sent to the HTTP endpoint specified as the
-- destination.
--
-- 'roleARN', 'httpEndpointDestinationDescription_roleARN' - Kinesis Data Firehose uses this IAM role for all the permissions that
-- the delivery stream needs.
newHttpEndpointDestinationDescription ::
  HttpEndpointDestinationDescription
newHttpEndpointDestinationDescription :: HttpEndpointDestinationDescription
newHttpEndpointDestinationDescription =
  HttpEndpointDestinationDescription' :: Maybe HttpEndpointS3BackupMode
-> Maybe CloudWatchLoggingOptions
-> Maybe S3DestinationDescription
-> Maybe HttpEndpointBufferingHints
-> Maybe HttpEndpointRetryOptions
-> Maybe HttpEndpointDescription
-> Maybe ProcessingConfiguration
-> Maybe HttpEndpointRequestConfiguration
-> Maybe Text
-> HttpEndpointDestinationDescription
HttpEndpointDestinationDescription'
    { $sel:s3BackupMode:HttpEndpointDestinationDescription' :: Maybe HttpEndpointS3BackupMode
s3BackupMode =
        Maybe HttpEndpointS3BackupMode
forall a. Maybe a
Prelude.Nothing,
      $sel:cloudWatchLoggingOptions:HttpEndpointDestinationDescription' :: Maybe CloudWatchLoggingOptions
cloudWatchLoggingOptions =
        Maybe CloudWatchLoggingOptions
forall a. Maybe a
Prelude.Nothing,
      $sel:s3DestinationDescription:HttpEndpointDestinationDescription' :: Maybe S3DestinationDescription
s3DestinationDescription =
        Maybe S3DestinationDescription
forall a. Maybe a
Prelude.Nothing,
      $sel:bufferingHints:HttpEndpointDestinationDescription' :: Maybe HttpEndpointBufferingHints
bufferingHints = Maybe HttpEndpointBufferingHints
forall a. Maybe a
Prelude.Nothing,
      $sel:retryOptions:HttpEndpointDestinationDescription' :: Maybe HttpEndpointRetryOptions
retryOptions = Maybe HttpEndpointRetryOptions
forall a. Maybe a
Prelude.Nothing,
      $sel:endpointConfiguration:HttpEndpointDestinationDescription' :: Maybe HttpEndpointDescription
endpointConfiguration = Maybe HttpEndpointDescription
forall a. Maybe a
Prelude.Nothing,
      $sel:processingConfiguration:HttpEndpointDestinationDescription' :: Maybe ProcessingConfiguration
processingConfiguration =
        Maybe ProcessingConfiguration
forall a. Maybe a
Prelude.Nothing,
      $sel:requestConfiguration:HttpEndpointDestinationDescription' :: Maybe HttpEndpointRequestConfiguration
requestConfiguration = Maybe HttpEndpointRequestConfiguration
forall a. Maybe a
Prelude.Nothing,
      $sel:roleARN:HttpEndpointDestinationDescription' :: Maybe Text
roleARN = Maybe Text
forall a. Maybe a
Prelude.Nothing
    }

-- | Describes the S3 bucket backup options for the data that Kinesis
-- Firehose delivers to the HTTP endpoint destination. You can back up all
-- documents (@AllData@) or only the documents that Kinesis Data Firehose
-- could not deliver to the specified HTTP endpoint destination
-- (@FailedDataOnly@).
httpEndpointDestinationDescription_s3BackupMode :: Lens.Lens' HttpEndpointDestinationDescription (Prelude.Maybe HttpEndpointS3BackupMode)
httpEndpointDestinationDescription_s3BackupMode :: (Maybe HttpEndpointS3BackupMode
 -> f (Maybe HttpEndpointS3BackupMode))
-> HttpEndpointDestinationDescription
-> f HttpEndpointDestinationDescription
httpEndpointDestinationDescription_s3BackupMode = (HttpEndpointDestinationDescription
 -> Maybe HttpEndpointS3BackupMode)
-> (HttpEndpointDestinationDescription
    -> Maybe HttpEndpointS3BackupMode
    -> HttpEndpointDestinationDescription)
-> Lens
     HttpEndpointDestinationDescription
     HttpEndpointDestinationDescription
     (Maybe HttpEndpointS3BackupMode)
     (Maybe HttpEndpointS3BackupMode)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\HttpEndpointDestinationDescription' {Maybe HttpEndpointS3BackupMode
s3BackupMode :: Maybe HttpEndpointS3BackupMode
$sel:s3BackupMode:HttpEndpointDestinationDescription' :: HttpEndpointDestinationDescription
-> Maybe HttpEndpointS3BackupMode
s3BackupMode} -> Maybe HttpEndpointS3BackupMode
s3BackupMode) (\s :: HttpEndpointDestinationDescription
s@HttpEndpointDestinationDescription' {} Maybe HttpEndpointS3BackupMode
a -> HttpEndpointDestinationDescription
s {$sel:s3BackupMode:HttpEndpointDestinationDescription' :: Maybe HttpEndpointS3BackupMode
s3BackupMode = Maybe HttpEndpointS3BackupMode
a} :: HttpEndpointDestinationDescription)

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

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

-- | Describes buffering options that can be applied to the data before it is
-- delivered to the HTTPS endpoint destination. Kinesis Data Firehose teats
-- these options as hints, and it might choose to use more optimal values.
-- The @SizeInMBs@ and @IntervalInSeconds@ parameters are optional.
-- However, if specify a value for one of them, you must also provide a
-- value for the other.
httpEndpointDestinationDescription_bufferingHints :: Lens.Lens' HttpEndpointDestinationDescription (Prelude.Maybe HttpEndpointBufferingHints)
httpEndpointDestinationDescription_bufferingHints :: (Maybe HttpEndpointBufferingHints
 -> f (Maybe HttpEndpointBufferingHints))
-> HttpEndpointDestinationDescription
-> f HttpEndpointDestinationDescription
httpEndpointDestinationDescription_bufferingHints = (HttpEndpointDestinationDescription
 -> Maybe HttpEndpointBufferingHints)
-> (HttpEndpointDestinationDescription
    -> Maybe HttpEndpointBufferingHints
    -> HttpEndpointDestinationDescription)
-> Lens
     HttpEndpointDestinationDescription
     HttpEndpointDestinationDescription
     (Maybe HttpEndpointBufferingHints)
     (Maybe HttpEndpointBufferingHints)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\HttpEndpointDestinationDescription' {Maybe HttpEndpointBufferingHints
bufferingHints :: Maybe HttpEndpointBufferingHints
$sel:bufferingHints:HttpEndpointDestinationDescription' :: HttpEndpointDestinationDescription
-> Maybe HttpEndpointBufferingHints
bufferingHints} -> Maybe HttpEndpointBufferingHints
bufferingHints) (\s :: HttpEndpointDestinationDescription
s@HttpEndpointDestinationDescription' {} Maybe HttpEndpointBufferingHints
a -> HttpEndpointDestinationDescription
s {$sel:bufferingHints:HttpEndpointDestinationDescription' :: Maybe HttpEndpointBufferingHints
bufferingHints = Maybe HttpEndpointBufferingHints
a} :: HttpEndpointDestinationDescription)

-- | Describes the retry behavior in case Kinesis Data Firehose is unable to
-- deliver data to the specified HTTP endpoint destination, or if it
-- doesn\'t receive a valid acknowledgment of receipt from the specified
-- HTTP endpoint destination.
httpEndpointDestinationDescription_retryOptions :: Lens.Lens' HttpEndpointDestinationDescription (Prelude.Maybe HttpEndpointRetryOptions)
httpEndpointDestinationDescription_retryOptions :: (Maybe HttpEndpointRetryOptions
 -> f (Maybe HttpEndpointRetryOptions))
-> HttpEndpointDestinationDescription
-> f HttpEndpointDestinationDescription
httpEndpointDestinationDescription_retryOptions = (HttpEndpointDestinationDescription
 -> Maybe HttpEndpointRetryOptions)
-> (HttpEndpointDestinationDescription
    -> Maybe HttpEndpointRetryOptions
    -> HttpEndpointDestinationDescription)
-> Lens
     HttpEndpointDestinationDescription
     HttpEndpointDestinationDescription
     (Maybe HttpEndpointRetryOptions)
     (Maybe HttpEndpointRetryOptions)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\HttpEndpointDestinationDescription' {Maybe HttpEndpointRetryOptions
retryOptions :: Maybe HttpEndpointRetryOptions
$sel:retryOptions:HttpEndpointDestinationDescription' :: HttpEndpointDestinationDescription
-> Maybe HttpEndpointRetryOptions
retryOptions} -> Maybe HttpEndpointRetryOptions
retryOptions) (\s :: HttpEndpointDestinationDescription
s@HttpEndpointDestinationDescription' {} Maybe HttpEndpointRetryOptions
a -> HttpEndpointDestinationDescription
s {$sel:retryOptions:HttpEndpointDestinationDescription' :: Maybe HttpEndpointRetryOptions
retryOptions = Maybe HttpEndpointRetryOptions
a} :: HttpEndpointDestinationDescription)

-- | The configuration of the specified HTTP endpoint destination.
httpEndpointDestinationDescription_endpointConfiguration :: Lens.Lens' HttpEndpointDestinationDescription (Prelude.Maybe HttpEndpointDescription)
httpEndpointDestinationDescription_endpointConfiguration :: (Maybe HttpEndpointDescription
 -> f (Maybe HttpEndpointDescription))
-> HttpEndpointDestinationDescription
-> f HttpEndpointDestinationDescription
httpEndpointDestinationDescription_endpointConfiguration = (HttpEndpointDestinationDescription
 -> Maybe HttpEndpointDescription)
-> (HttpEndpointDestinationDescription
    -> Maybe HttpEndpointDescription
    -> HttpEndpointDestinationDescription)
-> Lens
     HttpEndpointDestinationDescription
     HttpEndpointDestinationDescription
     (Maybe HttpEndpointDescription)
     (Maybe HttpEndpointDescription)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\HttpEndpointDestinationDescription' {Maybe HttpEndpointDescription
endpointConfiguration :: Maybe HttpEndpointDescription
$sel:endpointConfiguration:HttpEndpointDestinationDescription' :: HttpEndpointDestinationDescription -> Maybe HttpEndpointDescription
endpointConfiguration} -> Maybe HttpEndpointDescription
endpointConfiguration) (\s :: HttpEndpointDestinationDescription
s@HttpEndpointDestinationDescription' {} Maybe HttpEndpointDescription
a -> HttpEndpointDestinationDescription
s {$sel:endpointConfiguration:HttpEndpointDestinationDescription' :: Maybe HttpEndpointDescription
endpointConfiguration = Maybe HttpEndpointDescription
a} :: HttpEndpointDestinationDescription)

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

-- | The configuration of request sent to the HTTP endpoint specified as the
-- destination.
httpEndpointDestinationDescription_requestConfiguration :: Lens.Lens' HttpEndpointDestinationDescription (Prelude.Maybe HttpEndpointRequestConfiguration)
httpEndpointDestinationDescription_requestConfiguration :: (Maybe HttpEndpointRequestConfiguration
 -> f (Maybe HttpEndpointRequestConfiguration))
-> HttpEndpointDestinationDescription
-> f HttpEndpointDestinationDescription
httpEndpointDestinationDescription_requestConfiguration = (HttpEndpointDestinationDescription
 -> Maybe HttpEndpointRequestConfiguration)
-> (HttpEndpointDestinationDescription
    -> Maybe HttpEndpointRequestConfiguration
    -> HttpEndpointDestinationDescription)
-> Lens
     HttpEndpointDestinationDescription
     HttpEndpointDestinationDescription
     (Maybe HttpEndpointRequestConfiguration)
     (Maybe HttpEndpointRequestConfiguration)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\HttpEndpointDestinationDescription' {Maybe HttpEndpointRequestConfiguration
requestConfiguration :: Maybe HttpEndpointRequestConfiguration
$sel:requestConfiguration:HttpEndpointDestinationDescription' :: HttpEndpointDestinationDescription
-> Maybe HttpEndpointRequestConfiguration
requestConfiguration} -> Maybe HttpEndpointRequestConfiguration
requestConfiguration) (\s :: HttpEndpointDestinationDescription
s@HttpEndpointDestinationDescription' {} Maybe HttpEndpointRequestConfiguration
a -> HttpEndpointDestinationDescription
s {$sel:requestConfiguration:HttpEndpointDestinationDescription' :: Maybe HttpEndpointRequestConfiguration
requestConfiguration = Maybe HttpEndpointRequestConfiguration
a} :: HttpEndpointDestinationDescription)

-- | Kinesis Data Firehose uses this IAM role for all the permissions that
-- the delivery stream needs.
httpEndpointDestinationDescription_roleARN :: Lens.Lens' HttpEndpointDestinationDescription (Prelude.Maybe Prelude.Text)
httpEndpointDestinationDescription_roleARN :: (Maybe Text -> f (Maybe Text))
-> HttpEndpointDestinationDescription
-> f HttpEndpointDestinationDescription
httpEndpointDestinationDescription_roleARN = (HttpEndpointDestinationDescription -> Maybe Text)
-> (HttpEndpointDestinationDescription
    -> Maybe Text -> HttpEndpointDestinationDescription)
-> Lens
     HttpEndpointDestinationDescription
     HttpEndpointDestinationDescription
     (Maybe Text)
     (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\HttpEndpointDestinationDescription' {Maybe Text
roleARN :: Maybe Text
$sel:roleARN:HttpEndpointDestinationDescription' :: HttpEndpointDestinationDescription -> Maybe Text
roleARN} -> Maybe Text
roleARN) (\s :: HttpEndpointDestinationDescription
s@HttpEndpointDestinationDescription' {} Maybe Text
a -> HttpEndpointDestinationDescription
s {$sel:roleARN:HttpEndpointDestinationDescription' :: Maybe Text
roleARN = Maybe Text
a} :: HttpEndpointDestinationDescription)

instance
  Core.FromJSON
    HttpEndpointDestinationDescription
  where
  parseJSON :: Value -> Parser HttpEndpointDestinationDescription
parseJSON =
    String
-> (Object -> Parser HttpEndpointDestinationDescription)
-> Value
-> Parser HttpEndpointDestinationDescription
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Core.withObject
      String
"HttpEndpointDestinationDescription"
      ( \Object
x ->
          Maybe HttpEndpointS3BackupMode
-> Maybe CloudWatchLoggingOptions
-> Maybe S3DestinationDescription
-> Maybe HttpEndpointBufferingHints
-> Maybe HttpEndpointRetryOptions
-> Maybe HttpEndpointDescription
-> Maybe ProcessingConfiguration
-> Maybe HttpEndpointRequestConfiguration
-> Maybe Text
-> HttpEndpointDestinationDescription
HttpEndpointDestinationDescription'
            (Maybe HttpEndpointS3BackupMode
 -> Maybe CloudWatchLoggingOptions
 -> Maybe S3DestinationDescription
 -> Maybe HttpEndpointBufferingHints
 -> Maybe HttpEndpointRetryOptions
 -> Maybe HttpEndpointDescription
 -> Maybe ProcessingConfiguration
 -> Maybe HttpEndpointRequestConfiguration
 -> Maybe Text
 -> HttpEndpointDestinationDescription)
-> Parser (Maybe HttpEndpointS3BackupMode)
-> Parser
     (Maybe CloudWatchLoggingOptions
      -> Maybe S3DestinationDescription
      -> Maybe HttpEndpointBufferingHints
      -> Maybe HttpEndpointRetryOptions
      -> Maybe HttpEndpointDescription
      -> Maybe ProcessingConfiguration
      -> Maybe HttpEndpointRequestConfiguration
      -> Maybe Text
      -> HttpEndpointDestinationDescription)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x Object -> Text -> Parser (Maybe HttpEndpointS3BackupMode)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"S3BackupMode")
            Parser
  (Maybe CloudWatchLoggingOptions
   -> Maybe S3DestinationDescription
   -> Maybe HttpEndpointBufferingHints
   -> Maybe HttpEndpointRetryOptions
   -> Maybe HttpEndpointDescription
   -> Maybe ProcessingConfiguration
   -> Maybe HttpEndpointRequestConfiguration
   -> Maybe Text
   -> HttpEndpointDestinationDescription)
-> Parser (Maybe CloudWatchLoggingOptions)
-> Parser
     (Maybe S3DestinationDescription
      -> Maybe HttpEndpointBufferingHints
      -> Maybe HttpEndpointRetryOptions
      -> Maybe HttpEndpointDescription
      -> Maybe ProcessingConfiguration
      -> Maybe HttpEndpointRequestConfiguration
      -> Maybe Text
      -> HttpEndpointDestinationDescription)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe CloudWatchLoggingOptions)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"CloudWatchLoggingOptions")
            Parser
  (Maybe S3DestinationDescription
   -> Maybe HttpEndpointBufferingHints
   -> Maybe HttpEndpointRetryOptions
   -> Maybe HttpEndpointDescription
   -> Maybe ProcessingConfiguration
   -> Maybe HttpEndpointRequestConfiguration
   -> Maybe Text
   -> HttpEndpointDestinationDescription)
-> Parser (Maybe S3DestinationDescription)
-> Parser
     (Maybe HttpEndpointBufferingHints
      -> Maybe HttpEndpointRetryOptions
      -> Maybe HttpEndpointDescription
      -> Maybe ProcessingConfiguration
      -> Maybe HttpEndpointRequestConfiguration
      -> Maybe Text
      -> HttpEndpointDestinationDescription)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe S3DestinationDescription)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"S3DestinationDescription")
            Parser
  (Maybe HttpEndpointBufferingHints
   -> Maybe HttpEndpointRetryOptions
   -> Maybe HttpEndpointDescription
   -> Maybe ProcessingConfiguration
   -> Maybe HttpEndpointRequestConfiguration
   -> Maybe Text
   -> HttpEndpointDestinationDescription)
-> Parser (Maybe HttpEndpointBufferingHints)
-> Parser
     (Maybe HttpEndpointRetryOptions
      -> Maybe HttpEndpointDescription
      -> Maybe ProcessingConfiguration
      -> Maybe HttpEndpointRequestConfiguration
      -> Maybe Text
      -> HttpEndpointDestinationDescription)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe HttpEndpointBufferingHints)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"BufferingHints")
            Parser
  (Maybe HttpEndpointRetryOptions
   -> Maybe HttpEndpointDescription
   -> Maybe ProcessingConfiguration
   -> Maybe HttpEndpointRequestConfiguration
   -> Maybe Text
   -> HttpEndpointDestinationDescription)
-> Parser (Maybe HttpEndpointRetryOptions)
-> Parser
     (Maybe HttpEndpointDescription
      -> Maybe ProcessingConfiguration
      -> Maybe HttpEndpointRequestConfiguration
      -> Maybe Text
      -> HttpEndpointDestinationDescription)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe HttpEndpointRetryOptions)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"RetryOptions")
            Parser
  (Maybe HttpEndpointDescription
   -> Maybe ProcessingConfiguration
   -> Maybe HttpEndpointRequestConfiguration
   -> Maybe Text
   -> HttpEndpointDestinationDescription)
-> Parser (Maybe HttpEndpointDescription)
-> Parser
     (Maybe ProcessingConfiguration
      -> Maybe HttpEndpointRequestConfiguration
      -> Maybe Text
      -> HttpEndpointDestinationDescription)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe HttpEndpointDescription)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"EndpointConfiguration")
            Parser
  (Maybe ProcessingConfiguration
   -> Maybe HttpEndpointRequestConfiguration
   -> Maybe Text
   -> HttpEndpointDestinationDescription)
-> Parser (Maybe ProcessingConfiguration)
-> Parser
     (Maybe HttpEndpointRequestConfiguration
      -> Maybe Text -> HttpEndpointDestinationDescription)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe ProcessingConfiguration)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"ProcessingConfiguration")
            Parser
  (Maybe HttpEndpointRequestConfiguration
   -> Maybe Text -> HttpEndpointDestinationDescription)
-> Parser (Maybe HttpEndpointRequestConfiguration)
-> Parser (Maybe Text -> HttpEndpointDestinationDescription)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe HttpEndpointRequestConfiguration)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"RequestConfiguration")
            Parser (Maybe Text -> HttpEndpointDestinationDescription)
-> Parser (Maybe Text) -> Parser HttpEndpointDestinationDescription
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"RoleARN")
      )

instance
  Prelude.Hashable
    HttpEndpointDestinationDescription

instance
  Prelude.NFData
    HttpEndpointDestinationDescription