{-# 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.MwAA.Types.Environment
-- 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.MwAA.Types.Environment where

import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import Amazonka.MwAA.Types.EnvironmentStatus
import Amazonka.MwAA.Types.LastUpdate
import Amazonka.MwAA.Types.LoggingConfiguration
import Amazonka.MwAA.Types.NetworkConfiguration
import Amazonka.MwAA.Types.WebserverAccessMode
import qualified Amazonka.Prelude as Prelude

-- | The Amazon Managed Workflows for Apache Airflow (MWAA) environment.
--
-- /See:/ 'newEnvironment' smart constructor.
data Environment = Environment'
  { -- | The Amazon Resource Name (ARN) for the service-linked role of the
    -- environment. To learn more, see
    -- <https://docs.aws.amazon.com/mwaa/latest/userguide/mwaa-slr.html Amazon MWAA Service-linked role>.
    Environment -> Maybe Text
serviceRoleArn :: Prelude.Maybe Prelude.Text,
    -- | The number of Apache Airflow schedulers that run in your Amazon MWAA
    -- environment.
    Environment -> Maybe Int
schedulers :: Prelude.Maybe Prelude.Int,
    -- | The status of the Amazon MWAA environment. Valid values:
    --
    -- -   @CREATING@ - Indicates the request to create the environment is in
    --     progress.
    --
    -- -   @CREATE_FAILED@ - Indicates the request to create the environment
    --     failed, and the environment could not be created.
    --
    -- -   @AVAILABLE@ - Indicates the request was successful and the
    --     environment is ready to use.
    --
    -- -   @UPDATING@ - Indicates the request to update the environment is in
    --     progress.
    --
    -- -   @DELETING@ - Indicates the request to delete the environment is in
    --     progress.
    --
    -- -   @DELETED@ - Indicates the request to delete the environment is
    --     complete, and the environment has been deleted.
    --
    -- -   @UNAVAILABLE@ - Indicates the request failed, but the environment
    --     was unable to rollback and is not in a stable state.
    --
    -- -   @UPDATE_FAILED@ - Indicates the request to update the environment
    --     failed, and the environment has rolled back successfully and is
    --     ready to use.
    --
    -- We recommend reviewing our troubleshooting guide for a list of common
    -- errors and their solutions. To learn more, see
    -- <https://docs.aws.amazon.com/mwaa/latest/userguide/troubleshooting.html Amazon MWAA troubleshooting>.
    Environment -> Maybe EnvironmentStatus
status :: Prelude.Maybe EnvironmentStatus,
    -- | The minimum number of workers that run in your environment. For example,
    -- @2@.
    Environment -> Maybe Natural
minWorkers :: Prelude.Maybe Prelude.Natural,
    -- | The relative path to the @plugins.zip@ file on your Amazon S3 bucket.
    -- For example, @plugins.zip@. To learn more, see
    -- <https://docs.aws.amazon.com/mwaa/latest/userguide/configuring-dag-import-plugins.html Installing custom plugins>.
    Environment -> Maybe Text
pluginsS3Path :: Prelude.Maybe Prelude.Text,
    -- | The Apache Airflow /Web server/ access mode. To learn more, see
    -- <https://docs.aws.amazon.com/mwaa/latest/userguide/configuring-networking.html Apache Airflow access modes>.
    Environment -> Maybe WebserverAccessMode
webserverAccessMode :: Prelude.Maybe WebserverAccessMode,
    -- | The Apache Airflow version on your environment. For example, @v1.10.12@.
    Environment -> Maybe Text
airflowVersion :: Prelude.Maybe Prelude.Text,
    -- | The Key Management Service (KMS) encryption key used to encrypt the data
    -- in your environment.
    Environment -> Maybe Text
kmsKey :: Prelude.Maybe Prelude.Text,
    -- | The Amazon Resource Name (ARN) of the Amazon MWAA environment.
    Environment -> Maybe Text
arn :: Prelude.Maybe Prelude.Text,
    -- | The day and time the environment was created.
    Environment -> Maybe POSIX
createdAt :: Prelude.Maybe Core.POSIX,
    -- | The day and time of the week that weekly maintenance updates are
    -- scheduled. For example: @TUE:03:30@.
    Environment -> Maybe Text
weeklyMaintenanceWindowStart :: Prelude.Maybe Prelude.Text,
    -- | The Amazon Resource Name (ARN) of the execution role in IAM that allows
    -- MWAA to access AWS resources in your environment. For example,
    -- @arn:aws:iam::123456789:role\/my-execution-role@. To learn more, see
    -- <https://docs.aws.amazon.com/mwaa/latest/userguide/mwaa-create-role.html Amazon MWAA Execution role>.
    Environment -> Maybe Text
executionRoleArn :: Prelude.Maybe Prelude.Text,
    -- | The version of the requirements.txt file on your Amazon S3 bucket. To
    -- learn more, see
    -- <https://docs.aws.amazon.com/mwaa/latest/userguide/working-dags-dependencies.html Installing Python dependencies>.
    Environment -> Maybe Text
requirementsS3ObjectVersion :: Prelude.Maybe Prelude.Text,
    Environment -> Maybe LastUpdate
lastUpdate :: Prelude.Maybe LastUpdate,
    -- | The Amazon Resource Name (ARN) of the Amazon S3 bucket where your DAG
    -- code and supporting files are stored. For example,
    -- @arn:aws:s3:::my-airflow-bucket-unique-name@. To learn more, see
    -- <https://docs.aws.amazon.com/mwaa/latest/userguide/mwaa-s3-bucket.html Create an Amazon S3 bucket for Amazon MWAA>.
    Environment -> Maybe Text
sourceBucketArn :: Prelude.Maybe Prelude.Text,
    -- | The Apache Airflow /Web server/ host name for the Amazon MWAA
    -- environment. To learn more, see
    -- <https://docs.aws.amazon.com/mwaa/latest/userguide/access-airflow-ui.html Accessing the Apache Airflow UI>.
    Environment -> Maybe Text
webserverUrl :: Prelude.Maybe Prelude.Text,
    -- | The relative path to the DAGs folder on your Amazon S3 bucket. For
    -- example, @dags@. To learn more, see
    -- <https://docs.aws.amazon.com/mwaa/latest/userguide/configuring-dag-folder.html Adding or updating DAGs>.
    Environment -> Maybe Text
dagS3Path :: Prelude.Maybe Prelude.Text,
    -- | The name of the Amazon MWAA environment. For example,
    -- @MyMWAAEnvironment@.
    Environment -> Maybe Text
name :: Prelude.Maybe Prelude.Text,
    -- | The version of the plugins.zip file on your Amazon S3 bucket. To learn
    -- more, see
    -- <https://docs.aws.amazon.com/mwaa/latest/userguide/configuring-dag-import-plugins.html Installing custom plugins>.
    Environment -> Maybe Text
pluginsS3ObjectVersion :: Prelude.Maybe Prelude.Text,
    -- | A list of key-value pairs containing the Apache Airflow configuration
    -- options attached to your environment. To learn more, see
    -- <https://docs.aws.amazon.com/mwaa/latest/userguide/configuring-env-variables.html Apache Airflow configuration options>.
    Environment -> Maybe (HashMap Text Text)
airflowConfigurationOptions :: Prelude.Maybe (Prelude.HashMap Prelude.Text Prelude.Text),
    -- | The Apache Airflow logs being sent to CloudWatch Logs:
    -- @DagProcessingLogs@, @SchedulerLogs@, @TaskLogs@, @WebserverLogs@,
    -- @WorkerLogs@.
    Environment -> Maybe LoggingConfiguration
loggingConfiguration :: Prelude.Maybe LoggingConfiguration,
    -- | The environment class type. Valid values: @mw1.small@, @mw1.medium@,
    -- @mw1.large@. To learn more, see
    -- <https://docs.aws.amazon.com/mwaa/latest/userguide/environment-class.html Amazon MWAA environment class>.
    Environment -> Maybe Text
environmentClass :: Prelude.Maybe Prelude.Text,
    Environment -> Maybe NetworkConfiguration
networkConfiguration :: Prelude.Maybe NetworkConfiguration,
    -- | The key-value tag pairs associated to your environment. For example,
    -- @\"Environment\": \"Staging\"@. To learn more, see
    -- <https://docs.aws.amazon.com/general/latest/gr/aws_tagging.html Tagging AWS resources>.
    Environment -> Maybe (HashMap Text Text)
tags :: Prelude.Maybe (Prelude.HashMap Prelude.Text Prelude.Text),
    -- | The relative path to the @requirements.txt@ file on your Amazon S3
    -- bucket. For example, @requirements.txt@. To learn more, see
    -- <https://docs.aws.amazon.com/mwaa/latest/userguide/working-dags-dependencies.html Installing Python dependencies>.
    Environment -> Maybe Text
requirementsS3Path :: Prelude.Maybe Prelude.Text,
    -- | The maximum number of workers that run in your environment. For example,
    -- @20@.
    Environment -> Maybe Natural
maxWorkers :: Prelude.Maybe Prelude.Natural
  }
  deriving (Environment -> Environment -> Bool
(Environment -> Environment -> Bool)
-> (Environment -> Environment -> Bool) -> Eq Environment
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: Environment -> Environment -> Bool
$c/= :: Environment -> Environment -> Bool
== :: Environment -> Environment -> Bool
$c== :: Environment -> Environment -> Bool
Prelude.Eq, ReadPrec [Environment]
ReadPrec Environment
Int -> ReadS Environment
ReadS [Environment]
(Int -> ReadS Environment)
-> ReadS [Environment]
-> ReadPrec Environment
-> ReadPrec [Environment]
-> Read Environment
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [Environment]
$creadListPrec :: ReadPrec [Environment]
readPrec :: ReadPrec Environment
$creadPrec :: ReadPrec Environment
readList :: ReadS [Environment]
$creadList :: ReadS [Environment]
readsPrec :: Int -> ReadS Environment
$creadsPrec :: Int -> ReadS Environment
Prelude.Read, Int -> Environment -> ShowS
[Environment] -> ShowS
Environment -> String
(Int -> Environment -> ShowS)
-> (Environment -> String)
-> ([Environment] -> ShowS)
-> Show Environment
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [Environment] -> ShowS
$cshowList :: [Environment] -> ShowS
show :: Environment -> String
$cshow :: Environment -> String
showsPrec :: Int -> Environment -> ShowS
$cshowsPrec :: Int -> Environment -> ShowS
Prelude.Show, (forall x. Environment -> Rep Environment x)
-> (forall x. Rep Environment x -> Environment)
-> Generic Environment
forall x. Rep Environment x -> Environment
forall x. Environment -> Rep Environment x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep Environment x -> Environment
$cfrom :: forall x. Environment -> Rep Environment x
Prelude.Generic)

-- |
-- Create a value of 'Environment' 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:
--
-- 'serviceRoleArn', 'environment_serviceRoleArn' - The Amazon Resource Name (ARN) for the service-linked role of the
-- environment. To learn more, see
-- <https://docs.aws.amazon.com/mwaa/latest/userguide/mwaa-slr.html Amazon MWAA Service-linked role>.
--
-- 'schedulers', 'environment_schedulers' - The number of Apache Airflow schedulers that run in your Amazon MWAA
-- environment.
--
-- 'status', 'environment_status' - The status of the Amazon MWAA environment. Valid values:
--
-- -   @CREATING@ - Indicates the request to create the environment is in
--     progress.
--
-- -   @CREATE_FAILED@ - Indicates the request to create the environment
--     failed, and the environment could not be created.
--
-- -   @AVAILABLE@ - Indicates the request was successful and the
--     environment is ready to use.
--
-- -   @UPDATING@ - Indicates the request to update the environment is in
--     progress.
--
-- -   @DELETING@ - Indicates the request to delete the environment is in
--     progress.
--
-- -   @DELETED@ - Indicates the request to delete the environment is
--     complete, and the environment has been deleted.
--
-- -   @UNAVAILABLE@ - Indicates the request failed, but the environment
--     was unable to rollback and is not in a stable state.
--
-- -   @UPDATE_FAILED@ - Indicates the request to update the environment
--     failed, and the environment has rolled back successfully and is
--     ready to use.
--
-- We recommend reviewing our troubleshooting guide for a list of common
-- errors and their solutions. To learn more, see
-- <https://docs.aws.amazon.com/mwaa/latest/userguide/troubleshooting.html Amazon MWAA troubleshooting>.
--
-- 'minWorkers', 'environment_minWorkers' - The minimum number of workers that run in your environment. For example,
-- @2@.
--
-- 'pluginsS3Path', 'environment_pluginsS3Path' - The relative path to the @plugins.zip@ file on your Amazon S3 bucket.
-- For example, @plugins.zip@. To learn more, see
-- <https://docs.aws.amazon.com/mwaa/latest/userguide/configuring-dag-import-plugins.html Installing custom plugins>.
--
-- 'webserverAccessMode', 'environment_webserverAccessMode' - The Apache Airflow /Web server/ access mode. To learn more, see
-- <https://docs.aws.amazon.com/mwaa/latest/userguide/configuring-networking.html Apache Airflow access modes>.
--
-- 'airflowVersion', 'environment_airflowVersion' - The Apache Airflow version on your environment. For example, @v1.10.12@.
--
-- 'kmsKey', 'environment_kmsKey' - The Key Management Service (KMS) encryption key used to encrypt the data
-- in your environment.
--
-- 'arn', 'environment_arn' - The Amazon Resource Name (ARN) of the Amazon MWAA environment.
--
-- 'createdAt', 'environment_createdAt' - The day and time the environment was created.
--
-- 'weeklyMaintenanceWindowStart', 'environment_weeklyMaintenanceWindowStart' - The day and time of the week that weekly maintenance updates are
-- scheduled. For example: @TUE:03:30@.
--
-- 'executionRoleArn', 'environment_executionRoleArn' - The Amazon Resource Name (ARN) of the execution role in IAM that allows
-- MWAA to access AWS resources in your environment. For example,
-- @arn:aws:iam::123456789:role\/my-execution-role@. To learn more, see
-- <https://docs.aws.amazon.com/mwaa/latest/userguide/mwaa-create-role.html Amazon MWAA Execution role>.
--
-- 'requirementsS3ObjectVersion', 'environment_requirementsS3ObjectVersion' - The version of the requirements.txt file on your Amazon S3 bucket. To
-- learn more, see
-- <https://docs.aws.amazon.com/mwaa/latest/userguide/working-dags-dependencies.html Installing Python dependencies>.
--
-- 'lastUpdate', 'environment_lastUpdate' - Undocumented member.
--
-- 'sourceBucketArn', 'environment_sourceBucketArn' - The Amazon Resource Name (ARN) of the Amazon S3 bucket where your DAG
-- code and supporting files are stored. For example,
-- @arn:aws:s3:::my-airflow-bucket-unique-name@. To learn more, see
-- <https://docs.aws.amazon.com/mwaa/latest/userguide/mwaa-s3-bucket.html Create an Amazon S3 bucket for Amazon MWAA>.
--
-- 'webserverUrl', 'environment_webserverUrl' - The Apache Airflow /Web server/ host name for the Amazon MWAA
-- environment. To learn more, see
-- <https://docs.aws.amazon.com/mwaa/latest/userguide/access-airflow-ui.html Accessing the Apache Airflow UI>.
--
-- 'dagS3Path', 'environment_dagS3Path' - The relative path to the DAGs folder on your Amazon S3 bucket. For
-- example, @dags@. To learn more, see
-- <https://docs.aws.amazon.com/mwaa/latest/userguide/configuring-dag-folder.html Adding or updating DAGs>.
--
-- 'name', 'environment_name' - The name of the Amazon MWAA environment. For example,
-- @MyMWAAEnvironment@.
--
-- 'pluginsS3ObjectVersion', 'environment_pluginsS3ObjectVersion' - The version of the plugins.zip file on your Amazon S3 bucket. To learn
-- more, see
-- <https://docs.aws.amazon.com/mwaa/latest/userguide/configuring-dag-import-plugins.html Installing custom plugins>.
--
-- 'airflowConfigurationOptions', 'environment_airflowConfigurationOptions' - A list of key-value pairs containing the Apache Airflow configuration
-- options attached to your environment. To learn more, see
-- <https://docs.aws.amazon.com/mwaa/latest/userguide/configuring-env-variables.html Apache Airflow configuration options>.
--
-- 'loggingConfiguration', 'environment_loggingConfiguration' - The Apache Airflow logs being sent to CloudWatch Logs:
-- @DagProcessingLogs@, @SchedulerLogs@, @TaskLogs@, @WebserverLogs@,
-- @WorkerLogs@.
--
-- 'environmentClass', 'environment_environmentClass' - The environment class type. Valid values: @mw1.small@, @mw1.medium@,
-- @mw1.large@. To learn more, see
-- <https://docs.aws.amazon.com/mwaa/latest/userguide/environment-class.html Amazon MWAA environment class>.
--
-- 'networkConfiguration', 'environment_networkConfiguration' - Undocumented member.
--
-- 'tags', 'environment_tags' - The key-value tag pairs associated to your environment. For example,
-- @\"Environment\": \"Staging\"@. To learn more, see
-- <https://docs.aws.amazon.com/general/latest/gr/aws_tagging.html Tagging AWS resources>.
--
-- 'requirementsS3Path', 'environment_requirementsS3Path' - The relative path to the @requirements.txt@ file on your Amazon S3
-- bucket. For example, @requirements.txt@. To learn more, see
-- <https://docs.aws.amazon.com/mwaa/latest/userguide/working-dags-dependencies.html Installing Python dependencies>.
--
-- 'maxWorkers', 'environment_maxWorkers' - The maximum number of workers that run in your environment. For example,
-- @20@.
newEnvironment ::
  Environment
newEnvironment :: Environment
newEnvironment =
  Environment' :: Maybe Text
-> Maybe Int
-> Maybe EnvironmentStatus
-> Maybe Natural
-> Maybe Text
-> Maybe WebserverAccessMode
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe POSIX
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe LastUpdate
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe (HashMap Text Text)
-> Maybe LoggingConfiguration
-> Maybe Text
-> Maybe NetworkConfiguration
-> Maybe (HashMap Text Text)
-> Maybe Text
-> Maybe Natural
-> Environment
Environment'
    { $sel:serviceRoleArn:Environment' :: Maybe Text
serviceRoleArn = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:schedulers:Environment' :: Maybe Int
schedulers = Maybe Int
forall a. Maybe a
Prelude.Nothing,
      $sel:status:Environment' :: Maybe EnvironmentStatus
status = Maybe EnvironmentStatus
forall a. Maybe a
Prelude.Nothing,
      $sel:minWorkers:Environment' :: Maybe Natural
minWorkers = Maybe Natural
forall a. Maybe a
Prelude.Nothing,
      $sel:pluginsS3Path:Environment' :: Maybe Text
pluginsS3Path = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:webserverAccessMode:Environment' :: Maybe WebserverAccessMode
webserverAccessMode = Maybe WebserverAccessMode
forall a. Maybe a
Prelude.Nothing,
      $sel:airflowVersion:Environment' :: Maybe Text
airflowVersion = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:kmsKey:Environment' :: Maybe Text
kmsKey = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:arn:Environment' :: Maybe Text
arn = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:createdAt:Environment' :: Maybe POSIX
createdAt = Maybe POSIX
forall a. Maybe a
Prelude.Nothing,
      $sel:weeklyMaintenanceWindowStart:Environment' :: Maybe Text
weeklyMaintenanceWindowStart = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:executionRoleArn:Environment' :: Maybe Text
executionRoleArn = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:requirementsS3ObjectVersion:Environment' :: Maybe Text
requirementsS3ObjectVersion = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:lastUpdate:Environment' :: Maybe LastUpdate
lastUpdate = Maybe LastUpdate
forall a. Maybe a
Prelude.Nothing,
      $sel:sourceBucketArn:Environment' :: Maybe Text
sourceBucketArn = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:webserverUrl:Environment' :: Maybe Text
webserverUrl = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:dagS3Path:Environment' :: Maybe Text
dagS3Path = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:name:Environment' :: Maybe Text
name = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:pluginsS3ObjectVersion:Environment' :: Maybe Text
pluginsS3ObjectVersion = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:airflowConfigurationOptions:Environment' :: Maybe (HashMap Text Text)
airflowConfigurationOptions = Maybe (HashMap Text Text)
forall a. Maybe a
Prelude.Nothing,
      $sel:loggingConfiguration:Environment' :: Maybe LoggingConfiguration
loggingConfiguration = Maybe LoggingConfiguration
forall a. Maybe a
Prelude.Nothing,
      $sel:environmentClass:Environment' :: Maybe Text
environmentClass = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:networkConfiguration:Environment' :: Maybe NetworkConfiguration
networkConfiguration = Maybe NetworkConfiguration
forall a. Maybe a
Prelude.Nothing,
      $sel:tags:Environment' :: Maybe (HashMap Text Text)
tags = Maybe (HashMap Text Text)
forall a. Maybe a
Prelude.Nothing,
      $sel:requirementsS3Path:Environment' :: Maybe Text
requirementsS3Path = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:maxWorkers:Environment' :: Maybe Natural
maxWorkers = Maybe Natural
forall a. Maybe a
Prelude.Nothing
    }

-- | The Amazon Resource Name (ARN) for the service-linked role of the
-- environment. To learn more, see
-- <https://docs.aws.amazon.com/mwaa/latest/userguide/mwaa-slr.html Amazon MWAA Service-linked role>.
environment_serviceRoleArn :: Lens.Lens' Environment (Prelude.Maybe Prelude.Text)
environment_serviceRoleArn :: (Maybe Text -> f (Maybe Text)) -> Environment -> f Environment
environment_serviceRoleArn = (Environment -> Maybe Text)
-> (Environment -> Maybe Text -> Environment)
-> Lens Environment Environment (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Environment' {Maybe Text
serviceRoleArn :: Maybe Text
$sel:serviceRoleArn:Environment' :: Environment -> Maybe Text
serviceRoleArn} -> Maybe Text
serviceRoleArn) (\s :: Environment
s@Environment' {} Maybe Text
a -> Environment
s {$sel:serviceRoleArn:Environment' :: Maybe Text
serviceRoleArn = Maybe Text
a} :: Environment)

