{-# 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.SecurityHub.Types.AwsEcsServiceDetails
-- 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.SecurityHub.Types.AwsEcsServiceDetails where

import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude
import Amazonka.SecurityHub.Types.AwsEcsServiceCapacityProviderStrategyDetails
import Amazonka.SecurityHub.Types.AwsEcsServiceDeploymentConfigurationDetails
import Amazonka.SecurityHub.Types.AwsEcsServiceDeploymentControllerDetails
import Amazonka.SecurityHub.Types.AwsEcsServiceLoadBalancersDetails
import Amazonka.SecurityHub.Types.AwsEcsServiceNetworkConfigurationDetails
import Amazonka.SecurityHub.Types.AwsEcsServicePlacementConstraintsDetails
import Amazonka.SecurityHub.Types.AwsEcsServicePlacementStrategiesDetails
import Amazonka.SecurityHub.Types.AwsEcsServiceServiceRegistriesDetails

-- | Provides details about a service within an ECS cluster.
--
-- /See:/ 'newAwsEcsServiceDetails' smart constructor.
data AwsEcsServiceDetails = AwsEcsServiceDetails'
  { -- | Information about how tasks for the service are placed.
    AwsEcsServiceDetails
-> Maybe [AwsEcsServicePlacementStrategiesDetails]
placementStrategies :: Prelude.Maybe [AwsEcsServicePlacementStrategiesDetails],
    -- | The ARN of the cluster that hosts the service.
    AwsEcsServiceDetails -> Maybe Text
cluster :: Prelude.Maybe Prelude.Text,
    -- | Indicates whether to propagate the tags from the task definition to the
    -- task or from the service to the task. If no value is provided, then tags
    -- are not propagated.
    --
    -- Valid values: @TASK_DEFINITION@ | @SERVICE@
    AwsEcsServiceDetails -> Maybe Text
propagateTags :: Prelude.Maybe Prelude.Text,
    -- | The platform version on which to run the service. Only specified for
    -- tasks that are hosted on Fargate. If a platform version is not
    -- specified, the @LATEST@ platform version is used by default.
    AwsEcsServiceDetails -> Maybe Text
platformVersion :: Prelude.Maybe Prelude.Text,
    -- | Whether to enable Amazon ECS managed tags for the tasks in the service.
    AwsEcsServiceDetails -> Maybe Bool
enableEcsManagedTags :: Prelude.Maybe Prelude.Bool,
    -- | The number of instantiations of the task definition to run on the
    -- service.
    AwsEcsServiceDetails -> Maybe Int
desiredCount :: Prelude.Maybe Prelude.Int,
    -- | Information about the load balancers that the service uses.
    AwsEcsServiceDetails -> Maybe [AwsEcsServiceLoadBalancersDetails]
loadBalancers :: Prelude.Maybe [AwsEcsServiceLoadBalancersDetails],
    -- | The ARN of the IAM role that is associated with the service. The role
    -- allows the Amazon ECS container agent to register container instances
    -- with an Elastic Load Balancing load balancer.
    AwsEcsServiceDetails -> Maybe Text
role' :: Prelude.Maybe Prelude.Text,
    -- | The name of the service.
    AwsEcsServiceDetails -> Maybe Text
name :: Prelude.Maybe Prelude.Text,
    -- | The placement constraints for the tasks in the service.
    AwsEcsServiceDetails
-> Maybe [AwsEcsServicePlacementConstraintsDetails]
placementConstraints :: Prelude.Maybe [AwsEcsServicePlacementConstraintsDetails],
    -- | The name of the service.
    --
    -- The name can contain up to 255 characters. It can use letters, numbers,
    -- underscores, and hyphens.
    AwsEcsServiceDetails -> Maybe Text
serviceName :: Prelude.Maybe Prelude.Text,
    -- | Contains the deployment controller type that the service uses.
    AwsEcsServiceDetails
-> Maybe AwsEcsServiceDeploymentControllerDetails
deploymentController :: Prelude.Maybe AwsEcsServiceDeploymentControllerDetails,
    -- | The launch type that the service uses.
    --
    -- Valid values: @EC2@ | @FARGATE@ | @EXTERNAL@
    AwsEcsServiceDetails -> Maybe Text
launchType :: Prelude.Maybe Prelude.Text,
    -- | The task definition to use for tasks in the service.
    AwsEcsServiceDetails -> Maybe Text
taskDefinition :: Prelude.Maybe Prelude.Text,
    -- | The ARN of the service.
    AwsEcsServiceDetails -> Maybe Text
serviceArn :: Prelude.Maybe Prelude.Text,
    -- | The scheduling strategy to use for the service.
    --
    -- The @REPLICA@ scheduling strategy places and maintains the desired
    -- number of tasks across the cluster. By default, the service scheduler
    -- spreads tasks across Availability Zones. Task placement strategies and
    -- constraints are used to customize task placement decisions.
    --
    -- The @DAEMON@ scheduling strategy deploys exactly one task on each active
    -- container instance that meets all of the task placement constraints that
    -- are specified in the cluster. The service scheduler also evaluates the
    -- task placement constraints for running tasks and stops tasks that do not
    -- meet the placement constraints.
    --
    -- Valid values: @REPLICA@ | @DAEMON@
    AwsEcsServiceDetails -> Maybe Text
schedulingStrategy :: Prelude.Maybe Prelude.Text,
    -- | The capacity provider strategy that the service uses.
    AwsEcsServiceDetails
-> Maybe [AwsEcsServiceCapacityProviderStrategyDetails]
capacityProviderStrategy :: Prelude.Maybe [AwsEcsServiceCapacityProviderStrategyDetails],
    -- | Information about the service discovery registries to assign to the
    -- service.
    AwsEcsServiceDetails
-> Maybe [AwsEcsServiceServiceRegistriesDetails]
serviceRegistries :: Prelude.Maybe [AwsEcsServiceServiceRegistriesDetails],
    -- | After a task starts, the amount of time in seconds that the Amazon ECS
    -- service scheduler ignores unhealthy Elastic Load Balancing target health
    -- checks.
    AwsEcsServiceDetails -> Maybe Int
healthCheckGracePeriodSeconds :: Prelude.Maybe Prelude.Int,
    -- | For tasks that use the @awsvpc@ networking mode, the VPC subnet and
    -- security group configuration.
    AwsEcsServiceDetails
-> Maybe AwsEcsServiceNetworkConfigurationDetails
networkConfiguration :: Prelude.Maybe AwsEcsServiceNetworkConfigurationDetails,
    -- | Deployment parameters for the service. Includes the number of tasks that
    -- run and the order in which to start and stop tasks.
    AwsEcsServiceDetails
-> Maybe AwsEcsServiceDeploymentConfigurationDetails
deploymentConfiguration :: Prelude.Maybe AwsEcsServiceDeploymentConfigurationDetails,
    -- | Whether the execute command functionality is enabled for the service.
    AwsEcsServiceDetails -> Maybe Bool
enableExecuteCommand :: Prelude.Maybe Prelude.Bool
  }
  deriving (AwsEcsServiceDetails -> AwsEcsServiceDetails -> Bool
(AwsEcsServiceDetails -> AwsEcsServiceDetails -> Bool)
-> (AwsEcsServiceDetails -> AwsEcsServiceDetails -> Bool)
-> Eq AwsEcsServiceDetails
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: AwsEcsServiceDetails -> AwsEcsServiceDetails -> Bool
$c/= :: AwsEcsServiceDetails -> AwsEcsServiceDetails -> Bool
== :: AwsEcsServiceDetails -> AwsEcsServiceDetails -> Bool
$c== :: AwsEcsServiceDetails -> AwsEcsServiceDetails -> Bool
Prelude.Eq, ReadPrec [AwsEcsServiceDetails]
ReadPrec AwsEcsServiceDetails
Int -> ReadS AwsEcsServiceDetails
ReadS [AwsEcsServiceDetails]
(Int -> ReadS AwsEcsServiceDetails)
-> ReadS [AwsEcsServiceDetails]
-> ReadPrec AwsEcsServiceDetails
-> ReadPrec [AwsEcsServiceDetails]
-> Read AwsEcsServiceDetails
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [AwsEcsServiceDetails]
$creadListPrec :: ReadPrec [AwsEcsServiceDetails]
readPrec :: ReadPrec AwsEcsServiceDetails
$creadPrec :: ReadPrec AwsEcsServiceDetails
readList :: ReadS [AwsEcsServiceDetails]
$creadList :: ReadS [AwsEcsServiceDetails]
readsPrec :: Int -> ReadS AwsEcsServiceDetails
$creadsPrec :: Int -> ReadS AwsEcsServiceDetails
Prelude.Read, Int -> AwsEcsServiceDetails -> ShowS
[AwsEcsServiceDetails] -> ShowS
AwsEcsServiceDetails -> String
(Int -> AwsEcsServiceDetails -> ShowS)
-> (AwsEcsServiceDetails -> String)
-> ([AwsEcsServiceDetails] -> ShowS)
-> Show AwsEcsServiceDetails
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [AwsEcsServiceDetails] -> ShowS
$cshowList :: [AwsEcsServiceDetails] -> ShowS
show :: AwsEcsServiceDetails -> String
$cshow :: AwsEcsServiceDetails -> String
showsPrec :: Int -> AwsEcsServiceDetails -> ShowS
$cshowsPrec :: Int -> AwsEcsServiceDetails -> ShowS
Prelude.Show, (forall x. AwsEcsServiceDetails -> Rep AwsEcsServiceDetails x)
-> (forall x. Rep AwsEcsServiceDetails x -> AwsEcsServiceDetails)
-> Generic AwsEcsServiceDetails
forall x. Rep AwsEcsServiceDetails x -> AwsEcsServiceDetails
forall x. AwsEcsServiceDetails -> Rep AwsEcsServiceDetails x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep AwsEcsServiceDetails x -> AwsEcsServiceDetails
$cfrom :: forall x. AwsEcsServiceDetails -> Rep AwsEcsServiceDetails x
Prelude.Generic)

-- |
-- Create a value of 'AwsEcsServiceDetails' 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:
--
-- 'placementStrategies', 'awsEcsServiceDetails_placementStrategies' - Information about how tasks for the service are placed.
--
-- 'cluster', 'awsEcsServiceDetails_cluster' - The ARN of the cluster that hosts the service.
--
-- 'propagateTags', 'awsEcsServiceDetails_propagateTags' - Indicates whether to propagate the tags from the task definition to the
-- task or from the service to the task. If no value is provided, then tags
-- are not propagated.
--
-- Valid values: @TASK_DEFINITION@ | @SERVICE@
--
-- 'platformVersion', 'awsEcsServiceDetails_platformVersion' - The platform version on which to run the service. Only specified for
-- tasks that are hosted on Fargate. If a platform version is not
-- specified, the @LATEST@ platform version is used by default.
--
-- 'enableEcsManagedTags', 'awsEcsServiceDetails_enableEcsManagedTags' - Whether to enable Amazon ECS managed tags for the tasks in the service.
--
-- 'desiredCount', 'awsEcsServiceDetails_desiredCount' - The number of instantiations of the task definition to run on the
-- service.
--
-- 'loadBalancers', 'awsEcsServiceDetails_loadBalancers' - Information about the load balancers that the service uses.
--
-- 'role'', 'awsEcsServiceDetails_role' - The ARN of the IAM role that is associated with the service. The role
-- allows the Amazon ECS container agent to register container instances
-- with an Elastic Load Balancing load balancer.
--
-- 'name', 'awsEcsServiceDetails_name' - The name of the service.
--
-- 'placementConstraints', 'awsEcsServiceDetails_placementConstraints' - The placement constraints for the tasks in the service.
--
-- 'serviceName', 'awsEcsServiceDetails_serviceName' - The name of the service.
--
-- The name can contain up to 255 characters. It can use letters, numbers,
-- underscores, and hyphens.
--
-- 'deploymentController', 'awsEcsServiceDetails_deploymentController' - Contains the deployment controller type that the service uses.
--
-- 'launchType', 'awsEcsServiceDetails_launchType' - The launch type that the service uses.
--
-- Valid values: @EC2@ | @FARGATE@ | @EXTERNAL@
--
-- 'taskDefinition', 'awsEcsServiceDetails_taskDefinition' - The task definition to use for tasks in the service.
--
-- 'serviceArn', 'awsEcsServiceDetails_serviceArn' - The ARN of the service.
--
-- 'schedulingStrategy', 'awsEcsServiceDetails_schedulingStrategy' - The scheduling strategy to use for the service.
--
-- The @REPLICA@ scheduling strategy places and maintains the desired
-- number of tasks across the cluster. By default, the service scheduler
-- spreads tasks across Availability Zones. Task placement strategies and
-- constraints are used to customize task placement decisions.
--
-- The @DAEMON@ scheduling strategy deploys exactly one task on each active
-- container instance that meets all of the task placement constraints that
-- are specified in the cluster. The service scheduler also evaluates the
-- task placement constraints for running tasks and stops tasks that do not
-- meet the placement constraints.
--
-- Valid values: @REPLICA@ | @DAEMON@
--
-- 'capacityProviderStrategy', 'awsEcsServiceDetails_capacityProviderStrategy' - The capacity provider strategy that the service uses.
--
-- 'serviceRegistries', 'awsEcsServiceDetails_serviceRegistries' - Information about the service discovery registries to assign to the
-- service.
--
-- 'healthCheckGracePeriodSeconds', 'awsEcsServiceDetails_healthCheckGracePeriodSeconds' - After a task starts, the amount of time in seconds that the Amazon ECS
-- service scheduler ignores unhealthy Elastic Load Balancing target health
-- checks.
--
-- 'networkConfiguration', 'awsEcsServiceDetails_networkConfiguration' - For tasks that use the @awsvpc@ networking mode, the VPC subnet and
-- security group configuration.
--
-- 'deploymentConfiguration', 'awsEcsServiceDetails_deploymentConfiguration' - Deployment parameters for the service. Includes the number of tasks that
-- run and the order in which to start and stop tasks.
--
-- 'enableExecuteCommand', 'awsEcsServiceDetails_enableExecuteCommand' - Whether the execute command functionality is enabled for the service.
newAwsEcsServiceDetails ::
  AwsEcsServiceDetails
newAwsEcsServiceDetails :: AwsEcsServiceDetails
newAwsEcsServiceDetails =
  AwsEcsServiceDetails' :: Maybe [AwsEcsServicePlacementStrategiesDetails]
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Bool
-> Maybe Int
-> Maybe [AwsEcsServiceLoadBalancersDetails]
-> Maybe Text
-> Maybe Text
-> Maybe [AwsEcsServicePlacementConstraintsDetails]
-> Maybe Text
-> Maybe AwsEcsServiceDeploymentControllerDetails
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe [AwsEcsServiceCapacityProviderStrategyDetails]
-> Maybe [AwsEcsServiceServiceRegistriesDetails]
-> Maybe Int
-> Maybe AwsEcsServiceNetworkConfigurationDetails
-> Maybe AwsEcsServiceDeploymentConfigurationDetails
-> Maybe Bool
-> AwsEcsServiceDetails
AwsEcsServiceDetails'
    { $sel:placementStrategies:AwsEcsServiceDetails' :: Maybe [AwsEcsServicePlacementStrategiesDetails]
placementStrategies =
        Maybe [AwsEcsServicePlacementStrategiesDetails]
forall a. Maybe a
Prelude.Nothing,
      $sel:cluster:AwsEcsServiceDetails' :: Maybe Text
cluster = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:propagateTags:AwsEcsServiceDetails' :: Maybe Text
propagateTags = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:platformVersion:AwsEcsServiceDetails' :: Maybe Text
platformVersion = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:enableEcsManagedTags:AwsEcsServiceDetails' :: Maybe Bool
enableEcsManagedTags = Maybe Bool
forall a. Maybe a
Prelude.Nothing,
      $sel:desiredCount:AwsEcsServiceDetails' :: Maybe Int
desiredCount = Maybe Int
forall a. Maybe a
Prelude.Nothing,
      $sel:loadBalancers:AwsEcsServiceDetails' :: Maybe [AwsEcsServiceLoadBalancersDetails]
loadBalancers = Maybe [AwsEcsServiceLoadBalancersDetails]
forall a. Maybe a
Prelude.Nothing,
      $sel:role':AwsEcsServiceDetails' :: Maybe Text
role' = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:name:AwsEcsServiceDetails' :: Maybe Text
name = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:placementConstraints:AwsEcsServiceDetails' :: Maybe [AwsEcsServicePlacementConstraintsDetails]
placementConstraints = Maybe [AwsEcsServicePlacementConstraintsDetails]
forall a. Maybe a
Prelude.Nothing,
      $sel:serviceName:AwsEcsServiceDetails' :: Maybe Text
serviceName = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:deploymentController:AwsEcsServiceDetails' :: Maybe AwsEcsServiceDeploymentControllerDetails
deploymentController = Maybe AwsEcsServiceDeploymentControllerDetails
forall a. Maybe a
Prelude.Nothing,
      $sel:launchType:AwsEcsServiceDetails' :: Maybe Text
launchType = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:taskDefinition:AwsEcsServiceDetails' :: Maybe Text
taskDefinition = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:serviceArn:AwsEcsServiceDetails' :: Maybe Text
serviceArn = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:schedulingStrategy:AwsEcsServiceDetails' :: Maybe Text
schedulingStrategy = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:capacityProviderStrategy:AwsEcsServiceDetails' :: Maybe [AwsEcsServiceCapacityProviderStrategyDetails]
capacityProviderStrategy = Maybe [AwsEcsServiceCapacityProviderStrategyDetails]
forall a. Maybe a
Prelude.Nothing,
      $sel:serviceRegistries:AwsEcsServiceDetails' :: Maybe [AwsEcsServiceServiceRegistriesDetails]
serviceRegistries = Maybe [AwsEcsServiceServiceRegistriesDetails]
forall a. Maybe a
Prelude.Nothing,
      $sel:healthCheckGracePeriodSeconds:AwsEcsServiceDetails' :: Maybe Int
healthCheckGracePeriodSeconds = Maybe Int
forall a. Maybe a
Prelude.Nothing,
      $sel:networkConfiguration:AwsEcsServiceDetails' :: Maybe AwsEcsServiceNetworkConfigurationDetails
networkConfiguration = Maybe AwsEcsServiceNetworkConfigurationDetails
forall a. Maybe a
Prelude.Nothing,
      $sel:deploymentConfiguration:AwsEcsServiceDetails' :: Maybe AwsEcsServiceDeploymentConfigurationDetails
deploymentConfiguration = Maybe AwsEcsServiceDeploymentConfigurationDetails
forall a. Maybe a
Prelude.Nothing,
      $sel:enableExecuteCommand:AwsEcsServiceDetails' :: Maybe Bool
enableExecuteCommand = Maybe Bool
forall a. Maybe a
Prelude.Nothing
    }

-- | Information about how tasks for the service are placed.
awsEcsServiceDetails_placementStrategies :: Lens.Lens' AwsEcsServiceDetails (Prelude.Maybe [AwsEcsServicePlacementStrategiesDetails])
awsEcsServiceDetails_placementStrategies :: (Maybe [AwsEcsServicePlacementStrategiesDetails]
 -> f (Maybe [AwsEcsServicePlacementStrategiesDetails]))
-> AwsEcsServiceDetails -> f AwsEcsServiceDetails
awsEcsServiceDetails_placementStrategies = (AwsEcsServiceDetails
 -> Maybe [AwsEcsServicePlacementStrategiesDetails])
-> (AwsEcsServiceDetails
    -> Maybe [AwsEcsServicePlacementStrategiesDetails]
    -> AwsEcsServiceDetails)
-> Lens
     AwsEcsServiceDetails
     AwsEcsServiceDetails
     (Maybe [AwsEcsServicePlacementStrategiesDetails])
     (Maybe [AwsEcsServicePlacementStrategiesDetails])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsEcsServiceDetails' {Maybe [AwsEcsServicePlacementStrategiesDetails]
placementStrategies :: Maybe [AwsEcsServicePlacementStrategiesDetails]
$sel:placementStrategies:AwsEcsServiceDetails' :: AwsEcsServiceDetails
-> Maybe [AwsEcsServicePlacementStrategiesDetails]
placementStrategies} -> Maybe [AwsEcsServicePlacementStrategiesDetails]
placementStrategies) (\s :: AwsEcsServiceDetails
s@AwsEcsServiceDetails' {} Maybe [AwsEcsServicePlacementStrategiesDetails]
a -> AwsEcsServiceDetails
s {$sel:placementStrategies:AwsEcsServiceDetails' :: Maybe [AwsEcsServicePlacementStrategiesDetails]
placementStrategies = Maybe [AwsEcsServicePlacementStrategiesDetails]
a} :: AwsEcsServiceDetails) ((Maybe [AwsEcsServicePlacementStrategiesDetails]
  -> f (Maybe [AwsEcsServicePlacementStrategiesDetails]))
 -> AwsEcsServiceDetails -> f AwsEcsServiceDetails)
