module Stratosphere.ECS.Service.DeploymentCircuitBreakerProperty (
        DeploymentCircuitBreakerProperty(..),
        mkDeploymentCircuitBreakerProperty
    ) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import Stratosphere.ResourceProperties
import Stratosphere.Value
data DeploymentCircuitBreakerProperty
  = -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ecs-service-deploymentcircuitbreaker.html>
    DeploymentCircuitBreakerProperty {DeploymentCircuitBreakerProperty -> ()
haddock_workaround_ :: (),
                                      -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ecs-service-deploymentcircuitbreaker.html#cfn-ecs-service-deploymentcircuitbreaker-enable>
                                      DeploymentCircuitBreakerProperty -> Value Bool
enable :: (Value Prelude.Bool),
                                      -- | See: <http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-ecs-service-deploymentcircuitbreaker.html#cfn-ecs-service-deploymentcircuitbreaker-rollback>
                                      DeploymentCircuitBreakerProperty -> Value Bool
rollback :: (Value Prelude.Bool)}
  deriving stock (DeploymentCircuitBreakerProperty
-> DeploymentCircuitBreakerProperty -> Bool
(DeploymentCircuitBreakerProperty
 -> DeploymentCircuitBreakerProperty -> Bool)
-> (DeploymentCircuitBreakerProperty
    -> DeploymentCircuitBreakerProperty -> Bool)
-> Eq DeploymentCircuitBreakerProperty
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: DeploymentCircuitBreakerProperty
-> DeploymentCircuitBreakerProperty -> Bool
== :: DeploymentCircuitBreakerProperty
-> DeploymentCircuitBreakerProperty -> Bool
$c/= :: DeploymentCircuitBreakerProperty
-> DeploymentCircuitBreakerProperty -> Bool
/= :: DeploymentCircuitBreakerProperty
-> DeploymentCircuitBreakerProperty -> Bool
Prelude.Eq, Int -> DeploymentCircuitBreakerProperty -> ShowS
[DeploymentCircuitBreakerProperty] -> ShowS
DeploymentCircuitBreakerProperty -> String
(Int -> DeploymentCircuitBreakerProperty -> ShowS)
-> (DeploymentCircuitBreakerProperty -> String)
-> ([DeploymentCircuitBreakerProperty] -> ShowS)
-> Show DeploymentCircuitBreakerProperty
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> DeploymentCircuitBreakerProperty -> ShowS
showsPrec :: Int -> DeploymentCircuitBreakerProperty -> ShowS
$cshow :: DeploymentCircuitBreakerProperty -> String
show :: DeploymentCircuitBreakerProperty -> String
$cshowList :: [DeploymentCircuitBreakerProperty] -> ShowS
showList :: [DeploymentCircuitBreakerProperty] -> ShowS
Prelude.Show)
mkDeploymentCircuitBreakerProperty ::
  Value Prelude.Bool
  -> Value Prelude.Bool -> DeploymentCircuitBreakerProperty
mkDeploymentCircuitBreakerProperty :: Value Bool -> Value Bool -> DeploymentCircuitBreakerProperty
mkDeploymentCircuitBreakerProperty Value Bool
enable Value Bool
rollback
  = DeploymentCircuitBreakerProperty
      {haddock_workaround_ :: ()
haddock_workaround_ = (), enable :: Value Bool
enable = Value Bool
enable, rollback :: Value Bool
rollback = Value Bool
rollback}
instance ToResourceProperties DeploymentCircuitBreakerProperty where
  toResourceProperties :: DeploymentCircuitBreakerProperty -> ResourceProperties
toResourceProperties DeploymentCircuitBreakerProperty {()
Value Bool
haddock_workaround_ :: DeploymentCircuitBreakerProperty -> ()
enable :: DeploymentCircuitBreakerProperty -> Value Bool
rollback :: DeploymentCircuitBreakerProperty -> Value Bool
haddock_workaround_ :: ()
enable :: Value Bool
rollback :: Value Bool
..}
    = ResourceProperties
        {awsType :: Text
awsType = Text
"AWS::ECS::Service.DeploymentCircuitBreaker",
         supportsTags :: Bool
supportsTags = Bool
Prelude.False,
         properties :: Object
properties = [Key
"Enable" Key -> Value Bool -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
JSON..= Value Bool
enable,
                       Key
"Rollback" Key -> Value Bool -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
JSON..= Value Bool
rollback]}
instance JSON.ToJSON DeploymentCircuitBreakerProperty where
  toJSON :: DeploymentCircuitBreakerProperty -> Value
toJSON DeploymentCircuitBreakerProperty {()
Value Bool
haddock_workaround_ :: DeploymentCircuitBreakerProperty -> ()
enable :: DeploymentCircuitBreakerProperty -> Value Bool
rollback :: DeploymentCircuitBreakerProperty -> Value Bool
haddock_workaround_ :: ()
enable :: Value Bool
rollback :: Value Bool
..}
    = [(Key, Value)] -> Value
JSON.object
        [Key
"Enable" Key -> Value Bool -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
JSON..= Value Bool
enable, Key
"Rollback" Key -> Value Bool -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
JSON..= Value Bool
rollback]
instance Property "Enable" DeploymentCircuitBreakerProperty where
  type PropertyType "Enable" DeploymentCircuitBreakerProperty = Value Prelude.Bool
  set :: PropertyType "Enable" DeploymentCircuitBreakerProperty
-> DeploymentCircuitBreakerProperty
-> DeploymentCircuitBreakerProperty
set PropertyType "Enable" DeploymentCircuitBreakerProperty
newValue DeploymentCircuitBreakerProperty {()
Value Bool
haddock_workaround_ :: DeploymentCircuitBreakerProperty -> ()
enable :: DeploymentCircuitBreakerProperty -> Value Bool
rollback :: DeploymentCircuitBreakerProperty -> Value Bool
haddock_workaround_ :: ()
enable :: Value Bool
rollback :: Value Bool
..}
    = DeploymentCircuitBreakerProperty {enable :: Value Bool
enable = PropertyType "Enable" DeploymentCircuitBreakerProperty
Value Bool
newValue, ()
Value Bool
haddock_workaround_ :: ()
rollback :: Value Bool
haddock_workaround_ :: ()
rollback :: Value Bool
..}
instance Property "Rollback" DeploymentCircuitBreakerProperty where
  type PropertyType "Rollback" DeploymentCircuitBreakerProperty = Value Prelude.Bool
  set :: PropertyType "Rollback" DeploymentCircuitBreakerProperty
-> DeploymentCircuitBreakerProperty
-> DeploymentCircuitBreakerProperty
set PropertyType "Rollback" DeploymentCircuitBreakerProperty
newValue DeploymentCircuitBreakerProperty {()
Value Bool
haddock_workaround_ :: DeploymentCircuitBreakerProperty -> ()
enable :: DeploymentCircuitBreakerProperty -> Value Bool
rollback :: DeploymentCircuitBreakerProperty -> Value Bool
haddock_workaround_ :: ()
enable :: Value Bool
rollback :: Value Bool
..}
    = DeploymentCircuitBreakerProperty {rollback :: Value Bool
rollback = PropertyType "Rollback" DeploymentCircuitBreakerProperty
Value Bool
newValue, ()
Value Bool
haddock_workaround_ :: ()
enable :: Value Bool
haddock_workaround_ :: ()
enable :: Value Bool
..}