-- | The number of Apache Airflow schedulers that run in your Amazon MWAA
-- environment.
environment_schedulers :: Lens.Lens' Environment (Prelude.Maybe Prelude.Int)
environment_schedulers :: (Maybe Int -> f (Maybe Int)) -> Environment -> f Environment
environment_schedulers = (Environment -> Maybe Int)
-> (Environment -> Maybe Int -> Environment)
-> Lens Environment Environment (Maybe Int) (Maybe Int)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Environment' {Maybe Int
schedulers :: Maybe Int
$sel:schedulers:Environment' :: Environment -> Maybe Int
schedulers} -> Maybe Int
schedulers) (\s :: Environment
s@Environment' {} Maybe Int
a -> Environment
s {$sel:schedulers:Environment' :: Maybe Int
schedulers = Maybe Int
a} :: Environment)

-- | The status of the Amazon MWAA environment. Valid values:
--
-- -   @CREATING@ - Indicates the request to create the environment is in
--     progress.
--
-- -   @CREATE_FAILED@ - Indicates the request to create the environment
--     failed, and the environment could not be created.
--
-- -   @AVAILABLE@ - Indicates the request was successful and the
--     environment is ready to use.
--
-- -   @UPDATING@ - Indicates the request to update the environment is in
--     progress.
--
-- -   @DELETING@ - Indicates the request to delete the environment is in
--     progress.
--
-- -   @DELETED@ - Indicates the request to delete the environment is
--     complete, and the environment has been deleted.
--
-- -   @UNAVAILABLE@ - Indicates the request failed, but the environment
--     was unable to rollback and is not in a stable state.
--
-- -   @UPDATE_FAILED@ - Indicates the request to update the environment
--     failed, and the environment has rolled back successfully and is
--     ready to use.
--
-- We recommend reviewing our troubleshooting guide for a list of common
-- errors and their solutions. To learn more, see
-- <https://docs.aws.amazon.com/mwaa/latest/userguide/troubleshooting.html Amazon MWAA troubleshooting>.
environment_status :: Lens.Lens' Environment (Prelude.Maybe EnvironmentStatus)
environment_status :: (Maybe EnvironmentStatus -> f (Maybe EnvironmentStatus))
-> Environment -> f Environment
environment_status = (Environment -> Maybe EnvironmentStatus)
-> (Environment -> Maybe EnvironmentStatus -> Environment)
-> Lens
     Environment
     Environment
     (Maybe EnvironmentStatus)
     (Maybe EnvironmentStatus)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Environment' {Maybe EnvironmentStatus
