module Stratosphere.ApplicationInsights.Application.JMXPrometheusExporterProperty (
JMXPrometheusExporterProperty(..), mkJMXPrometheusExporterProperty
) where
import qualified Data.Aeson as JSON
import qualified Stratosphere.Prelude as Prelude
import Stratosphere.Property
import Stratosphere.ResourceProperties
import Stratosphere.Value
data JMXPrometheusExporterProperty
=
JMXPrometheusExporterProperty {JMXPrometheusExporterProperty -> ()
haddock_workaround_ :: (),
JMXPrometheusExporterProperty -> Maybe (Value Text)
hostPort :: (Prelude.Maybe (Value Prelude.Text)),
JMXPrometheusExporterProperty -> Maybe (Value Text)
jMXURL :: (Prelude.Maybe (Value Prelude.Text)),
JMXPrometheusExporterProperty -> Maybe (Value Text)
prometheusPort :: (Prelude.Maybe (Value Prelude.Text))}
deriving stock (JMXPrometheusExporterProperty
-> JMXPrometheusExporterProperty -> Bool
(JMXPrometheusExporterProperty
-> JMXPrometheusExporterProperty -> Bool)
-> (JMXPrometheusExporterProperty
-> JMXPrometheusExporterProperty -> Bool)
-> Eq JMXPrometheusExporterProperty
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
$c== :: JMXPrometheusExporterProperty
-> JMXPrometheusExporterProperty -> Bool
== :: JMXPrometheusExporterProperty
-> JMXPrometheusExporterProperty -> Bool
$c/= :: JMXPrometheusExporterProperty
-> JMXPrometheusExporterProperty -> Bool
/= :: JMXPrometheusExporterProperty
-> JMXPrometheusExporterProperty -> Bool
Prelude.Eq, Int -> JMXPrometheusExporterProperty -> ShowS
[JMXPrometheusExporterProperty] -> ShowS
JMXPrometheusExporterProperty -> String
(Int -> JMXPrometheusExporterProperty -> ShowS)
-> (JMXPrometheusExporterProperty -> String)
-> ([JMXPrometheusExporterProperty] -> ShowS)
-> Show JMXPrometheusExporterProperty
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
$cshowsPrec :: Int -> JMXPrometheusExporterProperty -> ShowS
showsPrec :: Int -> JMXPrometheusExporterProperty -> ShowS
$cshow :: JMXPrometheusExporterProperty -> String
show :: JMXPrometheusExporterProperty -> String
$cshowList :: [JMXPrometheusExporterProperty] -> ShowS
showList :: [JMXPrometheusExporterProperty] -> ShowS
Prelude.Show)
mkJMXPrometheusExporterProperty :: JMXPrometheusExporterProperty
mkJMXPrometheusExporterProperty :: JMXPrometheusExporterProperty
mkJMXPrometheusExporterProperty
= JMXPrometheusExporterProperty
{haddock_workaround_ :: ()
haddock_workaround_ = (), hostPort :: Maybe (Value Text)
hostPort = Maybe (Value Text)
forall a. Maybe a
Prelude.Nothing,
jMXURL :: Maybe (Value Text)
jMXURL = Maybe (Value Text)
forall a. Maybe a
Prelude.Nothing, prometheusPort :: Maybe (Value Text)
prometheusPort = Maybe (Value Text)
forall a. Maybe a
Prelude.Nothing}
instance ToResourceProperties JMXPrometheusExporterProperty where
toResourceProperties :: JMXPrometheusExporterProperty -> ResourceProperties
toResourceProperties JMXPrometheusExporterProperty {Maybe (Value Text)
()
haddock_workaround_ :: JMXPrometheusExporterProperty -> ()
hostPort :: JMXPrometheusExporterProperty -> Maybe (Value Text)
jMXURL :: JMXPrometheusExporterProperty -> Maybe (Value Text)
prometheusPort :: JMXPrometheusExporterProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
hostPort :: Maybe (Value Text)
jMXURL :: Maybe (Value Text)
prometheusPort :: Maybe (Value Text)
..}
= ResourceProperties
{awsType :: Text
awsType = Text
"AWS::ApplicationInsights::Application.JMXPrometheusExporter",
supportsTags :: Bool
supportsTags = Bool
Prelude.False,
properties :: Object
properties = [Item Object] -> Object
forall l. IsList l => [Item l] -> l
Prelude.fromList
([Maybe (Key, Value)] -> [(Key, Value)]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
[Key -> Value Text -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"HostPort" (Value Text -> (Key, Value))
-> Maybe (Value Text) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (Value Text)
hostPort,
Key -> Value Text -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"JMXURL" (Value Text -> (Key, Value))
-> Maybe (Value Text) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (Value Text)
jMXURL,
Key -> Value Text -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"PrometheusPort" (Value Text -> (Key, Value))
-> Maybe (Value Text) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (Value Text)
prometheusPort])}
instance JSON.ToJSON JMXPrometheusExporterProperty where
toJSON :: JMXPrometheusExporterProperty -> Value
toJSON JMXPrometheusExporterProperty {Maybe (Value Text)
()
haddock_workaround_ :: JMXPrometheusExporterProperty -> ()
hostPort :: JMXPrometheusExporterProperty -> Maybe (Value Text)
jMXURL :: JMXPrometheusExporterProperty -> Maybe (Value Text)
prometheusPort :: JMXPrometheusExporterProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
hostPort :: Maybe (Value Text)
jMXURL :: Maybe (Value Text)
prometheusPort :: Maybe (Value Text)
..}
= [(Key, Value)] -> Value
JSON.object
([Item [(Key, Value)]] -> [(Key, Value)]
forall l. IsList l => [Item l] -> l
Prelude.fromList
([Maybe (Key, Value)] -> [(Key, Value)]
forall a. [Maybe a] -> [a]
Prelude.catMaybes
[Key -> Value Text -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"HostPort" (Value Text -> (Key, Value))
-> Maybe (Value Text) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (Value Text)
hostPort,
Key -> Value Text -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"JMXURL" (Value Text -> (Key, Value))
-> Maybe (Value Text) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (Value Text)
jMXURL,
Key -> Value Text -> (Key, Value)
forall v. ToJSON v => Key -> v -> (Key, Value)
forall e kv v. (KeyValue e kv, ToJSON v) => Key -> v -> kv
(JSON..=) Key
"PrometheusPort" (Value Text -> (Key, Value))
-> Maybe (Value Text) -> Maybe (Key, Value)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> Maybe (Value Text)
prometheusPort]))
instance Property "HostPort" JMXPrometheusExporterProperty where
type PropertyType "HostPort" JMXPrometheusExporterProperty = Value Prelude.Text
set :: PropertyType "HostPort" JMXPrometheusExporterProperty
-> JMXPrometheusExporterProperty -> JMXPrometheusExporterProperty
set PropertyType "HostPort" JMXPrometheusExporterProperty
newValue JMXPrometheusExporterProperty {Maybe (Value Text)
()
haddock_workaround_ :: JMXPrometheusExporterProperty -> ()
hostPort :: JMXPrometheusExporterProperty -> Maybe (Value Text)
jMXURL :: JMXPrometheusExporterProperty -> Maybe (Value Text)
prometheusPort :: JMXPrometheusExporterProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
hostPort :: Maybe (Value Text)
jMXURL :: Maybe (Value Text)
prometheusPort :: Maybe (Value Text)
..}
= JMXPrometheusExporterProperty
{hostPort :: Maybe (Value Text)
hostPort = Value Text -> Maybe (Value Text)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "HostPort" JMXPrometheusExporterProperty
Value Text
newValue, Maybe (Value Text)
()
haddock_workaround_ :: ()
jMXURL :: Maybe (Value Text)
prometheusPort :: Maybe (Value Text)
haddock_workaround_ :: ()
jMXURL :: Maybe (Value Text)
prometheusPort :: Maybe (Value Text)
..}
instance Property "JMXURL" JMXPrometheusExporterProperty where
type PropertyType "JMXURL" JMXPrometheusExporterProperty = Value Prelude.Text
set :: PropertyType "JMXURL" JMXPrometheusExporterProperty
-> JMXPrometheusExporterProperty -> JMXPrometheusExporterProperty
set PropertyType "JMXURL" JMXPrometheusExporterProperty
newValue JMXPrometheusExporterProperty {Maybe (Value Text)
()
haddock_workaround_ :: JMXPrometheusExporterProperty -> ()
hostPort :: JMXPrometheusExporterProperty -> Maybe (Value Text)
jMXURL :: JMXPrometheusExporterProperty -> Maybe (Value Text)
prometheusPort :: JMXPrometheusExporterProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
hostPort :: Maybe (Value Text)
jMXURL :: Maybe (Value Text)
prometheusPort :: Maybe (Value Text)
..}
= JMXPrometheusExporterProperty
{jMXURL :: Maybe (Value Text)
jMXURL = Value Text -> Maybe (Value Text)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "JMXURL" JMXPrometheusExporterProperty
Value Text
newValue, Maybe (Value Text)
()
haddock_workaround_ :: ()
hostPort :: Maybe (Value Text)
prometheusPort :: Maybe (Value Text)
haddock_workaround_ :: ()
hostPort :: Maybe (Value Text)
prometheusPort :: Maybe (Value Text)
..}
instance Property "PrometheusPort" JMXPrometheusExporterProperty where
type PropertyType "PrometheusPort" JMXPrometheusExporterProperty = Value Prelude.Text
set :: PropertyType "PrometheusPort" JMXPrometheusExporterProperty
-> JMXPrometheusExporterProperty -> JMXPrometheusExporterProperty
set PropertyType "PrometheusPort" JMXPrometheusExporterProperty
newValue JMXPrometheusExporterProperty {Maybe (Value Text)
()
haddock_workaround_ :: JMXPrometheusExporterProperty -> ()
hostPort :: JMXPrometheusExporterProperty -> Maybe (Value Text)
jMXURL :: JMXPrometheusExporterProperty -> Maybe (Value Text)
prometheusPort :: JMXPrometheusExporterProperty -> Maybe (Value Text)
haddock_workaround_ :: ()
hostPort :: Maybe (Value Text)
jMXURL :: Maybe (Value Text)
prometheusPort :: Maybe (Value Text)
..}
= JMXPrometheusExporterProperty
{prometheusPort :: Maybe (Value Text)
prometheusPort = Value Text -> Maybe (Value Text)
forall a. a -> Maybe a
forall (f :: * -> *) a. Applicative f => a -> f a
Prelude.pure PropertyType "PrometheusPort" JMXPrometheusExporterProperty
Value Text
newValue, Maybe (Value Text)
()
haddock_workaround_ :: ()
hostPort :: Maybe (Value Text)
jMXURL :: Maybe (Value Text)
haddock_workaround_ :: ()
hostPort :: Maybe (Value Text)
jMXURL :: Maybe (Value Text)
..}