-> ((Maybe [AwsEcsServicePlacementStrategiesDetails]
     -> f (Maybe [AwsEcsServicePlacementStrategiesDetails]))
    -> Maybe [AwsEcsServicePlacementStrategiesDetails]
    -> f (Maybe [AwsEcsServicePlacementStrategiesDetails]))
-> (Maybe [AwsEcsServicePlacementStrategiesDetails]
    -> f (Maybe [AwsEcsServicePlacementStrategiesDetails]))
-> AwsEcsServiceDetails
-> f AwsEcsServiceDetails
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
  [AwsEcsServicePlacementStrategiesDetails]
  [AwsEcsServicePlacementStrategiesDetails]
  [AwsEcsServicePlacementStrategiesDetails]
  [AwsEcsServicePlacementStrategiesDetails]
-> Iso
     (Maybe [AwsEcsServicePlacementStrategiesDetails])
     (Maybe [AwsEcsServicePlacementStrategiesDetails])
     (Maybe [AwsEcsServicePlacementStrategiesDetails])
     (Maybe [AwsEcsServicePlacementStrategiesDetails])
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
  [AwsEcsServicePlacementStrategiesDetails]
  [AwsEcsServicePlacementStrategiesDetails]
  [AwsEcsServicePlacementStrategiesDetails]
  [AwsEcsServicePlacementStrategiesDetails]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | The ARN of the cluster that hosts the service.
awsEcsServiceDetails_cluster :: Lens.Lens' AwsEcsServiceDetails (Prelude.Maybe Prelude.Text)
awsEcsServiceDetails_cluster :: (Maybe Text -> f (Maybe Text))
-> AwsEcsServiceDetails -> f AwsEcsServiceDetails
awsEcsServiceDetails_cluster = (AwsEcsServiceDetails -> Maybe Text)
-> (AwsEcsServiceDetails -> Maybe Text -> AwsEcsServiceDetails)
-> Lens
     AwsEcsServiceDetails AwsEcsServiceDetails (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsEcsServiceDetails' {Maybe Text
cluster :: Maybe Text
$sel:cluster:AwsEcsServiceDetails' :: AwsEcsServiceDetails -> Maybe Text
cluster} -> Maybe Text
cluster) (\s :: AwsEcsServiceDetails
s@AwsEcsServiceDetails' {} Maybe Text
a -> AwsEcsServiceDetails
s {$sel:cluster:AwsEcsServiceDetails' :: Maybe Text
cluster = Maybe Text
a} :: AwsEcsServiceDetails)