status :: Maybe EnvironmentStatus
$sel:status:Environment' :: Environment -> Maybe EnvironmentStatus
status} -> Maybe EnvironmentStatus
status) (\s :: Environment
s@Environment' {} Maybe EnvironmentStatus
a -> Environment
s {$sel:status:Environment' :: Maybe EnvironmentStatus
status = Maybe EnvironmentStatus
a} :: Environment)

-- | The minimum number of workers that run in your environment. For example,
-- @2@.
environment_minWorkers :: Lens.Lens' Environment (Prelude.Maybe Prelude.Natural)
environment_minWorkers :: (Maybe Natural -> f (Maybe Natural))
-> Environment -> f Environment
environment_minWorkers = (Environment -> Maybe Natural)
-> (Environment -> Maybe Natural -> Environment)
-> Lens Environment Environment (Maybe Natural) (Maybe Natural)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Environment' {Maybe Natural
minWorkers :: Maybe Natural
$sel:minWorkers:Environment' :: Environment -> Maybe Natural
minWorkers} -> Maybe Natural
minWorkers) (\s :: Environment
s@Environment' {} Maybe Natural
a -> Environment
s {$sel:minWorkers:Environment' :: Maybe Natural
minWorkers = Maybe Natural
a} :: Environment)

-- | The relative path to the @plugins.zip@ file on your Amazon S3 bucket.
-- For example, @plugins.zip@. To learn more, see
-- <https://docs.aws.amazon.com/mwaa/latest/userguide/configuring-dag-import-plugins.html Installing custom plugins>.
environment_pluginsS3Path :: Lens.Lens' Environment (Prelude.Maybe Prelude.Text)
environment_pluginsS3Path :: (Maybe Text -> f (Maybe Text)) -> Environment -> f Environment
environment_pluginsS3Path = (Environment -> Maybe Text)
-> (Environment -> Maybe Text -> Environment)
-> Lens Environment Environment (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Environment' {Maybe Text
pluginsS3Path :: Maybe Text
$sel:pluginsS3Path:Environment' :: Environment -> Maybe Text
pluginsS3Path} -> Maybe Text
pluginsS3Path) (\s :: Environment
s@Environment' {} Maybe Text
a -> Environment
s {$sel:pluginsS3Path:Environment' :: Maybe Text
pluginsS3Path = Maybe Text
a} :: Environment)

-- | The Apache Airflow /Web server/ access mode. To learn more, see
-- <https://docs.aws.amazon.com/mwaa/latest/userguide/configuring-networking.html Apache Airflow access modes>.
environment_webserverAccessMode :: Lens.Lens' Environment (Prelude.Maybe WebserverAccessMode)
environment_webserverAccessMode :: (Maybe WebserverAccessMode -> f (Maybe WebserverAccessMode))
-> Environment -> f Environment
environment_webserverAccessMode = (Environment -> Maybe WebserverAccessMode)
-> (Environment -> Maybe WebserverAccessMode -> Environment)
-> Lens
     Environment
     Environment
     (Maybe WebserverAccessMode)
     (Maybe WebserverAccessMode)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Environment' {Maybe WebserverAccessMode
webserverAccessMode :: Maybe WebserverAccessMode
$sel:webserverAccessMode:Environment' :: Environment -> Maybe WebserverAccessMode
webserverAccessMode} -> Maybe WebserverAccessMode
webserverAccessMode) (\s :: Environment
s@Environment' {} Maybe WebserverAccessMode
a -> Environment
s {$sel:webserverAccessMode:Environment' :: Maybe WebserverAccessMode
webserverAccessMode = Maybe WebserverAccessMode
a} :: Environment)

-- | The Apache Airflow version on your environment. For example, @v1.10.12@.
environment_airflowVersion :: Lens.Lens' Environment (Prelude.Maybe Prelude.Text)
environment_airflowVersion :: (Maybe Text -> f (Maybe Text)) -> Environment -> f Environment
environment_airflowVersion = (Environment -> Maybe Text)
-> (Environment -> Maybe Text -> Environment)
-> Lens Environment Environment (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Environment' {Maybe Text
airflowVersion :: Maybe Text
$sel:airflowVersion:Environment' :: Environment -> Maybe Text
airflowVersion} -> Maybe Text
airflowVersion) (\s :: Environment
s@Environment' {} Maybe Text
a -> Environment
s {$sel:airflowVersion:Environment' :: Maybe Text
airflowVersion = Maybe Text
a} :: Environment)

-- | The Key Management Service (KMS) encryption key used to encrypt the data
-- in your environment.
environment_kmsKey :: Lens.Lens' Environment (Prelude.Maybe Prelude.Text)
environment_kmsKey :: (Maybe Text -> f (Maybe Text)) -> Environment -> f Environment
environment_kmsKey = (Environment -> Maybe Text)
-> (Environment -> Maybe Text -> Environment)
-> Lens Environment Environment (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Environment' {Maybe Text
kmsKey :: Maybe Text
$sel:kmsKey:Environment' :: Environment -> Maybe Text
kmsKey} -> Maybe Text
kmsKey) (\s :: Environment
s@Environment' {} Maybe Text
a -> Environment
s {$sel:kmsKey:Environment' :: Maybe Text
kmsKey = Maybe Text
a} :: Environment)

-- | The Amazon Resource Name (ARN) of the Amazon MWAA environment.
environment_arn :: Lens.Lens' Environment (Prelude.Maybe Prelude.Text)
environment_arn :: (Maybe Text -> f (Maybe Text)) -> Environment -> f Environment
environment_arn = (Environment -> Maybe Text)
-> (Environment -> Maybe Text -> Environment)
-> Lens Environment Environment (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Environment' {Maybe Text
arn :: Maybe Text
$sel:arn:Environment' :: Environment -> Maybe Text
arn} -> Maybe Text
arn) (\s :: Environment
s@Environment' {} Maybe Text
a -> Environment
s {$sel:arn:Environment' :: Maybe Text
arn = Maybe Text
a} :: Environment)

-- | The day and time the environment was created.
environment_createdAt :: Lens.Lens' Environment (Prelude.Maybe Prelude.UTCTime)
environment_createdAt :: (Maybe UTCTime -> f (Maybe UTCTime))
-> Environment -> f Environment
environment_createdAt = (Environment -> Maybe POSIX)
-> (Environment -> Maybe POSIX -> Environment)
-> Lens Environment Environment (Maybe POSIX) (Maybe POSIX)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Environment' {Maybe POSIX
createdAt :: Maybe POSIX
$sel:createdAt:Environment' :: Environment -> Maybe POSIX
createdAt} -> Maybe POSIX
createdAt) (\s :: Environment
s@Environment' {} Maybe POSIX
a -> Environment
s {$sel:createdAt:Environment' :: Maybe POSIX
createdAt = Maybe POSIX
a} :: Environment) ((Maybe POSIX -> f (Maybe POSIX)) -> Environment -> f Environment)
-> ((Maybe UTCTime -> f (Maybe UTCTime))
    -> Maybe POSIX -> f (Maybe POSIX))
-> (Maybe UTCTime -> f (Maybe UTCTime))
-> Environment
-> f Environment
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso POSIX POSIX UTCTime UTCTime
-> Iso (Maybe POSIX) (Maybe POSIX) (Maybe UTCTime) (Maybe UTCTime)
forall (f :: * -> *) (g :: * -> *) s t a b.
(Functor f, Functor g) =>
AnIso s t a b -> Iso (f s) (g t) (f a) (g b)
Lens.mapping AnIso POSIX POSIX UTCTime UTCTime
forall (a :: Format). Iso' (Time a) UTCTime
Core._Time

-- | The day and time of the week that weekly maintenance updates are
-- scheduled. For example: @TUE:03:30@.
environment_weeklyMaintenanceWindowStart :: Lens.Lens' Environment (Prelude.Maybe Prelude.Text)
environment_weeklyMaintenanceWindowStart :: (Maybe Text -> f (Maybe Text)) -> Environment -> f Environment
environment_weeklyMaintenanceWindowStart = (Environment -> Maybe Text)
-> (Environment -> Maybe Text -> Environment)
-> Lens Environment Environment (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Environment' {Maybe Text
weeklyMaintenanceWindowStart :: Maybe Text
$sel:weeklyMaintenanceWindowStart:Environment' :: Environment -> Maybe Text
weeklyMaintenanceWindowStart} -> Maybe Text
weeklyMaintenanceWindowStart) (\s :: Environment
s@Environment' {} Maybe Text
a -> Environment
s {$sel:weeklyMaintenanceWindowStart:Environment' :: Maybe Text
weeklyMaintenanceWindowStart = Maybe Text
a} :: Environment)

-- | The Amazon Resource Name (ARN) of the execution role in IAM that allows
-- MWAA to access AWS resources in your environment. For example,
-- @arn:aws:iam::123456789:role\/my-execution-role@. To learn more, see
-- <https://docs.aws.amazon.com/mwaa/latest/userguide/mwaa-create-role.html Amazon MWAA Execution role>.
environment_executionRoleArn :: Lens.Lens' Environment (Prelude.Maybe Prelude.Text)
environment_executionRoleArn :: (Maybe Text -> f (Maybe Text)) -> Environment -> f Environment
environment_executionRoleArn = (Environment -> Maybe Text)
-> (Environment -> Maybe Text -> Environment)
-> Lens Environment Environment (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Environment' {Maybe Text
executionRoleArn :: Maybe Text
$sel:executionRoleArn:Environment' :: Environment -> Maybe Text
executionRoleArn} -> Maybe Text
executionRoleArn) (\s :: Environment
s@Environment' {} Maybe Text
a -> Environment
s {$sel:executionRoleArn:Environment' :: Maybe Text
executionRoleArn = Maybe Text
a} :: Environment)