-- | Indicates whether to propagate the tags from the task definition to the
-- task or from the service to the task. If no value is provided, then tags
-- are not propagated.
--
-- Valid values: @TASK_DEFINITION@ | @SERVICE@
awsEcsServiceDetails_propagateTags :: Lens.Lens' AwsEcsServiceDetails (Prelude.Maybe Prelude.Text)
awsEcsServiceDetails_propagateTags :: (Maybe Text -> f (Maybe Text))
-> AwsEcsServiceDetails -> f AwsEcsServiceDetails
awsEcsServiceDetails_propagateTags = (AwsEcsServiceDetails -> Maybe Text)
-> (AwsEcsServiceDetails -> Maybe Text -> AwsEcsServiceDetails)
-> Lens
     AwsEcsServiceDetails AwsEcsServiceDetails (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsEcsServiceDetails' {Maybe Text
propagateTags :: Maybe Text
$sel:propagateTags:AwsEcsServiceDetails' :: AwsEcsServiceDetails -> Maybe Text
propagateTags} -> Maybe Text
propagateTags) (\s :: AwsEcsServiceDetails
s@AwsEcsServiceDetails' {} Maybe Text
a -> AwsEcsServiceDetails
s {$sel:propagateTags:AwsEcsServiceDetails' :: Maybe Text
propagateTags = Maybe Text
a} :: AwsEcsServiceDetails)

-- | The platform version on which to run the service. Only specified for
-- tasks that are hosted on Fargate. If a platform version is not
-- specified, the @LATEST@ platform version is used by default.
awsEcsServiceDetails_platformVersion :: Lens.Lens' AwsEcsServiceDetails (Prelude.Maybe Prelude.Text)
awsEcsServiceDetails_platformVersion :: (Maybe Text -> f (Maybe Text))
-> AwsEcsServiceDetails -> f AwsEcsServiceDetails
awsEcsServiceDetails_platformVersion = (AwsEcsServiceDetails -> Maybe Text)
-> (AwsEcsServiceDetails -> Maybe Text -> AwsEcsServiceDetails)
-> Lens
     AwsEcsServiceDetails AwsEcsServiceDetails (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsEcsServiceDetails' {Maybe Text
platformVersion :: Maybe Text
$sel:platformVersion:AwsEcsServiceDetails' :: AwsEcsServiceDetails -> Maybe Text
platformVersion} -> Maybe Text
platformVersion) (\s :: AwsEcsServiceDetails
s@AwsEcsServiceDetails' {} Maybe Text
a -> AwsEcsServiceDetails
s {$sel:platformVersion:AwsEcsServiceDetails' :: Maybe Text
platformVersion = Maybe Text
a} :: AwsEcsServiceDetails)

-- | Whether to enable Amazon ECS managed tags for the tasks in the service.
awsEcsServiceDetails_enableEcsManagedTags :: Lens.Lens' AwsEcsServiceDetails (Prelude.Maybe Prelude.Bool)
awsEcsServiceDetails_enableEcsManagedTags :: (Maybe Bool -> f (Maybe Bool))
-> AwsEcsServiceDetails -> f AwsEcsServiceDetails
awsEcsServiceDetails_enableEcsManagedTags = (AwsEcsServiceDetails -> Maybe Bool)
-> (AwsEcsServiceDetails -> Maybe Bool -> AwsEcsServiceDetails)
-> Lens
     AwsEcsServiceDetails AwsEcsServiceDetails (Maybe Bool) (Maybe Bool)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsEcsServiceDetails' {Maybe Bool
enableEcsManagedTags :: Maybe Bool
$sel:enableEcsManagedTags:AwsEcsServiceDetails' :: AwsEcsServiceDetails -> Maybe Bool
enableEcsManagedTags} -> Maybe Bool
enableEcsManagedTags) (\s :: AwsEcsServiceDetails
s@AwsEcsServiceDetails' {} Maybe Bool
a -> AwsEcsServiceDetails
s {$sel:enableEcsManagedTags:AwsEcsServiceDetails' :: Maybe Bool
enableEcsManagedTags = Maybe Bool
a} :: AwsEcsServiceDetails)

-- | The number of instantiations of the task definition to run on the
-- service.
awsEcsServiceDetails_desiredCount :: Lens.Lens' AwsEcsServiceDetails (Prelude.Maybe Prelude.Int)
awsEcsServiceDetails_desiredCount :: (Maybe Int -> f (Maybe Int))
-> AwsEcsServiceDetails -> f AwsEcsServiceDetails
awsEcsServiceDetails_desiredCount = (AwsEcsServiceDetails -> Maybe Int)
-> (AwsEcsServiceDetails -> Maybe Int -> AwsEcsServiceDetails)
-> Lens
     AwsEcsServiceDetails AwsEcsServiceDetails (Maybe Int) (Maybe Int)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsEcsServiceDetails' {Maybe Int
desiredCount :: Maybe Int
$sel:desiredCount:AwsEcsServiceDetails' :: AwsEcsServiceDetails -> Maybe Int
desiredCount} -> Maybe Int
desiredCount) (\s :: AwsEcsServiceDetails
s@AwsEcsServiceDetails' {} Maybe Int
a -> AwsEcsServiceDetails
s {$sel:desiredCount:AwsEcsServiceDetails' :: Maybe Int
desiredCount = Maybe Int
a} :: AwsEcsServiceDetails)

-- | Information about the load balancers that the service uses.
awsEcsServiceDetails_loadBalancers :: Lens.Lens' AwsEcsServiceDetails (Prelude.Maybe [AwsEcsServiceLoadBalancersDetails])
awsEcsServiceDetails_loadBalancers :: (Maybe [AwsEcsServiceLoadBalancersDetails]
 -> f (Maybe [AwsEcsServiceLoadBalancersDetails]))
-> AwsEcsServiceDetails -> f AwsEcsServiceDetails
awsEcsServiceDetails_loadBalancers = (AwsEcsServiceDetails -> Maybe [AwsEcsServiceLoadBalancersDetails])
-> (AwsEcsServiceDetails
    -> Maybe [AwsEcsServiceLoadBalancersDetails]
    -> AwsEcsServiceDetails)
-> Lens
     AwsEcsServiceDetails
     AwsEcsServiceDetails
     (Maybe [AwsEcsServiceLoadBalancersDetails])
     (Maybe [AwsEcsServiceLoadBalancersDetails])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsEcsServiceDetails' {Maybe [AwsEcsServiceLoadBalancersDetails]
loadBalancers :: Maybe [AwsEcsServiceLoadBalancersDetails]
$sel:loadBalancers:AwsEcsServiceDetails' :: AwsEcsServiceDetails -> Maybe [AwsEcsServiceLoadBalancersDetails]
loadBalancers} -> Maybe [AwsEcsServiceLoadBalancersDetails]
loadBalancers) (\s :: AwsEcsServiceDetails
s@AwsEcsServiceDetails' {} Maybe [AwsEcsServiceLoadBalancersDetails]
a -> AwsEcsServiceDetails
s {$sel:loadBalancers:AwsEcsServiceDetails' :: Maybe [AwsEcsServiceLoadBalancersDetails]
loadBalancers = Maybe [AwsEcsServiceLoadBalancersDetails]
a} :: AwsEcsServiceDetails) ((Maybe [AwsEcsServiceLoadBalancersDetails]
  -> f (Maybe [AwsEcsServiceLoadBalancersDetails]))
 -> AwsEcsServiceDetails -> f AwsEcsServiceDetails)
-> ((Maybe [AwsEcsServiceLoadBalancersDetails]
     -> f (Maybe [AwsEcsServiceLoadBalancersDetails]))
    -> Maybe [AwsEcsServiceLoadBalancersDetails]
    -> f (Maybe [AwsEcsServiceLoadBalancersDetails]))
-> (Maybe [AwsEcsServiceLoadBalancersDetails]
    -> f (Maybe [AwsEcsServiceLoadBalancersDetails]))
-> AwsEcsServiceDetails
-> f AwsEcsServiceDetails
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
  [AwsEcsServiceLoadBalancersDetails]
  [AwsEcsServiceLoadBalancersDetails]
  [AwsEcsServiceLoadBalancersDetails]
  [AwsEcsServiceLoadBalancersDetails]
-> Iso
     (Maybe [AwsEcsServiceLoadBalancersDetails])
     (Maybe [AwsEcsServiceLoadBalancersDetails])
     (Maybe [AwsEcsServiceLoadBalancersDetails])
     (Maybe [AwsEcsServiceLoadBalancersDetails])
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
  [AwsEcsServiceLoadBalancersDetails]
  [AwsEcsServiceLoadBalancersDetails]
  [AwsEcsServiceLoadBalancersDetails]
  [AwsEcsServiceLoadBalancersDetails]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | The ARN of the IAM role that is associated with the service. The role
-- allows the Amazon ECS container agent to register container instances
-- with an Elastic Load Balancing load balancer.
awsEcsServiceDetails_role :: Lens.Lens' AwsEcsServiceDetails (Prelude.Maybe Prelude.Text)
awsEcsServiceDetails_role :: (Maybe Text -> f (Maybe Text))
-> AwsEcsServiceDetails -> f AwsEcsServiceDetails
awsEcsServiceDetails_role = (AwsEcsServiceDetails -> Maybe Text)
-> (AwsEcsServiceDetails -> Maybe Text -> AwsEcsServiceDetails)
-> Lens
     AwsEcsServiceDetails AwsEcsServiceDetails (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsEcsServiceDetails' {Maybe Text
role' :: Maybe Text
$sel:role':AwsEcsServiceDetails' :: AwsEcsServiceDetails -> Maybe Text
role'} -> Maybe Text
role') (\s :: AwsEcsServiceDetails
s@AwsEcsServiceDetails' {} Maybe Text
a -> AwsEcsServiceDetails
s {$sel:role':AwsEcsServiceDetails' :: Maybe Text
role' = Maybe Text
a} :: AwsEcsServiceDetails)

-- | The name of the service.
awsEcsServiceDetails_name :: Lens.Lens' AwsEcsServiceDetails (Prelude.Maybe Prelude.Text)
awsEcsServiceDetails_name :: (Maybe Text -> f (Maybe Text))
-> AwsEcsServiceDetails -> f AwsEcsServiceDetails
awsEcsServiceDetails_name = (AwsEcsServiceDetails -> Maybe Text)
-> (AwsEcsServiceDetails -> Maybe Text -> AwsEcsServiceDetails)
-> Lens
     AwsEcsServiceDetails AwsEcsServiceDetails (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsEcsServiceDetails' {Maybe Text
name :: Maybe Text
$sel:name:AwsEcsServiceDetails' :: AwsEcsServiceDetails -> Maybe Text
name} -> Maybe Text
name) (\s :: AwsEcsServiceDetails
s@AwsEcsServiceDetails' {} Maybe Text
a -> AwsEcsServiceDetails
s {$sel:name:AwsEcsServiceDetails' :: Maybe Text
name = Maybe Text
a} :: AwsEcsServiceDetails)

-- | The placement constraints for the tasks in the service.
awsEcsServiceDetails_placementConstraints :: Lens.Lens' AwsEcsServiceDetails (Prelude.Maybe [AwsEcsServicePlacementConstraintsDetails])
awsEcsServiceDetails_placementConstraints :: (Maybe [AwsEcsServicePlacementConstraintsDetails]
 -> f (Maybe [AwsEcsServicePlacementConstraintsDetails]))
-> AwsEcsServiceDetails -> f AwsEcsServiceDetails
awsEcsServiceDetails_placementConstraints = (AwsEcsServiceDetails
 -> Maybe [AwsEcsServicePlacementConstraintsDetails])
-> (AwsEcsServiceDetails
    -> Maybe [AwsEcsServicePlacementConstraintsDetails]
    -> AwsEcsServiceDetails)
-> Lens
     AwsEcsServiceDetails
     AwsEcsServiceDetails
     (Maybe [AwsEcsServicePlacementConstraintsDetails])
     (Maybe [AwsEcsServicePlacementConstraintsDetails])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsEcsServiceDetails' {Maybe [AwsEcsServicePlacementConstraintsDetails]
placementConstraints :: Maybe [AwsEcsServicePlacementConstraintsDetails]
$sel:placementConstraints:AwsEcsServiceDetails' :: AwsEcsServiceDetails
-> Maybe [AwsEcsServicePlacementConstraintsDetails]
placementConstraints} -> Maybe [AwsEcsServicePlacementConstraintsDetails]
placementConstraints) (\s :: AwsEcsServiceDetails
s@AwsEcsServiceDetails' {} Maybe [AwsEcsServicePlacementConstraintsDetails]
a -> AwsEcsServiceDetails
s {$sel:placementConstraints:AwsEcsServiceDetails' :: Maybe [AwsEcsServicePlacementConstraintsDetails]
placementConstraints = Maybe [AwsEcsServicePlacementConstraintsDetails]
a} :: AwsEcsServiceDetails) ((Maybe [AwsEcsServicePlacementConstraintsDetails]
  -> f (Maybe [AwsEcsServicePlacementConstraintsDetails]))
 -> AwsEcsServiceDetails -> f AwsEcsServiceDetails)