-- | The version of the requirements.txt file on your Amazon S3 bucket. To
-- learn more, see
-- <https://docs.aws.amazon.com/mwaa/latest/userguide/working-dags-dependencies.html Installing Python dependencies>.
environment_requirementsS3ObjectVersion :: Lens.Lens' Environment (Prelude.Maybe Prelude.Text)
environment_requirementsS3ObjectVersion :: (Maybe Text -> f (Maybe Text)) -> Environment -> f Environment
environment_requirementsS3ObjectVersion = (Environment -> Maybe Text)
-> (Environment -> Maybe Text -> Environment)
-> Lens Environment Environment (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Environment' {Maybe Text
requirementsS3ObjectVersion :: Maybe Text
$sel:requirementsS3ObjectVersion:Environment' :: Environment -> Maybe Text
requirementsS3ObjectVersion} -> Maybe Text
requirementsS3ObjectVersion) (\s :: Environment
s@Environment' {} Maybe Text
a -> Environment
s {$sel:requirementsS3ObjectVersion:Environment' :: Maybe Text
requirementsS3ObjectVersion = Maybe Text
a} :: Environment)

-- | Undocumented member.
environment_lastUpdate :: Lens.Lens' Environment (Prelude.Maybe LastUpdate)
environment_lastUpdate :: (Maybe LastUpdate -> f (Maybe LastUpdate))
-> Environment -> f Environment
environment_lastUpdate = (Environment -> Maybe LastUpdate)
-> (Environment -> Maybe LastUpdate -> Environment)
-> Lens
     Environment Environment (Maybe LastUpdate) (Maybe LastUpdate)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Environment' {Maybe LastUpdate
lastUpdate :: Maybe LastUpdate
$sel:lastUpdate:Environment' :: Environment -> Maybe LastUpdate
lastUpdate} -> Maybe LastUpdate
lastUpdate) (\s :: Environment
s@Environment' {} Maybe LastUpdate
a -> Environment
s {$sel:lastUpdate:Environment' :: Maybe LastUpdate
lastUpdate = Maybe LastUpdate
a} :: Environment)

-- | The Amazon Resource Name (ARN) of the Amazon S3 bucket where your DAG
-- code and supporting files are stored. For example,
-- @arn:aws:s3:::my-airflow-bucket-unique-name@. To learn more, see
-- <https://docs.aws.amazon.com/mwaa/latest/userguide/mwaa-s3-bucket.html Create an Amazon S3 bucket for Amazon MWAA>.
environment_sourceBucketArn :: Lens.Lens' Environment (Prelude.Maybe Prelude.Text)
environment_sourceBucketArn :: (Maybe Text -> f (Maybe Text)) -> Environment -> f Environment
environment_sourceBucketArn = (Environment -> Maybe Text)
-> (Environment -> Maybe Text -> Environment)
-> Lens Environment Environment (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Environment' {Maybe Text
sourceBucketArn :: Maybe Text
$sel:sourceBucketArn:Environment' :: Environment -> Maybe Text
sourceBucketArn} -> Maybe Text
sourceBucketArn) (\s :: Environment
s@Environment' {} Maybe Text
a -> Environment
s {$sel:sourceBucketArn:Environment' :: Maybe Text
sourceBucketArn = Maybe Text
a} :: Environment)

-- | The Apache Airflow /Web server/ host name for the Amazon MWAA
-- environment. To learn more, see
-- <https://docs.aws.amazon.com/mwaa/latest/userguide/access-airflow-ui.html Accessing the Apache Airflow UI>.
environment_webserverUrl :: Lens.Lens' Environment (Prelude.Maybe Prelude.Text)
environment_webserverUrl :: (Maybe Text -> f (Maybe Text)) -> Environment -> f Environment
environment_webserverUrl = (Environment -> Maybe Text)
-> (Environment -> Maybe Text -> Environment)
-> Lens Environment Environment (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Environment' {Maybe Text
webserverUrl :: Maybe Text
$sel:webserverUrl:Environment' :: Environment -> Maybe Text
webserverUrl} -> Maybe Text
webserverUrl) (\s :: Environment
s@Environment' {} Maybe Text
a -> Environment
s {$sel:webserverUrl:Environment' :: Maybe Text
webserverUrl = Maybe Text
a} :: Environment)

-- | The relative path to the DAGs folder on your Amazon S3 bucket. For
-- example, @dags@. To learn more, see
-- <https://docs.aws.amazon.com/mwaa/latest/userguide/configuring-dag-folder.html Adding or updating DAGs>.
environment_dagS3Path :: Lens.Lens' Environment (Prelude.Maybe Prelude.Text)
environment_dagS3Path :: (Maybe Text -> f (Maybe Text)) -> Environment -> f Environment
environment_dagS3Path = (Environment -> Maybe Text)
-> (Environment -> Maybe Text -> Environment)
-> Lens Environment Environment (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Environment' {Maybe Text
dagS3Path :: Maybe Text
$sel:dagS3Path:Environment' :: Environment -> Maybe Text
dagS3Path} -> Maybe Text
dagS3Path) (\s :: Environment
s@Environment' {} Maybe Text
a -> Environment
s {$sel:dagS3Path:Environment' :: Maybe Text
dagS3Path = Maybe Text
a} :: Environment)

-- | The name of the Amazon MWAA environment. For example,
-- @MyMWAAEnvironment@.
environment_name :: Lens.Lens' Environment (Prelude.Maybe Prelude.Text)
environment_name :: (Maybe Text -> f (Maybe Text)) -> Environment -> f Environment
environment_name = (Environment -> Maybe Text)
-> (Environment -> Maybe Text -> Environment)
-> Lens Environment Environment (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Environment' {Maybe Text
name :: Maybe Text
$sel:name:Environment' :: Environment -> Maybe Text
name} -> Maybe Text
name) (\s :: Environment
s@Environment' {} Maybe Text
a -> Environment
s {$sel:name:Environment' :: Maybe Text
name = Maybe Text
a} :: Environment)

-- | The version of the plugins.zip file on your Amazon S3 bucket. To learn
-- more, see
-- <https://docs.aws.amazon.com/mwaa/latest/userguide/configuring-dag-import-plugins.html Installing custom plugins>.
environment_pluginsS3ObjectVersion :: Lens.Lens' Environment (Prelude.Maybe Prelude.Text)
environment_pluginsS3ObjectVersion :: (Maybe Text -> f (Maybe Text)) -> Environment -> f Environment
environment_pluginsS3ObjectVersion = (Environment -> Maybe Text)
-> (Environment -> Maybe Text -> Environment)
-> Lens Environment Environment (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Environment' {Maybe Text
pluginsS3ObjectVersion :: Maybe Text
$sel:pluginsS3ObjectVersion:Environment' :: Environment -> Maybe Text
pluginsS3ObjectVersion} -> Maybe Text
pluginsS3ObjectVersion) (\s :: Environment
s@Environment' {} Maybe Text
a -> Environment
s {$sel:pluginsS3ObjectVersion:Environment' :: Maybe Text
pluginsS3ObjectVersion = Maybe Text
a} :: Environment)