-> ((Maybe [AwsEcsServicePlacementConstraintsDetails]
     -> f (Maybe [AwsEcsServicePlacementConstraintsDetails]))
    -> Maybe [AwsEcsServicePlacementConstraintsDetails]
    -> f (Maybe [AwsEcsServicePlacementConstraintsDetails]))
-> (Maybe [AwsEcsServicePlacementConstraintsDetails]
    -> f (Maybe [AwsEcsServicePlacementConstraintsDetails]))
-> AwsEcsServiceDetails
-> f AwsEcsServiceDetails
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
  [AwsEcsServicePlacementConstraintsDetails]
  [AwsEcsServicePlacementConstraintsDetails]
  [AwsEcsServicePlacementConstraintsDetails]
  [AwsEcsServicePlacementConstraintsDetails]
-> Iso
     (Maybe [AwsEcsServicePlacementConstraintsDetails])
     (Maybe [AwsEcsServicePlacementConstraintsDetails])
     (Maybe [AwsEcsServicePlacementConstraintsDetails])
     (Maybe [AwsEcsServicePlacementConstraintsDetails])
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
  [AwsEcsServicePlacementConstraintsDetails]
  [AwsEcsServicePlacementConstraintsDetails]
  [AwsEcsServicePlacementConstraintsDetails]
  [AwsEcsServicePlacementConstraintsDetails]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | The name of the service.
--
-- The name can contain up to 255 characters. It can use letters, numbers,
-- underscores, and hyphens.
awsEcsServiceDetails_serviceName :: Lens.Lens' AwsEcsServiceDetails (Prelude.Maybe Prelude.Text)
awsEcsServiceDetails_serviceName :: (Maybe Text -> f (Maybe Text))
-> AwsEcsServiceDetails -> f AwsEcsServiceDetails
awsEcsServiceDetails_serviceName = (AwsEcsServiceDetails -> Maybe Text)
-> (AwsEcsServiceDetails -> Maybe Text -> AwsEcsServiceDetails)
-> Lens
     AwsEcsServiceDetails AwsEcsServiceDetails (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsEcsServiceDetails' {Maybe Text
serviceName :: Maybe Text
$sel:serviceName:AwsEcsServiceDetails' :: AwsEcsServiceDetails -> Maybe Text
serviceName} -> Maybe Text
serviceName) (\s :: AwsEcsServiceDetails
s@AwsEcsServiceDetails' {} Maybe Text
a -> AwsEcsServiceDetails
s {$sel:serviceName:AwsEcsServiceDetails' :: Maybe Text
serviceName = Maybe Text
a} :: AwsEcsServiceDetails)

-- | Contains the deployment controller type that the service uses.
awsEcsServiceDetails_deploymentController :: Lens.Lens' AwsEcsServiceDetails (Prelude.Maybe AwsEcsServiceDeploymentControllerDetails)
awsEcsServiceDetails_deploymentController :: (Maybe AwsEcsServiceDeploymentControllerDetails
 -> f (Maybe AwsEcsServiceDeploymentControllerDetails))
-> AwsEcsServiceDetails -> f AwsEcsServiceDetails
awsEcsServiceDetails_deploymentController = (AwsEcsServiceDetails
 -> Maybe AwsEcsServiceDeploymentControllerDetails)
-> (AwsEcsServiceDetails
    -> Maybe AwsEcsServiceDeploymentControllerDetails
    -> AwsEcsServiceDetails)
-> Lens
     AwsEcsServiceDetails
     AwsEcsServiceDetails
     (Maybe AwsEcsServiceDeploymentControllerDetails)
     (Maybe AwsEcsServiceDeploymentControllerDetails)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsEcsServiceDetails' {Maybe AwsEcsServiceDeploymentControllerDetails
deploymentController :: Maybe AwsEcsServiceDeploymentControllerDetails
$sel:deploymentController:AwsEcsServiceDetails' :: AwsEcsServiceDetails
-> Maybe AwsEcsServiceDeploymentControllerDetails
deploymentController} -> Maybe AwsEcsServiceDeploymentControllerDetails
deploymentController) (\s :: AwsEcsServiceDetails
s@AwsEcsServiceDetails' {} Maybe AwsEcsServiceDeploymentControllerDetails
a -> AwsEcsServiceDetails
s {$sel:deploymentController:AwsEcsServiceDetails' :: Maybe AwsEcsServiceDeploymentControllerDetails
deploymentController = Maybe AwsEcsServiceDeploymentControllerDetails
a} :: AwsEcsServiceDetails)

-- | The launch type that the service uses.
--
-- Valid values: @EC2@ | @FARGATE@ | @EXTERNAL@
awsEcsServiceDetails_launchType :: Lens.Lens' AwsEcsServiceDetails (Prelude.Maybe Prelude.Text)
awsEcsServiceDetails_launchType :: (Maybe Text -> f (Maybe Text))
-> AwsEcsServiceDetails -> f AwsEcsServiceDetails
awsEcsServiceDetails_launchType = (AwsEcsServiceDetails -> Maybe Text)
-> (AwsEcsServiceDetails -> Maybe Text -> AwsEcsServiceDetails)
-> Lens
     AwsEcsServiceDetails AwsEcsServiceDetails (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsEcsServiceDetails' {Maybe Text
launchType :: Maybe Text
$sel:launchType:AwsEcsServiceDetails' :: AwsEcsServiceDetails -> Maybe Text
launchType} -> Maybe Text
launchType) (\s :: AwsEcsServiceDetails
s@AwsEcsServiceDetails' {} Maybe Text
a -> AwsEcsServiceDetails
s {$sel:launchType:AwsEcsServiceDetails' :: Maybe Text
launchType = Maybe Text
a} :: AwsEcsServiceDetails)

-- | The task definition to use for tasks in the service.
awsEcsServiceDetails_taskDefinition :: Lens.Lens' AwsEcsServiceDetails (Prelude.Maybe Prelude.Text)
awsEcsServiceDetails_taskDefinition :: (Maybe Text -> f (Maybe Text))
-> AwsEcsServiceDetails -> f AwsEcsServiceDetails
awsEcsServiceDetails_taskDefinition = (AwsEcsServiceDetails -> Maybe Text)
-> (AwsEcsServiceDetails -> Maybe Text -> AwsEcsServiceDetails)
-> Lens
     AwsEcsServiceDetails AwsEcsServiceDetails (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsEcsServiceDetails' {Maybe Text
taskDefinition :: Maybe Text
$sel:taskDefinition:AwsEcsServiceDetails' :: AwsEcsServiceDetails -> Maybe Text
taskDefinition} -> Maybe Text
taskDefinition) (\s :: AwsEcsServiceDetails
s@AwsEcsServiceDetails' {} Maybe Text
a -> AwsEcsServiceDetails
s {$sel:taskDefinition:AwsEcsServiceDetails' :: Maybe Text
taskDefinition = Maybe Text
a} :: AwsEcsServiceDetails)

-- | The ARN of the service.
awsEcsServiceDetails_serviceArn :: Lens.Lens' AwsEcsServiceDetails (Prelude.Maybe Prelude.Text)
awsEcsServiceDetails_serviceArn :: (Maybe Text -> f (Maybe Text))
-> AwsEcsServiceDetails -> f AwsEcsServiceDetails
awsEcsServiceDetails_serviceArn = (AwsEcsServiceDetails -> Maybe Text)
-> (AwsEcsServiceDetails -> Maybe Text -> AwsEcsServiceDetails)
-> Lens
     AwsEcsServiceDetails AwsEcsServiceDetails (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsEcsServiceDetails' {Maybe Text
serviceArn :: Maybe Text
$sel:serviceArn:AwsEcsServiceDetails' :: AwsEcsServiceDetails -> Maybe Text
serviceArn} -> Maybe Text
serviceArn) (\s :: AwsEcsServiceDetails
s@AwsEcsServiceDetails' {} Maybe Text
a -> AwsEcsServiceDetails
s {$sel:serviceArn:AwsEcsServiceDetails' :: Maybe Text
serviceArn = Maybe Text
a} :: AwsEcsServiceDetails)

-- | The scheduling strategy to use for the service.
--
-- The @REPLICA@ scheduling strategy places and maintains the desired
-- number of tasks across the cluster. By default, the service scheduler
-- spreads tasks across Availability Zones. Task placement strategies and
-- constraints are used to customize task placement decisions.
--
-- The @DAEMON@ scheduling strategy deploys exactly one task on each active
-- container instance that meets all of the task placement constraints that
-- are specified in the cluster. The service scheduler also evaluates the
-- task placement constraints for running tasks and stops tasks that do not
-- meet the placement constraints.
--
-- Valid values: @REPLICA@ | @DAEMON@
awsEcsServiceDetails_schedulingStrategy :: Lens.Lens' AwsEcsServiceDetails (Prelude.Maybe Prelude.Text)
awsEcsServiceDetails_schedulingStrategy :: (Maybe Text -> f (Maybe Text))
-> AwsEcsServiceDetails -> f AwsEcsServiceDetails
awsEcsServiceDetails_schedulingStrategy = (AwsEcsServiceDetails -> Maybe Text)
-> (AwsEcsServiceDetails -> Maybe Text -> AwsEcsServiceDetails)
-> Lens
     AwsEcsServiceDetails AwsEcsServiceDetails (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsEcsServiceDetails' {Maybe Text
schedulingStrategy :: Maybe Text
$sel:schedulingStrategy:AwsEcsServiceDetails' :: AwsEcsServiceDetails -> Maybe Text
schedulingStrategy} -> Maybe Text
schedulingStrategy) (\s :: AwsEcsServiceDetails
s@AwsEcsServiceDetails' {} Maybe Text
a -> AwsEcsServiceDetails
s {$sel:schedulingStrategy:AwsEcsServiceDetails' :: Maybe Text
schedulingStrategy = Maybe Text
a} :: AwsEcsServiceDetails)

-- | The capacity provider strategy that the service uses.
awsEcsServiceDetails_capacityProviderStrategy :: Lens.Lens' AwsEcsServiceDetails (Prelude.Maybe [AwsEcsServiceCapacityProviderStrategyDetails])
awsEcsServiceDetails_capacityProviderStrategy :: (Maybe [AwsEcsServiceCapacityProviderStrategyDetails]
 -> f (Maybe [AwsEcsServiceCapacityProviderStrategyDetails]))
-> AwsEcsServiceDetails -> f AwsEcsServiceDetails
awsEcsServiceDetails_capacityProviderStrategy = (AwsEcsServiceDetails
 -> Maybe [AwsEcsServiceCapacityProviderStrategyDetails])
-> (AwsEcsServiceDetails
    -> Maybe [AwsEcsServiceCapacityProviderStrategyDetails]
    -> AwsEcsServiceDetails)
-> Lens
     AwsEcsServiceDetails
     AwsEcsServiceDetails
     (Maybe [AwsEcsServiceCapacityProviderStrategyDetails])
     (Maybe [AwsEcsServiceCapacityProviderStrategyDetails])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsEcsServiceDetails' {Maybe [AwsEcsServiceCapacityProviderStrategyDetails]
capacityProviderStrategy :: Maybe [AwsEcsServiceCapacityProviderStrategyDetails]
$sel:capacityProviderStrategy:AwsEcsServiceDetails' :: AwsEcsServiceDetails
-> Maybe [AwsEcsServiceCapacityProviderStrategyDetails]
capacityProviderStrategy} -> Maybe [AwsEcsServiceCapacityProviderStrategyDetails]
capacityProviderStrategy) (\s :: AwsEcsServiceDetails
s@AwsEcsServiceDetails' {} Maybe [AwsEcsServiceCapacityProviderStrategyDetails]
a -> AwsEcsServiceDetails
s {$sel:capacityProviderStrategy:AwsEcsServiceDetails' :: Maybe [AwsEcsServiceCapacityProviderStrategyDetails]
capacityProviderStrategy = Maybe [AwsEcsServiceCapacityProviderStrategyDetails]
a} :: AwsEcsServiceDetails) ((Maybe [AwsEcsServiceCapacityProviderStrategyDetails]
  -> f (Maybe [AwsEcsServiceCapacityProviderStrategyDetails]))
 -> AwsEcsServiceDetails -> f AwsEcsServiceDetails)