-- | A list of key-value pairs containing the Apache Airflow configuration
-- options attached to your environment. To learn more, see
-- <https://docs.aws.amazon.com/mwaa/latest/userguide/configuring-env-variables.html Apache Airflow configuration options>.
environment_airflowConfigurationOptions :: Lens.Lens' Environment (Prelude.Maybe (Prelude.HashMap Prelude.Text Prelude.Text))
environment_airflowConfigurationOptions :: (Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
-> Environment -> f Environment
environment_airflowConfigurationOptions = (Environment -> Maybe (HashMap Text Text))
-> (Environment -> Maybe (HashMap Text Text) -> Environment)
-> Lens
     Environment
     Environment
     (Maybe (HashMap Text Text))
     (Maybe (HashMap Text Text))
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Environment' {Maybe (HashMap Text Text)
airflowConfigurationOptions :: Maybe (HashMap Text Text)
$sel:airflowConfigurationOptions:Environment' :: Environment -> Maybe (HashMap Text Text)
airflowConfigurationOptions} -> Maybe (HashMap Text Text)
airflowConfigurationOptions) (\s :: Environment
s@Environment' {} Maybe (HashMap Text Text)
a -> Environment
s {$sel:airflowConfigurationOptions:Environment' :: Maybe (HashMap Text Text)
airflowConfigurationOptions = Maybe (HashMap Text Text)
a} :: Environment) ((Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
 -> Environment -> f Environment)
-> ((Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
    -> Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
-> (Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
-> Environment
-> f Environment
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
  (HashMap Text Text)
  (HashMap Text Text)
  (HashMap Text Text)
  (HashMap Text Text)
-> Iso
     (Maybe (HashMap Text Text))
     (Maybe (HashMap Text Text))
     (Maybe (HashMap Text Text))
     (Maybe (HashMap Text Text))
forall (f :: * -> *) (g :: * -> *) s t a b.
(Functor f, Functor g) =>
AnIso s t a b -> Iso (f s) (g t) (f a) (g b)
Lens.mapping AnIso
  (HashMap Text Text)
  (HashMap Text Text)
  (HashMap Text Text)
  (HashMap Text Text)
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | The Apache Airflow logs being sent to CloudWatch Logs:
-- @DagProcessingLogs@, @SchedulerLogs@, @TaskLogs@, @WebserverLogs@,
-- @WorkerLogs@.
environment_loggingConfiguration :: Lens.Lens' Environment (Prelude.Maybe LoggingConfiguration)
environment_loggingConfiguration :: (Maybe LoggingConfiguration -> f (Maybe LoggingConfiguration))
-> Environment -> f Environment
environment_loggingConfiguration = (Environment -> Maybe LoggingConfiguration)
-> (Environment -> Maybe LoggingConfiguration -> Environment)
-> Lens
     Environment
     Environment
     (Maybe LoggingConfiguration)
     (Maybe LoggingConfiguration)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Environment' {Maybe LoggingConfiguration
loggingConfiguration :: Maybe LoggingConfiguration
$sel:loggingConfiguration:Environment' :: Environment -> Maybe LoggingConfiguration
loggingConfiguration} -> Maybe LoggingConfiguration
loggingConfiguration) (\s :: Environment
s@Environment' {} Maybe LoggingConfiguration
a -> Environment
s {$sel:loggingConfiguration:Environment' :: Maybe LoggingConfiguration
loggingConfiguration = Maybe LoggingConfiguration
a} :: Environment)

-- | The environment class type. Valid values: @mw1.small@, @mw1.medium@,
-- @mw1.large@. To learn more, see
-- <https://docs.aws.amazon.com/mwaa/latest/userguide/environment-class.html Amazon MWAA environment class>.
environment_environmentClass :: Lens.Lens' Environment (Prelude.Maybe Prelude.Text)
environment_environmentClass :: (Maybe Text -> f (Maybe Text)) -> Environment -> f Environment
environment_environmentClass = (Environment -> Maybe Text)
-> (Environment -> Maybe Text -> Environment)
-> Lens Environment Environment (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Environment' {Maybe Text
environmentClass :: Maybe Text
$sel:environmentClass:Environment' :: Environment -> Maybe Text
environmentClass} -> Maybe Text
environmentClass) (\s :: Environment
s@Environment' {} Maybe Text
a -> Environment
s {$sel:environmentClass:Environment' :: Maybe Text
environmentClass = Maybe Text
a} :: Environment)

-- | Undocumented member.
environment_networkConfiguration :: Lens.Lens' Environment (Prelude.Maybe NetworkConfiguration)
environment_networkConfiguration :: (Maybe NetworkConfiguration -> f (Maybe NetworkConfiguration))
-> Environment -> f Environment
environment_networkConfiguration = (Environment -> Maybe NetworkConfiguration)
-> (Environment -> Maybe NetworkConfiguration -> Environment)
-> Lens
     Environment
     Environment
     (Maybe NetworkConfiguration)
     (Maybe NetworkConfiguration)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Environment' {Maybe NetworkConfiguration
networkConfiguration :: Maybe NetworkConfiguration
$sel:networkConfiguration:Environment' :: Environment -> Maybe NetworkConfiguration
networkConfiguration} -> Maybe NetworkConfiguration
networkConfiguration) (\s :: Environment
s@Environment' {} Maybe NetworkConfiguration
a -> Environment
s {$sel:networkConfiguration:Environment' :: Maybe NetworkConfiguration
networkConfiguration = Maybe NetworkConfiguration
a} :: Environment)

-- | The key-value tag pairs associated to your environment. For example,
-- @\"Environment\": \"Staging\"@. To learn more, see
-- <https://docs.aws.amazon.com/general/latest/gr/aws_tagging.html Tagging AWS resources>.
environment_tags :: Lens.Lens' Environment (Prelude.Maybe (Prelude.HashMap Prelude.Text Prelude.Text))
environment_tags :: (Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
-> Environment -> f Environment
environment_tags = (Environment -> Maybe (HashMap Text Text))
-> (Environment -> Maybe (HashMap Text Text) -> Environment)
-> Lens
     Environment
     Environment
     (Maybe (HashMap Text Text))
     (Maybe (HashMap Text Text))
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Environment' {Maybe (HashMap Text Text)
tags :: Maybe (HashMap Text Text)
$sel:tags:Environment' :: Environment -> Maybe (HashMap Text Text)
tags} -> Maybe (HashMap Text Text)
tags) (\s :: Environment
s@Environment' {} Maybe (HashMap Text Text)
a -> Environment
s {$sel:tags:Environment' :: Maybe (HashMap Text Text)
tags = Maybe (HashMap Text Text)
a} :: Environment) ((Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
 -> Environment -> f Environment)
-> ((Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
    -> Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
-> (Maybe (HashMap Text Text) -> f (Maybe (HashMap Text Text)))
-> Environment
-> f Environment
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
  (HashMap Text Text)
  (HashMap Text Text)
  (HashMap Text Text)
  (HashMap Text Text)
-> Iso
     (Maybe (HashMap Text Text))
     (Maybe (HashMap Text Text))
     (Maybe (HashMap Text Text))
     (Maybe (HashMap Text Text))
forall (f :: * -> *) (g :: * -> *) s t a b.
(Functor f, Functor g) =>
AnIso s t a b -> Iso (f s) (g t) (f a) (g b)
Lens.mapping AnIso
  (HashMap Text Text)
  (HashMap Text Text)
  (HashMap Text Text)
  (HashMap Text Text)
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | The relative path to the @requirements.txt@ file on your Amazon S3
-- bucket. For example, @requirements.txt@. To learn more, see
-- <https://docs.aws.amazon.com/mwaa/latest/userguide/working-dags-dependencies.html Installing Python dependencies>.
environment_requirementsS3Path :: Lens.Lens' Environment (Prelude.Maybe Prelude.Text)
environment_requirementsS3Path :: (Maybe Text -> f (Maybe Text)) -> Environment -> f Environment
environment_requirementsS3Path = (Environment -> Maybe Text)
-> (Environment -> Maybe Text -> Environment)
-> Lens Environment Environment (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Environment' {Maybe Text
requirementsS3Path :: Maybe Text
$sel:requirementsS3Path:Environment' :: Environment -> Maybe Text
requirementsS3Path} -> Maybe Text
requirementsS3Path) (\s :: Environment
s@Environment' {} Maybe Text
a -> Environment
s {$sel:requirementsS3Path:Environment' :: Maybe Text
requirementsS3Path = Maybe Text
a} :: Environment)

-- | The maximum number of workers that run in your environment. For example,
-- @20@.
environment_maxWorkers :: Lens.Lens' Environment (Prelude.Maybe Prelude.Natural)
environment_maxWorkers :: (Maybe Natural -> f (Maybe Natural))
-> Environment -> f Environment
environment_maxWorkers = (Environment -> Maybe Natural)
-> (Environment -> Maybe Natural -> Environment)
-> Lens Environment Environment (Maybe Natural) (Maybe Natural)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\Environment' {Maybe Natural
maxWorkers :: Maybe Natural
$sel:maxWorkers:Environment' :: Environment -> Maybe Natural
maxWorkers} -> Maybe Natural
maxWorkers) (\s :: Environment
s@Environment' {} Maybe Natural
a -> Environment
s {$sel:maxWorkers:Environment' :: Maybe Natural
maxWorkers = Maybe Natural
a} :: Environment)

instance Core.FromJSON Environment where
  parseJSON :: Value -> Parser Environment
parseJSON =
    String
-> (Object -> Parser Environment) -> Value -> Parser Environment
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Core.withObject
      String