-> ((Maybe [AwsEcsServiceCapacityProviderStrategyDetails]
     -> f (Maybe [AwsEcsServiceCapacityProviderStrategyDetails]))
    -> Maybe [AwsEcsServiceCapacityProviderStrategyDetails]
    -> f (Maybe [AwsEcsServiceCapacityProviderStrategyDetails]))
-> (Maybe [AwsEcsServiceCapacityProviderStrategyDetails]
    -> f (Maybe [AwsEcsServiceCapacityProviderStrategyDetails]))
-> AwsEcsServiceDetails
-> f AwsEcsServiceDetails
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
  [AwsEcsServiceCapacityProviderStrategyDetails]
  [AwsEcsServiceCapacityProviderStrategyDetails]
  [AwsEcsServiceCapacityProviderStrategyDetails]
  [AwsEcsServiceCapacityProviderStrategyDetails]
-> Iso
     (Maybe [AwsEcsServiceCapacityProviderStrategyDetails])
     (Maybe [AwsEcsServiceCapacityProviderStrategyDetails])
     (Maybe [AwsEcsServiceCapacityProviderStrategyDetails])
     (Maybe [AwsEcsServiceCapacityProviderStrategyDetails])
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
  [AwsEcsServiceCapacityProviderStrategyDetails]
  [AwsEcsServiceCapacityProviderStrategyDetails]
  [AwsEcsServiceCapacityProviderStrategyDetails]
  [AwsEcsServiceCapacityProviderStrategyDetails]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | Information about the service discovery registries to assign to the
-- service.
awsEcsServiceDetails_serviceRegistries :: Lens.Lens' AwsEcsServiceDetails (Prelude.Maybe [AwsEcsServiceServiceRegistriesDetails])
awsEcsServiceDetails_serviceRegistries :: (Maybe [AwsEcsServiceServiceRegistriesDetails]
 -> f (Maybe [AwsEcsServiceServiceRegistriesDetails]))
-> AwsEcsServiceDetails -> f AwsEcsServiceDetails
awsEcsServiceDetails_serviceRegistries = (AwsEcsServiceDetails
 -> Maybe [AwsEcsServiceServiceRegistriesDetails])
-> (AwsEcsServiceDetails
    -> Maybe [AwsEcsServiceServiceRegistriesDetails]
    -> AwsEcsServiceDetails)
-> Lens
     AwsEcsServiceDetails
     AwsEcsServiceDetails
     (Maybe [AwsEcsServiceServiceRegistriesDetails])
     (Maybe [AwsEcsServiceServiceRegistriesDetails])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsEcsServiceDetails' {Maybe [AwsEcsServiceServiceRegistriesDetails]
serviceRegistries :: Maybe [AwsEcsServiceServiceRegistriesDetails]
$sel:serviceRegistries:AwsEcsServiceDetails' :: AwsEcsServiceDetails
-> Maybe [AwsEcsServiceServiceRegistriesDetails]
serviceRegistries} -> Maybe [AwsEcsServiceServiceRegistriesDetails]
serviceRegistries) (\s :: AwsEcsServiceDetails
s@AwsEcsServiceDetails' {} Maybe [AwsEcsServiceServiceRegistriesDetails]
a -> AwsEcsServiceDetails
s {$sel:serviceRegistries:AwsEcsServiceDetails' :: Maybe [AwsEcsServiceServiceRegistriesDetails]
serviceRegistries = Maybe [AwsEcsServiceServiceRegistriesDetails]
a} :: AwsEcsServiceDetails) ((Maybe [AwsEcsServiceServiceRegistriesDetails]
  -> f (Maybe [AwsEcsServiceServiceRegistriesDetails]))
 -> AwsEcsServiceDetails -> f AwsEcsServiceDetails)
-> ((Maybe [AwsEcsServiceServiceRegistriesDetails]
     -> f (Maybe [AwsEcsServiceServiceRegistriesDetails]))
    -> Maybe [AwsEcsServiceServiceRegistriesDetails]
    -> f (Maybe [AwsEcsServiceServiceRegistriesDetails]))
-> (Maybe [AwsEcsServiceServiceRegistriesDetails]
    -> f (Maybe [AwsEcsServiceServiceRegistriesDetails]))
-> AwsEcsServiceDetails
-> f AwsEcsServiceDetails
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso
  [AwsEcsServiceServiceRegistriesDetails]
  [AwsEcsServiceServiceRegistriesDetails]
  [AwsEcsServiceServiceRegistriesDetails]
  [AwsEcsServiceServiceRegistriesDetails]
-> Iso
     (Maybe [AwsEcsServiceServiceRegistriesDetails])
     (Maybe [AwsEcsServiceServiceRegistriesDetails])
     (Maybe [AwsEcsServiceServiceRegistriesDetails])
     (Maybe [AwsEcsServiceServiceRegistriesDetails])
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
  [AwsEcsServiceServiceRegistriesDetails]
  [AwsEcsServiceServiceRegistriesDetails]
  [AwsEcsServiceServiceRegistriesDetails]
  [AwsEcsServiceServiceRegistriesDetails]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | After a task starts, the amount of time in seconds that the Amazon ECS
-- service scheduler ignores unhealthy Elastic Load Balancing target health
-- checks.
awsEcsServiceDetails_healthCheckGracePeriodSeconds :: Lens.Lens' AwsEcsServiceDetails (Prelude.Maybe Prelude.Int)
awsEcsServiceDetails_healthCheckGracePeriodSeconds :: (Maybe Int -> f (Maybe Int))
-> AwsEcsServiceDetails -> f AwsEcsServiceDetails
awsEcsServiceDetails_healthCheckGracePeriodSeconds = (AwsEcsServiceDetails -> Maybe Int)
-> (AwsEcsServiceDetails -> Maybe Int -> AwsEcsServiceDetails)
-> Lens
     AwsEcsServiceDetails AwsEcsServiceDetails (Maybe Int) (Maybe Int)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsEcsServiceDetails' {Maybe Int
healthCheckGracePeriodSeconds :: Maybe Int
$sel:healthCheckGracePeriodSeconds:AwsEcsServiceDetails' :: AwsEcsServiceDetails -> Maybe Int
healthCheckGracePeriodSeconds} -> Maybe Int
healthCheckGracePeriodSeconds) (\s :: AwsEcsServiceDetails
s@AwsEcsServiceDetails' {} Maybe Int
a -> AwsEcsServiceDetails
s {$sel:healthCheckGracePeriodSeconds:AwsEcsServiceDetails' :: Maybe Int
healthCheckGracePeriodSeconds = Maybe Int
a} :: AwsEcsServiceDetails)

-- | For tasks that use the @awsvpc@ networking mode, the VPC subnet and
-- security group configuration.
awsEcsServiceDetails_networkConfiguration :: Lens.Lens' AwsEcsServiceDetails (Prelude.Maybe AwsEcsServiceNetworkConfigurationDetails)
awsEcsServiceDetails_networkConfiguration :: (Maybe AwsEcsServiceNetworkConfigurationDetails
 -> f (Maybe AwsEcsServiceNetworkConfigurationDetails))
-> AwsEcsServiceDetails -> f AwsEcsServiceDetails
awsEcsServiceDetails_networkConfiguration = (AwsEcsServiceDetails
 -> Maybe AwsEcsServiceNetworkConfigurationDetails)
-> (AwsEcsServiceDetails
    -> Maybe AwsEcsServiceNetworkConfigurationDetails
    -> AwsEcsServiceDetails)
-> Lens
     AwsEcsServiceDetails
     AwsEcsServiceDetails
     (Maybe AwsEcsServiceNetworkConfigurationDetails)
     (Maybe AwsEcsServiceNetworkConfigurationDetails)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsEcsServiceDetails' {Maybe AwsEcsServiceNetworkConfigurationDetails
networkConfiguration :: Maybe AwsEcsServiceNetworkConfigurationDetails
$sel:networkConfiguration:AwsEcsServiceDetails' :: AwsEcsServiceDetails
-> Maybe AwsEcsServiceNetworkConfigurationDetails
networkConfiguration} -> Maybe AwsEcsServiceNetworkConfigurationDetails
networkConfiguration) (\s :: AwsEcsServiceDetails
s@AwsEcsServiceDetails' {} Maybe AwsEcsServiceNetworkConfigurationDetails
a -> AwsEcsServiceDetails
s {$sel:networkConfiguration:AwsEcsServiceDetails' :: Maybe AwsEcsServiceNetworkConfigurationDetails
networkConfiguration = Maybe AwsEcsServiceNetworkConfigurationDetails
a} :: AwsEcsServiceDetails)

-- | Deployment parameters for the service. Includes the number of tasks that
-- run and the order in which to start and stop tasks.
awsEcsServiceDetails_deploymentConfiguration :: Lens.Lens' AwsEcsServiceDetails (Prelude.Maybe AwsEcsServiceDeploymentConfigurationDetails)
awsEcsServiceDetails_deploymentConfiguration :: (Maybe AwsEcsServiceDeploymentConfigurationDetails
 -> f (Maybe AwsEcsServiceDeploymentConfigurationDetails))
-> AwsEcsServiceDetails -> f AwsEcsServiceDetails
awsEcsServiceDetails_deploymentConfiguration = (AwsEcsServiceDetails
 -> Maybe AwsEcsServiceDeploymentConfigurationDetails)
-> (AwsEcsServiceDetails
    -> Maybe AwsEcsServiceDeploymentConfigurationDetails
    -> AwsEcsServiceDetails)
-> Lens
     AwsEcsServiceDetails
     AwsEcsServiceDetails
     (Maybe AwsEcsServiceDeploymentConfigurationDetails)
     (Maybe AwsEcsServiceDeploymentConfigurationDetails)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsEcsServiceDetails' {Maybe AwsEcsServiceDeploymentConfigurationDetails
deploymentConfiguration :: Maybe AwsEcsServiceDeploymentConfigurationDetails
$sel:deploymentConfiguration:AwsEcsServiceDetails' :: AwsEcsServiceDetails
-> Maybe AwsEcsServiceDeploymentConfigurationDetails
deploymentConfiguration} -> Maybe AwsEcsServiceDeploymentConfigurationDetails
deploymentConfiguration) (\s :: AwsEcsServiceDetails
s@AwsEcsServiceDetails' {} Maybe AwsEcsServiceDeploymentConfigurationDetails
a -> AwsEcsServiceDetails
s {$sel:deploymentConfiguration:AwsEcsServiceDetails' :: Maybe AwsEcsServiceDeploymentConfigurationDetails
deploymentConfiguration = Maybe AwsEcsServiceDeploymentConfigurationDetails
a} :: AwsEcsServiceDetails)

-- | Whether the execute command functionality is enabled for the service.
awsEcsServiceDetails_enableExecuteCommand :: Lens.Lens' AwsEcsServiceDetails (Prelude.Maybe Prelude.Bool)
awsEcsServiceDetails_enableExecuteCommand :: (Maybe Bool -> f (Maybe Bool))
-> AwsEcsServiceDetails -> f AwsEcsServiceDetails
awsEcsServiceDetails_enableExecuteCommand = (AwsEcsServiceDetails -> Maybe Bool)
-> (AwsEcsServiceDetails -> Maybe Bool -> AwsEcsServiceDetails)
-> Lens
     AwsEcsServiceDetails AwsEcsServiceDetails (Maybe Bool) (Maybe Bool)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\AwsEcsServiceDetails' {Maybe Bool
enableExecuteCommand :: Maybe Bool
$sel:enableExecuteCommand:AwsEcsServiceDetails' :: AwsEcsServiceDetails -> Maybe Bool
enableExecuteCommand} -> Maybe Bool
enableExecuteCommand) (\s :: AwsEcsServiceDetails
s@AwsEcsServiceDetails' {} Maybe Bool
a -> AwsEcsServiceDetails
s {$sel:enableExecuteCommand:AwsEcsServiceDetails' :: Maybe Bool
enableExecuteCommand = Maybe Bool
a} :: AwsEcsServiceDetails)

instance Core.FromJSON AwsEcsServiceDetails where
  parseJSON :: Value -> Parser AwsEcsServiceDetails
parseJSON =
    String
-> (Object -> Parser AwsEcsServiceDetails)
-> Value
-> Parser AwsEcsServiceDetails
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Core.withObject
      String
"AwsEcsServiceDetails"
      ( \Object
x ->
          Maybe [AwsEcsServicePlacementStrategiesDetails]
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Bool
-> Maybe Int
-> Maybe [AwsEcsServiceLoadBalancersDetails]
-> Maybe Text
-> Maybe Text
-> Maybe [AwsEcsServicePlacementConstraintsDetails]
-> Maybe Text
-> Maybe AwsEcsServiceDeploymentControllerDetails
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe [AwsEcsServiceCapacityProviderStrategyDetails]
-> Maybe [AwsEcsServiceServiceRegistriesDetails]
-> Maybe Int
-> Maybe AwsEcsServiceNetworkConfigurationDetails
-> Maybe AwsEcsServiceDeploymentConfigurationDetails
-> Maybe Bool
-> AwsEcsServiceDetails
AwsEcsServiceDetails'
            (Maybe [AwsEcsServicePlacementStrategiesDetails]
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe Bool
 -> Maybe Int
 -> Maybe [AwsEcsServiceLoadBalancersDetails]
 -> Maybe Text
 -> Maybe Text
 -> Maybe [AwsEcsServicePlacementConstraintsDetails]
 -> Maybe Text
 -> Maybe AwsEcsServiceDeploymentControllerDetails
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe [AwsEcsServiceCapacityProviderStrategyDetails]
 -> Maybe [AwsEcsServiceServiceRegistriesDetails]
 -> Maybe Int
 -> Maybe AwsEcsServiceNetworkConfigurationDetails
 -> Maybe AwsEcsServiceDeploymentConfigurationDetails
 -> Maybe Bool
 -> AwsEcsServiceDetails)
-> Parser (Maybe [AwsEcsServicePlacementStrategiesDetails])
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Int
      -> Maybe [AwsEcsServiceLoadBalancersDetails]
      -> Maybe Text
      -> Maybe Text
      -> Maybe [AwsEcsServicePlacementConstraintsDetails]
      -> Maybe Text
      -> Maybe AwsEcsServiceDeploymentControllerDetails
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe [AwsEcsServiceCapacityProviderStrategyDetails]
      -> Maybe [AwsEcsServiceServiceRegistriesDetails]
      -> Maybe Int
      -> Maybe AwsEcsServiceNetworkConfigurationDetails
      -> Maybe AwsEcsServiceDeploymentConfigurationDetails
      -> Maybe Bool
      -> AwsEcsServiceDetails)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> ( Object
x Object
-> Text
-> Parser (Maybe (Maybe [AwsEcsServicePlacementStrategiesDetails]))
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"PlacementStrategies"
                            Parser (Maybe (Maybe [AwsEcsServicePlacementStrategiesDetails]))
-> Maybe [AwsEcsServicePlacementStrategiesDetails]
-> Parser (Maybe [AwsEcsServicePlacementStrategiesDetails])
forall a. Parser (Maybe a) -> a -> Parser a
Core..!= Maybe [AwsEcsServicePlacementStrategiesDetails]
forall a. Monoid a => a
Prelude.mempty
                        )
            Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Int
   -> Maybe [AwsEcsServiceLoadBalancersDetails]
   -> Maybe Text
   -> Maybe Text
   -> Maybe [AwsEcsServicePlacementConstraintsDetails]
   -> Maybe Text
   -> Maybe AwsEcsServiceDeploymentControllerDetails
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe [AwsEcsServiceCapacityProviderStrategyDetails]
   -> Maybe [AwsEcsServiceServiceRegistriesDetails]
   -> Maybe Int
   -> Maybe AwsEcsServiceNetworkConfigurationDetails
   -> Maybe AwsEcsServiceDeploymentConfigurationDetails
   -> Maybe Bool
   -> AwsEcsServiceDetails)
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Int
      -> Maybe [AwsEcsServiceLoadBalancersDetails]
      -> Maybe Text
      -> Maybe Text
      -> Maybe [AwsEcsServicePlacementConstraintsDetails]
      -> Maybe Text
      -> Maybe AwsEcsServiceDeploymentControllerDetails
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe [AwsEcsServiceCapacityProviderStrategyDetails]
      -> Maybe [AwsEcsServiceServiceRegistriesDetails]
      -> Maybe Int
      -> Maybe AwsEcsServiceNetworkConfigurationDetails
      -> Maybe AwsEcsServiceDeploymentConfigurationDetails
      -> Maybe Bool
      -> AwsEcsServiceDetails)
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
"Cluster")
            Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Int
   -> Maybe [AwsEcsServiceLoadBalancersDetails]
   -> Maybe Text
   -> Maybe Text
   -> Maybe [AwsEcsServicePlacementConstraintsDetails]
   -> Maybe Text
   -> Maybe AwsEcsServiceDeploymentControllerDetails
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe [AwsEcsServiceCapacityProviderStrategyDetails]
   -> Maybe [AwsEcsServiceServiceRegistriesDetails]
   -> Maybe Int
   -> Maybe AwsEcsServiceNetworkConfigurationDetails
   -> Maybe AwsEcsServiceDeploymentConfigurationDetails
   -> Maybe Bool
   -> AwsEcsServiceDetails)
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe Bool
      -> Maybe Int
      -> Maybe [AwsEcsServiceLoadBalancersDetails]
      -> Maybe Text
      -> Maybe Text
      -> Maybe [AwsEcsServicePlacementConstraintsDetails]
      -> Maybe Text
      -> Maybe AwsEcsServiceDeploymentControllerDetails
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe [AwsEcsServiceCapacityProviderStrategyDetails]
      -> Maybe [AwsEcsServiceServiceRegistriesDetails]
      -> Maybe Int
      -> Maybe AwsEcsServiceNetworkConfigurationDetails
      -> Maybe AwsEcsServiceDeploymentConfigurationDetails
      -> Maybe Bool
      -> AwsEcsServiceDetails)
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
"PropagateTags")
            Parser
  (Maybe Text
   -> Maybe Bool
   -> Maybe Int
   -> Maybe [AwsEcsServiceLoadBalancersDetails]
   -> Maybe Text
   -> Maybe Text
   -> Maybe [AwsEcsServicePlacementConstraintsDetails]
   -> Maybe Text
   -> Maybe AwsEcsServiceDeploymentControllerDetails
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe [AwsEcsServiceCapacityProviderStrategyDetails]
   -> Maybe [AwsEcsServiceServiceRegistriesDetails]
   -> Maybe Int
   -> Maybe AwsEcsServiceNetworkConfigurationDetails
   -> Maybe AwsEcsServiceDeploymentConfigurationDetails
   -> Maybe Bool
   -> AwsEcsServiceDetails)
-> Parser (Maybe Text)
-> Parser
     (Maybe Bool
      -> Maybe Int
      -> Maybe [AwsEcsServiceLoadBalancersDetails]
      -> Maybe Text
      -> Maybe Text
      -> Maybe [AwsEcsServicePlacementConstraintsDetails]
      -> Maybe Text
      -> Maybe AwsEcsServiceDeploymentControllerDetails
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe [AwsEcsServiceCapacityProviderStrategyDetails]
      -> Maybe [AwsEcsServiceServiceRegistriesDetails]
      -> Maybe Int
      -> Maybe AwsEcsServiceNetworkConfigurationDetails
      -> Maybe AwsEcsServiceDeploymentConfigurationDetails
      -> Maybe Bool
      -> AwsEcsServiceDetails)
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
"PlatformVersion")
            Parser
  (Maybe Bool
   -> Maybe Int
   -> Maybe [AwsEcsServiceLoadBalancersDetails]
   -> Maybe Text
   -> Maybe Text
   -> Maybe [AwsEcsServicePlacementConstraintsDetails]
   -> Maybe Text
   -> Maybe AwsEcsServiceDeploymentControllerDetails
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe [AwsEcsServiceCapacityProviderStrategyDetails]
   -> Maybe [AwsEcsServiceServiceRegistriesDetails]
   -> Maybe Int
   -> Maybe AwsEcsServiceNetworkConfigurationDetails
   -> Maybe AwsEcsServiceDeploymentConfigurationDetails
   -> Maybe Bool
   -> AwsEcsServiceDetails)
-> Parser (Maybe Bool)
-> Parser
     (Maybe Int
      -> Maybe [AwsEcsServiceLoadBalancersDetails]
      -> Maybe Text
      -> Maybe Text
      -> Maybe [AwsEcsServicePlacementConstraintsDetails]
      -> Maybe Text
      -> Maybe AwsEcsServiceDeploymentControllerDetails
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe [AwsEcsServiceCapacityProviderStrategyDetails]
      -> Maybe [AwsEcsServiceServiceRegistriesDetails]
      -> Maybe Int
      -> Maybe AwsEcsServiceNetworkConfigurationDetails
      -> Maybe AwsEcsServiceDeploymentConfigurationDetails
      -> Maybe Bool
      -> AwsEcsServiceDetails)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Bool)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"EnableEcsManagedTags")
            Parser
  (Maybe Int
   -> Maybe [AwsEcsServiceLoadBalancersDetails]
   -> Maybe Text
   -> Maybe Text
   -> Maybe [AwsEcsServicePlacementConstraintsDetails]
   -> Maybe Text
   -> Maybe AwsEcsServiceDeploymentControllerDetails
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe [AwsEcsServiceCapacityProviderStrategyDetails]
   -> Maybe [AwsEcsServiceServiceRegistriesDetails]
   -> Maybe Int
   -> Maybe AwsEcsServiceNetworkConfigurationDetails
   -> Maybe AwsEcsServiceDeploymentConfigurationDetails
   -> Maybe Bool
   -> AwsEcsServiceDetails)
-> Parser (Maybe Int)
-> Parser
     (Maybe [AwsEcsServiceLoadBalancersDetails]
      -> Maybe Text
      -> Maybe Text
      -> Maybe [AwsEcsServicePlacementConstraintsDetails]
      -> Maybe Text
      -> Maybe AwsEcsServiceDeploymentControllerDetails
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe [AwsEcsServiceCapacityProviderStrategyDetails]
      -> Maybe [AwsEcsServiceServiceRegistriesDetails]
      -> Maybe Int
      -> Maybe AwsEcsServiceNetworkConfigurationDetails
      -> Maybe AwsEcsServiceDeploymentConfigurationDetails
      -> Maybe Bool
      -> AwsEcsServiceDetails)
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
"DesiredCount")
            Parser
  (Maybe [AwsEcsServiceLoadBalancersDetails]
   -> Maybe Text
   -> Maybe Text
   -> Maybe [AwsEcsServicePlacementConstraintsDetails]
   -> Maybe Text
   -> Maybe AwsEcsServiceDeploymentControllerDetails
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe [AwsEcsServiceCapacityProviderStrategyDetails]
   -> Maybe [AwsEcsServiceServiceRegistriesDetails]
   -> Maybe Int
   -> Maybe AwsEcsServiceNetworkConfigurationDetails
   -> Maybe AwsEcsServiceDeploymentConfigurationDetails
   -> Maybe Bool
   -> AwsEcsServiceDetails)
-> Parser (Maybe [AwsEcsServiceLoadBalancersDetails])
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe [AwsEcsServicePlacementConstraintsDetails]
      -> Maybe Text
      -> Maybe AwsEcsServiceDeploymentControllerDetails
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe [AwsEcsServiceCapacityProviderStrategyDetails]
      -> Maybe [AwsEcsServiceServiceRegistriesDetails]
      -> Maybe Int
      -> Maybe AwsEcsServiceNetworkConfigurationDetails
      -> Maybe AwsEcsServiceDeploymentConfigurationDetails
      -> Maybe Bool
      -> AwsEcsServiceDetails)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object