"Environment"
      ( \Object
x ->
          Maybe Text
-> Maybe Int
-> Maybe EnvironmentStatus
-> Maybe Natural
-> Maybe Text
-> Maybe WebserverAccessMode
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe POSIX
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe LastUpdate
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe (HashMap Text Text)
-> Maybe LoggingConfiguration
-> Maybe Text
-> Maybe NetworkConfiguration
-> Maybe (HashMap Text Text)
-> Maybe Text
-> Maybe Natural
-> Environment
Environment'
            (Maybe Text
 -> Maybe Int
 -> Maybe EnvironmentStatus
 -> Maybe Natural
 -> Maybe Text
 -> Maybe WebserverAccessMode
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe POSIX
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe LastUpdate
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe (HashMap Text Text)
 -> Maybe LoggingConfiguration
 -> Maybe Text
 -> Maybe NetworkConfiguration
 -> Maybe (HashMap Text Text)
 -> Maybe Text
 -> Maybe Natural
 -> Environment)
-> Parser (Maybe Text)
-> Parser
     (Maybe Int
      -> Maybe EnvironmentStatus
      -> Maybe Natural
      -> Maybe Text
      -> Maybe WebserverAccessMode
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe POSIX
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe LastUpdate
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe (HashMap Text Text)
      -> Maybe LoggingConfiguration
      -> Maybe Text
      -> Maybe NetworkConfiguration
      -> Maybe (HashMap Text Text)
      -> Maybe Text
      -> Maybe Natural
      -> Environment)
forall (f :: * -> *) a b. Functor 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
"ServiceRoleArn")
            Parser
  (Maybe Int
   -> Maybe EnvironmentStatus
   -> Maybe Natural
   -> Maybe Text
   -> Maybe WebserverAccessMode
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe POSIX
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe LastUpdate
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe (HashMap Text Text)
   -> Maybe LoggingConfiguration
   -> Maybe Text
   -> Maybe NetworkConfiguration
   -> Maybe (HashMap Text Text)
   -> Maybe Text
   -> Maybe Natural
   -> Environment)
-> Parser (Maybe Int)
-> Parser
     (Maybe EnvironmentStatus
      -> Maybe Natural
      -> Maybe Text
      -> Maybe WebserverAccessMode
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe POSIX
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe LastUpdate
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe (HashMap Text Text)
      -> Maybe LoggingConfiguration
      -> Maybe Text
      -> Maybe NetworkConfiguration
      -> Maybe (HashMap Text Text)
      -> Maybe Text
      -> Maybe Natural
      -> Environment)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"Schedulers")
            Parser
  (Maybe EnvironmentStatus
   -> Maybe Natural
   -> Maybe Text
   -> Maybe WebserverAccessMode
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe POSIX
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe LastUpdate
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe (HashMap Text Text)
   -> Maybe LoggingConfiguration
   -> Maybe Text
   -> Maybe NetworkConfiguration
   -> Maybe (HashMap Text Text)
   -> Maybe Text
   -> Maybe Natural
   -> Environment)
-> Parser (Maybe EnvironmentStatus)
-> Parser
     (Maybe Natural
      -> Maybe Text
      -> Maybe WebserverAccessMode
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe POSIX
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe LastUpdate
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe (HashMap Text Text)
      -> Maybe LoggingConfiguration
      -> Maybe Text
      -> Maybe NetworkConfiguration
      -> Maybe (HashMap Text Text)
      -> Maybe Text
      -> Maybe Natural
      -> Environment)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe EnvironmentStatus)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"Status")
            Parser
  (Maybe Natural
   -> Maybe Text
   -> Maybe WebserverAccessMode
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe POSIX
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe LastUpdate
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe (HashMap Text Text)
   -> Maybe LoggingConfiguration
   -> Maybe Text
   -> Maybe NetworkConfiguration
   -> Maybe (HashMap Text Text)
   -> Maybe Text
   -> Maybe Natural
   -> Environment)
-> Parser (Maybe Natural)
-> Parser
     (Maybe Text
      -> Maybe WebserverAccessMode
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe POSIX
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe LastUpdate
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe (HashMap Text Text)
      -> Maybe LoggingConfiguration
      -> Maybe Text
      -> Maybe NetworkConfiguration
      -> Maybe (HashMap Text Text)
      -> Maybe Text
      -> Maybe Natural
      -> Environment)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Natural)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"MinWorkers")
            Parser
  (Maybe Text
   -> Maybe WebserverAccessMode
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe POSIX
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe LastUpdate
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe (HashMap Text Text)
   -> Maybe LoggingConfiguration
   -> Maybe Text
   -> Maybe NetworkConfiguration
   -> Maybe (HashMap Text Text)
   -> Maybe Text
   -> Maybe Natural
   -> Environment)
-> Parser (Maybe Text)
-> Parser
     (Maybe WebserverAccessMode
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe POSIX
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe LastUpdate
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe (HashMap Text Text)
      -> Maybe LoggingConfiguration
      -> Maybe Text
      -> Maybe NetworkConfiguration
      -> Maybe (HashMap Text Text)
      -> Maybe Text
      -> Maybe Natural
      -> Environment)
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
"PluginsS3Path")
            Parser
  (Maybe WebserverAccessMode
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe POSIX
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe LastUpdate
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe (HashMap Text Text)
   -> Maybe LoggingConfiguration
   -> Maybe Text
   -> Maybe NetworkConfiguration
   -> Maybe (HashMap Text Text)
   -> Maybe Text
   -> Maybe Natural
   -> Environment)
-> Parser (Maybe WebserverAccessMode)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe POSIX
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe LastUpdate
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe (HashMap Text Text)
      -> Maybe LoggingConfiguration
      -> Maybe Text
      -> Maybe NetworkConfiguration
      -> Maybe (HashMap Text Text)
      -> Maybe Text
      -> Maybe Natural
      -> Environment)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe WebserverAccessMode)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"WebserverAccessMode")
            Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe POSIX
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe LastUpdate
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe (HashMap Text Text)
   -> Maybe LoggingConfiguration
   -> Maybe Text
   -> Maybe NetworkConfiguration
   -> Maybe (HashMap Text Text)
   -> Maybe Text
   -> Maybe Natural
   -> Environment)
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe POSIX
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe LastUpdate
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe (HashMap Text Text)
      -> Maybe LoggingConfiguration
      -> Maybe Text
      -> Maybe NetworkConfiguration
      -> Maybe (HashMap Text Text)
      -> Maybe Text
      -> Maybe Natural
      -> Environment)
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
"AirflowVersion")
            Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe POSIX
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe LastUpdate
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe (HashMap Text Text)
   -> Maybe LoggingConfiguration
   -> Maybe Text
   -> Maybe NetworkConfiguration
   -> Maybe (HashMap Text Text)
   -> Maybe Text
   -> Maybe Natural
   -> Environment)
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe POSIX
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe LastUpdate
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe (HashMap Text Text)
      -> Maybe LoggingConfiguration
      -> Maybe Text
      -> Maybe NetworkConfiguration
      -> Maybe (HashMap Text Text)
      -> Maybe Text
      -> Maybe Natural
      -> Environment)
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
"KmsKey")
            Parser
  (Maybe Text
   -> Maybe POSIX
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe LastUpdate
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe (HashMap Text Text)
   -> Maybe LoggingConfiguration
   -> Maybe Text
   -> Maybe NetworkConfiguration
   -> Maybe (HashMap Text Text)
   -> Maybe Text
   -> Maybe Natural
   -> Environment)
-> Parser (Maybe Text)
-> Parser
     (Maybe POSIX
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe LastUpdate
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe (HashMap Text Text)
      -> Maybe LoggingConfiguration
      -> Maybe Text
      -> Maybe NetworkConfiguration
      -> Maybe (HashMap Text Text)
      -> Maybe Text
      -> Maybe Natural
      -> Environment)
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
"Arn")
            Parser
  (Maybe POSIX
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe LastUpdate
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe (HashMap Text Text)
   -> Maybe LoggingConfiguration
   -> Maybe Text
   -> Maybe NetworkConfiguration
   -> Maybe (HashMap Text Text)
   -> Maybe Text
   -> Maybe Natural
   -> Environment)
-> Parser (Maybe POSIX)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe LastUpdate
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe (HashMap Text Text)
      -> Maybe LoggingConfiguration
      -> Maybe Text
      -> Maybe NetworkConfiguration
      -> Maybe (HashMap Text Text)
      -> Maybe Text
      -> Maybe Natural
      -> Environment)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe POSIX)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"CreatedAt")
            Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe LastUpdate
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe (HashMap Text Text)
   -> Maybe LoggingConfiguration
   -> Maybe Text
   -> Maybe NetworkConfiguration
   -> Maybe (HashMap Text Text)
   -> Maybe Text
   -> Maybe Natural
   -> Environment)
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe LastUpdate
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe (HashMap Text Text)
      -> Maybe LoggingConfiguration
      -> Maybe Text
      -> Maybe NetworkConfiguration
      -> Maybe (HashMap Text Text)
      -> Maybe Text
      -> Maybe Natural
      -> Environment)
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
"WeeklyMaintenanceWindowStart")
            Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe LastUpdate
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe (HashMap Text Text)
   -> Maybe LoggingConfiguration
   -> Maybe Text
   -> Maybe NetworkConfiguration
   -> Maybe (HashMap Text Text)
   -> Maybe Text
   -> Maybe Natural
   -> Environment)
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe LastUpdate
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe (HashMap Text Text)
      -> Maybe LoggingConfiguration
      -> Maybe Text
      -> Maybe NetworkConfiguration
      -> Maybe (HashMap Text Text)
      -> Maybe Text
      -> Maybe Natural
      -> Environment)
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
"ExecutionRoleArn")
            Parser
  (Maybe Text
   -> Maybe LastUpdate
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe (HashMap Text Text)
   -> Maybe LoggingConfiguration
   -> Maybe Text
   -> Maybe NetworkConfiguration
   -> Maybe (HashMap Text Text)
   -> Maybe Text
   -> Maybe Natural
   -> Environment)
-> Parser (Maybe Text)
-> Parser
     (Maybe LastUpdate
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe (HashMap Text Text)
      -> Maybe LoggingConfiguration
      -> Maybe Text
      -> Maybe NetworkConfiguration
      -> Maybe (HashMap Text Text)
      -> Maybe Text
      -> Maybe Natural
      -> Environment)
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
"RequirementsS3ObjectVersion")
            Parser
  (Maybe LastUpdate
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe (HashMap Text Text)
   -> Maybe LoggingConfiguration
   -> Maybe Text
   -> Maybe NetworkConfiguration
   -> Maybe (HashMap Text Text)
   -> Maybe Text
   -> Maybe Natural
   -> Environment)
-> Parser (Maybe LastUpdate)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe (HashMap Text Text)
      -> Maybe LoggingConfiguration
      -> Maybe Text
      -> Maybe NetworkConfiguration
      -> Maybe (HashMap Text Text)
      -> Maybe Text
      -> Maybe Natural
      -> Environment)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe LastUpdate)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"LastUpdate")
            Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe (HashMap Text Text)
   -> Maybe LoggingConfiguration
   -> Maybe Text
   -> Maybe NetworkConfiguration
   -> Maybe (HashMap Text Text)
   -> Maybe Text
   -> Maybe Natural
   -> Environment)
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe (HashMap Text Text)
      -> Maybe LoggingConfiguration
      -> Maybe Text
      -> Maybe NetworkConfiguration
      -> Maybe (HashMap Text Text)
      -> Maybe Text
      -> Maybe Natural
      -> Environment)
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
"SourceBucketArn")
            Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe (HashMap Text Text)
   -> Maybe LoggingConfiguration
   -> Maybe Text
   -> Maybe NetworkConfiguration
   -> Maybe (HashMap Text Text)
   -> Maybe Text
   -> Maybe Natural
   -> Environment)
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe (HashMap Text Text)
      -> Maybe LoggingConfiguration
      -> Maybe Text
      -> Maybe NetworkConfiguration
      -> Maybe (HashMap Text Text)
      -> Maybe Text
      -> Maybe Natural
      -> Environment)
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
"WebserverUrl")
            Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe (HashMap Text Text)
   -> Maybe LoggingConfiguration
   -> Maybe Text
   -> Maybe NetworkConfiguration
   -> Maybe (HashMap Text Text)
   -> Maybe Text
   -> Maybe Natural
   -> Environment)
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe (HashMap Text Text)
      -> Maybe LoggingConfiguration
      -> Maybe Text
      -> Maybe NetworkConfiguration
      -> Maybe (HashMap Text Text)
      -> Maybe Text
      -> Maybe Natural
      -> Environment)
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
"DagS3Path")
            Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe (HashMap Text Text)
   -> Maybe LoggingConfiguration
   -> Maybe Text
   -> Maybe NetworkConfiguration
   -> Maybe (HashMap Text Text)
   -> Maybe Text
   -> Maybe Natural
   -> Environment)
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe (HashMap Text Text)
      -> Maybe LoggingConfiguration
      -> Maybe Text
      -> Maybe NetworkConfiguration
      -> Maybe (HashMap Text Text)
      -> Maybe Text
      -> Maybe Natural
      -> Environment)
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
"Name")
            Parser
  (Maybe Text
   -> Maybe (HashMap Text Text)
   -> Maybe LoggingConfiguration
   -> Maybe Text
   -> Maybe NetworkConfiguration
   -> Maybe (HashMap Text Text)
   -> Maybe Text
   -> Maybe Natural
   -> Environment)
-> Parser (Maybe Text)
-> Parser
     (Maybe (HashMap Text Text)
      -> Maybe LoggingConfiguration
      -> Maybe Text
      -> Maybe NetworkConfiguration
      -> Maybe (HashMap Text Text)
      -> Maybe Text
      -> Maybe Natural
      -> Environment)
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
"PluginsS3ObjectVersion")
            Parser
  (Maybe (HashMap Text Text)
   -> Maybe LoggingConfiguration
   -> Maybe Text
   -> Maybe NetworkConfiguration
   -> Maybe (HashMap Text Text)
   -> Maybe Text
   -> Maybe Natural
   -> Environment)
-> Parser (Maybe (HashMap Text Text))
-> Parser
     (Maybe LoggingConfiguration
      -> Maybe Text
      -> Maybe NetworkConfiguration
      -> Maybe (HashMap Text Text)
      -> Maybe Text
      -> Maybe Natural
      -> Environment)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ( Object
x Object -> Text -> Parser (Maybe (Maybe (HashMap Text Text)))
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"AirflowConfigurationOptions"
                            Parser (Maybe (Maybe (HashMap Text Text)))
-> Maybe (HashMap Text Text) -> Parser (Maybe (HashMap Text Text))
forall a. Parser (Maybe a) -> a -> Parser a
Core..!= Maybe (HashMap Text Text)
forall a. Monoid a => a
Prelude.mempty
                        )
            Parser
  (Maybe LoggingConfiguration
   -> Maybe Text
   -> Maybe NetworkConfiguration
   -> Maybe (HashMap Text Text)
   -> Maybe Text
   -> Maybe Natural
   -> Environment)
-> Parser (Maybe LoggingConfiguration)
-> Parser
     (Maybe Text
      -> Maybe NetworkConfiguration
      -> Maybe (HashMap Text Text)
      -> Maybe Text
      -> Maybe Natural
      -> Environment)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe LoggingConfiguration)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"LoggingConfiguration")
            Parser
  (Maybe Text
   -> Maybe NetworkConfiguration
   -> Maybe (HashMap Text Text)
   -> Maybe Text
   -> Maybe Natural
   -> Environment)
-> Parser (Maybe Text)
-> Parser
     (Maybe NetworkConfiguration
      -> Maybe (HashMap Text Text)
      -> Maybe Text
      -> Maybe Natural
      -> Environment)
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
"EnvironmentClass")
            Parser
  (Maybe NetworkConfiguration
   -> Maybe (HashMap Text Text)
   -> Maybe Text
   -> Maybe Natural
   -> Environment)
-> Parser (Maybe NetworkConfiguration)
-> Parser
     (Maybe (HashMap Text Text)
      -> Maybe Text -> Maybe Natural -> Environment)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe NetworkConfiguration)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"NetworkConfiguration")
            Parser
  (Maybe (HashMap Text Text)
   -> Maybe Text -> Maybe Natural -> Environment)
-> Parser (Maybe (HashMap Text Text))
-> Parser (Maybe Text -> Maybe Natural -> Environment)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe (Maybe (HashMap Text Text)))
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"Tags" Parser (Maybe (Maybe (HashMap Text Text)))
-> Maybe (HashMap Text Text) -> Parser (Maybe (HashMap Text Text))
forall a. Parser (Maybe a) -> a -> Parser a
Core..!= Maybe (HashMap Text Text)
forall a. Monoid a => a
Prelude.mempty)
            Parser (Maybe Text -> Maybe Natural -> Environment)
-> Parser (Maybe Text) -> Parser (Maybe Natural -> Environment)
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
"RequirementsS3Path")
            Parser (Maybe Natural -> Environment)
-> Parser (Maybe Natural) -> Parser Environment
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Natural)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"MaxWorkers")
      )

instance Prelude.Hashable Environment

instance Prelude.NFData Environment