-> Text
-> Parser (Maybe (Maybe [AwsEcsServiceLoadBalancersDetails]))
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"LoadBalancers" Parser (Maybe (Maybe [AwsEcsServiceLoadBalancersDetails]))
-> Maybe [AwsEcsServiceLoadBalancersDetails]
-> Parser (Maybe [AwsEcsServiceLoadBalancersDetails])
forall a. Parser (Maybe a) -> a -> Parser a
Core..!= Maybe [AwsEcsServiceLoadBalancersDetails]
forall a. Monoid a => a
Prelude.mempty)
            Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe [AwsEcsServicePlacementConstraintsDetails]
   -> Maybe Text
   -> Maybe AwsEcsServiceDeploymentControllerDetails
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe [AwsEcsServiceCapacityProviderStrategyDetails]
   -> Maybe [AwsEcsServiceServiceRegistriesDetails]
   -> Maybe Int
   -> Maybe AwsEcsServiceNetworkConfigurationDetails
   -> Maybe AwsEcsServiceDeploymentConfigurationDetails
   -> Maybe Bool
   -> AwsEcsServiceDetails)
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe [AwsEcsServicePlacementConstraintsDetails]
      -> Maybe Text
      -> Maybe AwsEcsServiceDeploymentControllerDetails
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe [AwsEcsServiceCapacityProviderStrategyDetails]
      -> Maybe [AwsEcsServiceServiceRegistriesDetails]
      -> Maybe Int
      -> Maybe AwsEcsServiceNetworkConfigurationDetails
      -> Maybe AwsEcsServiceDeploymentConfigurationDetails
      -> Maybe Bool
      -> AwsEcsServiceDetails)
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
"Role")
            Parser
  (Maybe Text
   -> Maybe [AwsEcsServicePlacementConstraintsDetails]
   -> Maybe Text
   -> Maybe AwsEcsServiceDeploymentControllerDetails
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe [AwsEcsServiceCapacityProviderStrategyDetails]
   -> Maybe [AwsEcsServiceServiceRegistriesDetails]
   -> Maybe Int
   -> Maybe AwsEcsServiceNetworkConfigurationDetails
   -> Maybe AwsEcsServiceDeploymentConfigurationDetails
   -> Maybe Bool
   -> AwsEcsServiceDetails)
-> Parser (Maybe Text)
-> Parser
     (Maybe [AwsEcsServicePlacementConstraintsDetails]
      -> Maybe Text
      -> Maybe AwsEcsServiceDeploymentControllerDetails
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe [AwsEcsServiceCapacityProviderStrategyDetails]
      -> Maybe [AwsEcsServiceServiceRegistriesDetails]
      -> Maybe Int
      -> Maybe AwsEcsServiceNetworkConfigurationDetails
      -> Maybe AwsEcsServiceDeploymentConfigurationDetails
      -> Maybe Bool
      -> AwsEcsServiceDetails)
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 [AwsEcsServicePlacementConstraintsDetails]
   -> Maybe Text
   -> Maybe AwsEcsServiceDeploymentControllerDetails
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe [AwsEcsServiceCapacityProviderStrategyDetails]
   -> Maybe [AwsEcsServiceServiceRegistriesDetails]
   -> Maybe Int
   -> Maybe AwsEcsServiceNetworkConfigurationDetails
   -> Maybe AwsEcsServiceDeploymentConfigurationDetails
   -> Maybe Bool
   -> AwsEcsServiceDetails)
-> Parser (Maybe [AwsEcsServicePlacementConstraintsDetails])
-> Parser
     (Maybe Text
      -> Maybe AwsEcsServiceDeploymentControllerDetails
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe [AwsEcsServiceCapacityProviderStrategyDetails]
      -> Maybe [AwsEcsServiceServiceRegistriesDetails]
      -> Maybe Int
      -> Maybe AwsEcsServiceNetworkConfigurationDetails
      -> Maybe AwsEcsServiceDeploymentConfigurationDetails
      -> Maybe Bool
      -> AwsEcsServiceDetails)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ( Object
x Object
-> Text
-> Parser
     (Maybe (Maybe [AwsEcsServicePlacementConstraintsDetails]))
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"PlacementConstraints"
                            Parser (Maybe (Maybe [AwsEcsServicePlacementConstraintsDetails]))
-> Maybe [AwsEcsServicePlacementConstraintsDetails]
-> Parser (Maybe [AwsEcsServicePlacementConstraintsDetails])
forall a. Parser (Maybe a) -> a -> Parser a
Core..!= Maybe [AwsEcsServicePlacementConstraintsDetails]
forall a. Monoid a => a
Prelude.mempty
                        )
            Parser
  (Maybe Text
   -> Maybe AwsEcsServiceDeploymentControllerDetails
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe [AwsEcsServiceCapacityProviderStrategyDetails]
   -> Maybe [AwsEcsServiceServiceRegistriesDetails]
   -> Maybe Int
   -> Maybe AwsEcsServiceNetworkConfigurationDetails
   -> Maybe AwsEcsServiceDeploymentConfigurationDetails
   -> Maybe Bool
   -> AwsEcsServiceDetails)
-> Parser (Maybe Text)
-> Parser
     (Maybe AwsEcsServiceDeploymentControllerDetails
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe [AwsEcsServiceCapacityProviderStrategyDetails]
      -> Maybe [AwsEcsServiceServiceRegistriesDetails]
      -> Maybe Int
      -> Maybe AwsEcsServiceNetworkConfigurationDetails
      -> Maybe AwsEcsServiceDeploymentConfigurationDetails
      -> Maybe Bool
      -> AwsEcsServiceDetails)
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
"ServiceName")
            Parser
  (Maybe AwsEcsServiceDeploymentControllerDetails
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe [AwsEcsServiceCapacityProviderStrategyDetails]
   -> Maybe [AwsEcsServiceServiceRegistriesDetails]
   -> Maybe Int
   -> Maybe AwsEcsServiceNetworkConfigurationDetails
   -> Maybe AwsEcsServiceDeploymentConfigurationDetails
   -> Maybe Bool
   -> AwsEcsServiceDetails)
-> Parser (Maybe AwsEcsServiceDeploymentControllerDetails)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe [AwsEcsServiceCapacityProviderStrategyDetails]
      -> Maybe [AwsEcsServiceServiceRegistriesDetails]
      -> Maybe Int
      -> Maybe AwsEcsServiceNetworkConfigurationDetails
      -> Maybe AwsEcsServiceDeploymentConfigurationDetails
      -> Maybe Bool
      -> AwsEcsServiceDetails)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object
-> Text -> Parser (Maybe AwsEcsServiceDeploymentControllerDetails)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"DeploymentController")
            Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe [AwsEcsServiceCapacityProviderStrategyDetails]
   -> Maybe [AwsEcsServiceServiceRegistriesDetails]
   -> Maybe Int
   -> Maybe AwsEcsServiceNetworkConfigurationDetails
   -> Maybe AwsEcsServiceDeploymentConfigurationDetails
   -> Maybe Bool
   -> AwsEcsServiceDetails)
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe [AwsEcsServiceCapacityProviderStrategyDetails]
      -> Maybe [AwsEcsServiceServiceRegistriesDetails]
      -> Maybe Int
      -> Maybe AwsEcsServiceNetworkConfigurationDetails
      -> Maybe AwsEcsServiceDeploymentConfigurationDetails
      -> Maybe Bool
      -> AwsEcsServiceDetails)
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
"LaunchType")
            Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe [AwsEcsServiceCapacityProviderStrategyDetails]
   -> Maybe [AwsEcsServiceServiceRegistriesDetails]
   -> Maybe Int
   -> Maybe AwsEcsServiceNetworkConfigurationDetails
   -> Maybe AwsEcsServiceDeploymentConfigurationDetails
   -> Maybe Bool
   -> AwsEcsServiceDetails)
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe [AwsEcsServiceCapacityProviderStrategyDetails]
      -> Maybe [AwsEcsServiceServiceRegistriesDetails]
      -> Maybe Int
      -> Maybe AwsEcsServiceNetworkConfigurationDetails
      -> Maybe AwsEcsServiceDeploymentConfigurationDetails
      -> Maybe Bool
      -> AwsEcsServiceDetails)
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
"TaskDefinition")
            Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe [AwsEcsServiceCapacityProviderStrategyDetails]
   -> Maybe [AwsEcsServiceServiceRegistriesDetails]
   -> Maybe Int
   -> Maybe AwsEcsServiceNetworkConfigurationDetails
   -> Maybe AwsEcsServiceDeploymentConfigurationDetails
   -> Maybe Bool
   -> AwsEcsServiceDetails)
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe [AwsEcsServiceCapacityProviderStrategyDetails]
      -> Maybe [AwsEcsServiceServiceRegistriesDetails]
      -> Maybe Int
      -> Maybe AwsEcsServiceNetworkConfigurationDetails
      -> Maybe AwsEcsServiceDeploymentConfigurationDetails
      -> Maybe Bool
      -> AwsEcsServiceDetails)
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
"ServiceArn")
            Parser
  (Maybe Text
   -> Maybe [AwsEcsServiceCapacityProviderStrategyDetails]
   -> Maybe [AwsEcsServiceServiceRegistriesDetails]
   -> Maybe Int
   -> Maybe AwsEcsServiceNetworkConfigurationDetails
   -> Maybe AwsEcsServiceDeploymentConfigurationDetails
   -> Maybe Bool
   -> AwsEcsServiceDetails)
-> Parser (Maybe Text)
-> Parser
     (Maybe [AwsEcsServiceCapacityProviderStrategyDetails]
      -> Maybe [AwsEcsServiceServiceRegistriesDetails]
      -> Maybe Int
      -> Maybe AwsEcsServiceNetworkConfigurationDetails
      -> Maybe AwsEcsServiceDeploymentConfigurationDetails
      -> Maybe Bool
      -> AwsEcsServiceDetails)
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
"SchedulingStrategy")
            Parser
  (Maybe [AwsEcsServiceCapacityProviderStrategyDetails]
   -> Maybe [AwsEcsServiceServiceRegistriesDetails]
   -> Maybe Int
   -> Maybe AwsEcsServiceNetworkConfigurationDetails
   -> Maybe AwsEcsServiceDeploymentConfigurationDetails
   -> Maybe Bool
   -> AwsEcsServiceDetails)
-> Parser (Maybe [AwsEcsServiceCapacityProviderStrategyDetails])
-> Parser
     (Maybe [AwsEcsServiceServiceRegistriesDetails]
      -> Maybe Int
      -> Maybe AwsEcsServiceNetworkConfigurationDetails
      -> Maybe AwsEcsServiceDeploymentConfigurationDetails
      -> Maybe Bool
      -> AwsEcsServiceDetails)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ( Object
x Object
-> Text
-> Parser
     (Maybe (Maybe [AwsEcsServiceCapacityProviderStrategyDetails]))
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"CapacityProviderStrategy"
                            Parser
  (Maybe (Maybe [AwsEcsServiceCapacityProviderStrategyDetails]))
-> Maybe [AwsEcsServiceCapacityProviderStrategyDetails]
-> Parser (Maybe [AwsEcsServiceCapacityProviderStrategyDetails])
forall a. Parser (Maybe a) -> a -> Parser a
Core..!= Maybe [AwsEcsServiceCapacityProviderStrategyDetails]
forall a. Monoid a => a
Prelude.mempty
                        )
            Parser
  (Maybe [AwsEcsServiceServiceRegistriesDetails]
   -> Maybe Int
   -> Maybe AwsEcsServiceNetworkConfigurationDetails
   -> Maybe AwsEcsServiceDeploymentConfigurationDetails
   -> Maybe Bool
   -> AwsEcsServiceDetails)
-> Parser (Maybe [AwsEcsServiceServiceRegistriesDetails])
-> Parser
     (Maybe Int
      -> Maybe AwsEcsServiceNetworkConfigurationDetails
      -> Maybe AwsEcsServiceDeploymentConfigurationDetails
      -> Maybe Bool
      -> AwsEcsServiceDetails)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ( Object
x Object
-> Text
-> Parser (Maybe (Maybe [AwsEcsServiceServiceRegistriesDetails]))
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"ServiceRegistries"
                            Parser (Maybe (Maybe [AwsEcsServiceServiceRegistriesDetails]))
-> Maybe [AwsEcsServiceServiceRegistriesDetails]
-> Parser (Maybe [AwsEcsServiceServiceRegistriesDetails])
forall a. Parser (Maybe a) -> a -> Parser a
Core..!= Maybe [AwsEcsServiceServiceRegistriesDetails]
forall a. Monoid a => a
Prelude.mempty
                        )
            Parser
  (Maybe Int
   -> Maybe AwsEcsServiceNetworkConfigurationDetails
   -> Maybe AwsEcsServiceDeploymentConfigurationDetails
   -> Maybe Bool
   -> AwsEcsServiceDetails)
-> Parser (Maybe Int)
-> Parser
     (Maybe AwsEcsServiceNetworkConfigurationDetails
      -> Maybe AwsEcsServiceDeploymentConfigurationDetails
      -> Maybe Bool
      -> AwsEcsServiceDetails)
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
"HealthCheckGracePeriodSeconds")
            Parser
  (Maybe AwsEcsServiceNetworkConfigurationDetails
   -> Maybe AwsEcsServiceDeploymentConfigurationDetails
   -> Maybe Bool
   -> AwsEcsServiceDetails)
-> Parser (Maybe AwsEcsServiceNetworkConfigurationDetails)
-> Parser
     (Maybe AwsEcsServiceDeploymentConfigurationDetails
      -> Maybe Bool -> AwsEcsServiceDetails)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object
-> Text -> Parser (Maybe AwsEcsServiceNetworkConfigurationDetails)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"NetworkConfiguration")
            Parser
  (Maybe AwsEcsServiceDeploymentConfigurationDetails
   -> Maybe Bool -> AwsEcsServiceDetails)
-> Parser (Maybe AwsEcsServiceDeploymentConfigurationDetails)
-> Parser (Maybe Bool -> AwsEcsServiceDetails)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object
-> Text
-> Parser (Maybe AwsEcsServiceDeploymentConfigurationDetails)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"DeploymentConfiguration")
            Parser (Maybe Bool -> AwsEcsServiceDetails)
-> Parser (Maybe Bool) -> Parser AwsEcsServiceDetails
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x Object -> Text -> Parser (Maybe Bool)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Core..:? Text
"EnableExecuteCommand")
      )

instance Prelude.Hashable AwsEcsServiceDetails

instance Prelude.NFData AwsEcsServiceDetails

instance Core.ToJSON AwsEcsServiceDetails where
  toJSON :: AwsEcsServiceDetails -> Value
toJSON AwsEcsServiceDetails' {Maybe Bool
Maybe Int
Maybe [AwsEcsServiceCapacityProviderStrategyDetails]
Maybe [AwsEcsServiceLoadBalancersDetails]
Maybe [AwsEcsServicePlacementConstraintsDetails]
Maybe [AwsEcsServicePlacementStrategiesDetails]
Maybe [AwsEcsServiceServiceRegistriesDetails]
Maybe Text
Maybe AwsEcsServiceDeploymentConfigurationDetails
Maybe AwsEcsServiceDeploymentControllerDetails
Maybe AwsEcsServiceNetworkConfigurationDetails
enableExecuteCommand :: Maybe Bool
deploymentConfiguration :: Maybe AwsEcsServiceDeploymentConfigurationDetails
networkConfiguration :: Maybe AwsEcsServiceNetworkConfigurationDetails
healthCheckGracePeriodSeconds :: Maybe Int
serviceRegistries :: Maybe [AwsEcsServiceServiceRegistriesDetails]
capacityProviderStrategy :: Maybe [AwsEcsServiceCapacityProviderStrategyDetails]
schedulingStrategy :: Maybe Text
serviceArn :: Maybe Text
taskDefinition :: Maybe Text
launchType :: Maybe Text
deploymentController :: Maybe AwsEcsServiceDeploymentControllerDetails
serviceName :: Maybe Text
placementConstraints :: Maybe [AwsEcsServicePlacementConstraintsDetails]
name :: Maybe Text
role' :: Maybe Text
loadBalancers :: Maybe [AwsEcsServiceLoadBalancersDetails]
desiredCount :: Maybe Int
enableEcsManagedTags :: Maybe Bool
platformVersion :: Maybe Text
propagateTags :: Maybe Text
cluster :: Maybe Text
placementStrategies :: Maybe [AwsEcsServicePlacementStrategiesDetails]
$sel:enableExecuteCommand:AwsEcsServiceDetails' :: AwsEcsServiceDetails -> Maybe Bool
$sel:deploymentConfiguration:AwsEcsServiceDetails' :: AwsEcsServiceDetails
-> Maybe AwsEcsServiceDeploymentConfigurationDetails
$sel:networkConfiguration:AwsEcsServiceDetails' :: AwsEcsServiceDetails
-> Maybe AwsEcsServiceNetworkConfigurationDetails
$sel:healthCheckGracePeriodSeconds:AwsEcsServiceDetails' :: AwsEcsServiceDetails -> Maybe Int
$sel:serviceRegistries:AwsEcsServiceDetails' :: AwsEcsServiceDetails
-> Maybe [AwsEcsServiceServiceRegistriesDetails]
$sel:capacityProviderStrategy:AwsEcsServiceDetails' :: AwsEcsServiceDetails
-> Maybe [AwsEcsServiceCapacityProviderStrategyDetails]
$sel:schedulingStrategy:AwsEcsServiceDetails' :: AwsEcsServiceDetails -> Maybe Text
$sel:serviceArn:AwsEcsServiceDetails' :: AwsEcsServiceDetails -> Maybe Text
$sel:taskDefinition:AwsEcsServiceDetails' :: AwsEcsServiceDetails -> Maybe Text
$sel:launchType:AwsEcsServiceDetails' :: AwsEcsServiceDetails -> Maybe Text
$sel:deploymentController:AwsEcsServiceDetails' :: AwsEcsServiceDetails
-> Maybe AwsEcsServiceDeploymentControllerDetails
$sel:serviceName:AwsEcsServiceDetails' :: AwsEcsServiceDetails -> Maybe Text
$sel:placementConstraints:AwsEcsServiceDetails' :: AwsEcsServiceDetails
-> Maybe [AwsEcsServicePlacementConstraintsDetails]
$sel:name:AwsEcsServiceDetails' :: AwsEcsServiceDetails -> Maybe Text
$sel:role':AwsEcsServiceDetails' :: AwsEcsServiceDetails -> Maybe Text
$sel:loadBalancers:AwsEcsServiceDetails' :: AwsEcsServiceDetails -> Maybe [AwsEcsServiceLoadBalancersDetails]
$sel:desiredCount:AwsEcsServiceDetails' :: AwsEcsServiceDetails -> Maybe Int
$sel:enableEcsManagedTags:AwsEcsServiceDetails' :: AwsEcsServiceDetails -> Maybe Bool
$sel:platformVersion:AwsEcsServiceDetails' :: AwsEcsServiceDetails -> Maybe Text
$sel:propagateTags:AwsEcsServiceDetails' :: AwsEcsServiceDetails -> Maybe Text
$sel:cluster:AwsEcsServiceDetails' :: AwsEcsServiceDetails -> Maybe Text
$sel:placementStrategies:AwsEcsServiceDetails' :: AwsEcsServiceDetails
-> Maybe [AwsEcsServicePlacementStrategiesDetails]
..} =
    [Pair] -> Value
Core.object
      ( [Maybe Pair] -> [Pair]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
          [ (Text
"PlacementStrategies" Text -> [AwsEcsServicePlacementStrategiesDetails] -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
              ([AwsEcsServicePlacementStrategiesDetails] -> Pair)
-> Maybe [AwsEcsServicePlacementStrategiesDetails] -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [AwsEcsServicePlacementStrategiesDetails]
placementStrategies,
            (Text
"Cluster" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (Text -> Pair) -> Maybe Text -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
cluster,
            (Text
"PropagateTags" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (Text -> Pair) -> Maybe Text -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
propagateTags,
            (Text
"PlatformVersion" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
              (Text -> Pair) -> Maybe Text -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
platformVersion,
            (Text
"EnableEcsManagedTags" Text -> Bool -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
              (Bool -> Pair) -> Maybe Bool -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Bool
enableEcsManagedTags,
            (Text
"DesiredCount" Text -> Int -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (Int -> Pair) -> Maybe Int -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Int
desiredCount,
            (Text
"LoadBalancers" Text -> [AwsEcsServiceLoadBalancersDetails] -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) ([AwsEcsServiceLoadBalancersDetails] -> Pair)
-> Maybe [AwsEcsServiceLoadBalancersDetails] -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [AwsEcsServiceLoadBalancersDetails]
loadBalancers,
            (Text
"Role" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (Text -> Pair) -> Maybe Text -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
role',
            (Text
"Name" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (Text -> Pair) -> Maybe Text -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
name,
            (Text
"PlacementConstraints" Text -> [AwsEcsServicePlacementConstraintsDetails] -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
              ([AwsEcsServicePlacementConstraintsDetails] -> Pair)
-> Maybe [AwsEcsServicePlacementConstraintsDetails] -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [AwsEcsServicePlacementConstraintsDetails]
placementConstraints,
            (Text
"ServiceName" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (Text -> Pair) -> Maybe Text -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
serviceName,
            (Text
"DeploymentController" Text -> AwsEcsServiceDeploymentControllerDetails -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
              (AwsEcsServiceDeploymentControllerDetails -> Pair)
-> Maybe AwsEcsServiceDeploymentControllerDetails -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe AwsEcsServiceDeploymentControllerDetails
deploymentController,
            (Text
"LaunchType" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (Text -> Pair) -> Maybe Text -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
launchType,
            (Text
"TaskDefinition" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
              (Text -> Pair) -> Maybe Text -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
taskDefinition,
            (Text
"ServiceArn" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=) (Text -> Pair) -> Maybe Text -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
serviceArn,
            (Text
"SchedulingStrategy" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
              (Text -> Pair) -> Maybe Text -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Text
schedulingStrategy,
            (Text
"CapacityProviderStrategy" Text -> [AwsEcsServiceCapacityProviderStrategyDetails] -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
              ([AwsEcsServiceCapacityProviderStrategyDetails] -> Pair)
-> Maybe [AwsEcsServiceCapacityProviderStrategyDetails]
-> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [AwsEcsServiceCapacityProviderStrategyDetails]
capacityProviderStrategy,
            (Text
"ServiceRegistries" Text -> [AwsEcsServiceServiceRegistriesDetails] -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
              ([AwsEcsServiceServiceRegistriesDetails] -> Pair)
-> Maybe [AwsEcsServiceServiceRegistriesDetails] -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe [AwsEcsServiceServiceRegistriesDetails]
serviceRegistries,
            (Text
"HealthCheckGracePeriodSeconds" Text -> Int -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
              (Int -> Pair) -> Maybe Int -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Int
healthCheckGracePeriodSeconds,
            (Text
"NetworkConfiguration" Text -> AwsEcsServiceNetworkConfigurationDetails -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
              (AwsEcsServiceNetworkConfigurationDetails -> Pair)
-> Maybe AwsEcsServiceNetworkConfigurationDetails -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe AwsEcsServiceNetworkConfigurationDetails
networkConfiguration,
            (Text
"DeploymentConfiguration" Text -> AwsEcsServiceDeploymentConfigurationDetails -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
              (AwsEcsServiceDeploymentConfigurationDetails -> Pair)
-> Maybe AwsEcsServiceDeploymentConfigurationDetails -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe AwsEcsServiceDeploymentConfigurationDetails
deploymentConfiguration,
            (Text
"EnableExecuteCommand" Text -> Bool -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Core..=)
              (Bool -> Pair) -> Maybe Bool -> Maybe Pair
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe Bool
enableExecuteCommand
          ]
      )