{-# 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.GameLift.Types.GameSessionQueue
-- Copyright   : (c) 2013-2023 Brendan Hay
-- License     : Mozilla Public License, v. 2.0.
-- Maintainer  : Brendan Hay
-- Stability   : auto-generated
-- Portability : non-portable (GHC extensions)
module Amazonka.GameLift.Types.GameSessionQueue where

import qualified Amazonka.Core as Core
import qualified Amazonka.Core.Lens.Internal as Lens
import qualified Amazonka.Data as Data
import Amazonka.GameLift.Types.FilterConfiguration
import Amazonka.GameLift.Types.GameSessionQueueDestination
import Amazonka.GameLift.Types.PlayerLatencyPolicy
import Amazonka.GameLift.Types.PriorityConfiguration
import qualified Amazonka.Prelude as Prelude

-- | Configuration for a game session placement mechanism that processes
-- requests for new game sessions. A queue can be used on its own or as
-- part of a matchmaking solution.
--
-- /See:/ 'newGameSessionQueue' smart constructor.
data GameSessionQueue = GameSessionQueue'
  { -- | Information that is added to all events that are related to this game
    -- session queue.
    GameSessionQueue -> Maybe Text
customEventData :: Prelude.Maybe Prelude.Text,
    -- | A list of fleets and\/or fleet aliases that can be used to fulfill game
    -- session placement requests in the queue. Destinations are identified by
    -- either a fleet ARN or a fleet alias ARN, and are listed in order of
    -- placement preference.
    GameSessionQueue -> Maybe [GameSessionQueueDestination]
destinations :: Prelude.Maybe [GameSessionQueueDestination],
    -- | A list of locations where a queue is allowed to place new game sessions.
    -- Locations are specified in the form of Amazon Web Services Region codes,
    -- such as @us-west-2@. If this parameter is not set, game sessions can be
    -- placed in any queue location.
    GameSessionQueue -> Maybe FilterConfiguration
filterConfiguration :: Prelude.Maybe FilterConfiguration,
    -- | The Amazon Resource Name
    -- (<https://docs.aws.amazon.com/AmazonS3/latest/dev/s3-arn-format.html ARN>)
    -- that is assigned to a GameLift game session queue resource and uniquely
    -- identifies it. ARNs are unique across all Regions. Format is
    -- @arn:aws:gamelift:\<region>::gamesessionqueue\/\<queue name>@. In a
    -- GameLift game session queue ARN, the resource ID matches the /Name/
    -- value.
    GameSessionQueue -> Maybe Text
gameSessionQueueArn :: Prelude.Maybe Prelude.Text,
    -- | A descriptive label that is associated with game session queue. Queue
    -- names must be unique within each Region.
    GameSessionQueue -> Maybe Text
name :: Prelude.Maybe Prelude.Text,
    -- | An SNS topic ARN that is set up to receive game session placement
    -- notifications. See
    -- <https://docs.aws.amazon.com/gamelift/latest/developerguide/queue-notification.html Setting up notifications for game session placement>.
    GameSessionQueue -> Maybe Text
notificationTarget :: Prelude.Maybe Prelude.Text,
    -- | A set of policies that act as a sliding cap on player latency. FleetIQ
    -- works to deliver low latency for most players in a game session. These
    -- policies ensure that no individual player can be placed into a game with
    -- unreasonably high latency. Use multiple policies to gradually relax
    -- latency requirements a step at a time. Multiple policies are applied
    -- based on their maximum allowed latency, starting with the lowest value.
    GameSessionQueue -> Maybe [PlayerLatencyPolicy]
playerLatencyPolicies :: Prelude.Maybe [PlayerLatencyPolicy],
    -- | Custom settings to use when prioritizing destinations and locations for
    -- game session placements. This configuration replaces the FleetIQ default
    -- prioritization process. Priority types that are not explicitly named
    -- will be automatically applied at the end of the prioritization process.
    GameSessionQueue -> Maybe PriorityConfiguration
priorityConfiguration :: Prelude.Maybe PriorityConfiguration,
    -- | The maximum time, in seconds, that a new game session placement request
    -- remains in the queue. When a request exceeds this time, the game session
    -- placement changes to a @TIMED_OUT@ status.
    GameSessionQueue -> Maybe Natural
timeoutInSeconds :: Prelude.Maybe Prelude.Natural
  }
  deriving (GameSessionQueue -> GameSessionQueue -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: GameSessionQueue -> GameSessionQueue -> Bool
$c/= :: GameSessionQueue -> GameSessionQueue -> Bool
== :: GameSessionQueue -> GameSessionQueue -> Bool
$c== :: GameSessionQueue -> GameSessionQueue -> Bool
Prelude.Eq, ReadPrec [GameSessionQueue]
ReadPrec GameSessionQueue
Int -> ReadS GameSessionQueue
ReadS [GameSessionQueue]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [GameSessionQueue]
$creadListPrec :: ReadPrec [GameSessionQueue]
readPrec :: ReadPrec GameSessionQueue
$creadPrec :: ReadPrec GameSessionQueue
readList :: ReadS [GameSessionQueue]
$creadList :: ReadS [GameSessionQueue]
readsPrec :: Int -> ReadS GameSessionQueue
$creadsPrec :: Int -> ReadS GameSessionQueue
Prelude.Read, Int -> GameSessionQueue -> ShowS
[GameSessionQueue] -> ShowS
GameSessionQueue -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [GameSessionQueue] -> ShowS
$cshowList :: [GameSessionQueue] -> ShowS
show :: GameSessionQueue -> String
$cshow :: GameSessionQueue -> String
showsPrec :: Int -> GameSessionQueue -> ShowS
$cshowsPrec :: Int -> GameSessionQueue -> ShowS
Prelude.Show, forall x. Rep GameSessionQueue x -> GameSessionQueue
forall x. GameSessionQueue -> Rep GameSessionQueue x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep GameSessionQueue x -> GameSessionQueue
$cfrom :: forall x. GameSessionQueue -> Rep GameSessionQueue x
Prelude.Generic)

-- |
-- Create a value of 'GameSessionQueue' 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:
--
-- 'customEventData', 'gameSessionQueue_customEventData' - Information that is added to all events that are related to this game
-- session queue.
--
-- 'destinations', 'gameSessionQueue_destinations' - A list of fleets and\/or fleet aliases that can be used to fulfill game
-- session placement requests in the queue. Destinations are identified by
-- either a fleet ARN or a fleet alias ARN, and are listed in order of
-- placement preference.
--
-- 'filterConfiguration', 'gameSessionQueue_filterConfiguration' - A list of locations where a queue is allowed to place new game sessions.
-- Locations are specified in the form of Amazon Web Services Region codes,
-- such as @us-west-2@. If this parameter is not set, game sessions can be
-- placed in any queue location.
--
-- 'gameSessionQueueArn', 'gameSessionQueue_gameSessionQueueArn' - The Amazon Resource Name
-- (<https://docs.aws.amazon.com/AmazonS3/latest/dev/s3-arn-format.html ARN>)
-- that is assigned to a GameLift game session queue resource and uniquely
-- identifies it. ARNs are unique across all Regions. Format is
-- @arn:aws:gamelift:\<region>::gamesessionqueue\/\<queue name>@. In a
-- GameLift game session queue ARN, the resource ID matches the /Name/
-- value.
--
-- 'name', 'gameSessionQueue_name' - A descriptive label that is associated with game session queue. Queue
-- names must be unique within each Region.
--
-- 'notificationTarget', 'gameSessionQueue_notificationTarget' - An SNS topic ARN that is set up to receive game session placement
-- notifications. See
-- <https://docs.aws.amazon.com/gamelift/latest/developerguide/queue-notification.html Setting up notifications for game session placement>.
--
-- 'playerLatencyPolicies', 'gameSessionQueue_playerLatencyPolicies' - A set of policies that act as a sliding cap on player latency. FleetIQ
-- works to deliver low latency for most players in a game session. These
-- policies ensure that no individual player can be placed into a game with
-- unreasonably high latency. Use multiple policies to gradually relax
-- latency requirements a step at a time. Multiple policies are applied
-- based on their maximum allowed latency, starting with the lowest value.
--
-- 'priorityConfiguration', 'gameSessionQueue_priorityConfiguration' - Custom settings to use when prioritizing destinations and locations for
-- game session placements. This configuration replaces the FleetIQ default
-- prioritization process. Priority types that are not explicitly named
-- will be automatically applied at the end of the prioritization process.
--
-- 'timeoutInSeconds', 'gameSessionQueue_timeoutInSeconds' - The maximum time, in seconds, that a new game session placement request
-- remains in the queue. When a request exceeds this time, the game session
-- placement changes to a @TIMED_OUT@ status.
newGameSessionQueue ::
  GameSessionQueue
newGameSessionQueue :: GameSessionQueue
newGameSessionQueue =
  GameSessionQueue'
    { $sel:customEventData:GameSessionQueue' :: Maybe Text
customEventData =
        forall a. Maybe a
Prelude.Nothing,
      $sel:destinations:GameSessionQueue' :: Maybe [GameSessionQueueDestination]
destinations = forall a. Maybe a
Prelude.Nothing,
      $sel:filterConfiguration:GameSessionQueue' :: Maybe FilterConfiguration
filterConfiguration = forall a. Maybe a
Prelude.Nothing,
      $sel:gameSessionQueueArn:GameSessionQueue' :: Maybe Text
gameSessionQueueArn = forall a. Maybe a
Prelude.Nothing,
      $sel:name:GameSessionQueue' :: Maybe Text
name = forall a. Maybe a
Prelude.Nothing,
      $sel:notificationTarget:GameSessionQueue' :: Maybe Text
notificationTarget = forall a. Maybe a
Prelude.Nothing,
      $sel:playerLatencyPolicies:GameSessionQueue' :: Maybe [PlayerLatencyPolicy]
playerLatencyPolicies = forall a. Maybe a
Prelude.Nothing,
      $sel:priorityConfiguration:GameSessionQueue' :: Maybe PriorityConfiguration
priorityConfiguration = forall a. Maybe a
Prelude.Nothing,
      $sel:timeoutInSeconds:GameSessionQueue' :: Maybe Natural
timeoutInSeconds = forall a. Maybe a
Prelude.Nothing
    }

-- | Information that is added to all events that are related to this game
-- session queue.
gameSessionQueue_customEventData :: Lens.Lens' GameSessionQueue (Prelude.Maybe Prelude.Text)
gameSessionQueue_customEventData :: Lens' GameSessionQueue (Maybe Text)
gameSessionQueue_customEventData = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\GameSessionQueue' {Maybe Text
customEventData :: Maybe Text
$sel:customEventData:GameSessionQueue' :: GameSessionQueue -> Maybe Text
customEventData} -> Maybe Text
customEventData) (\s :: GameSessionQueue
s@GameSessionQueue' {} Maybe Text
a -> GameSessionQueue
s {$sel:customEventData:GameSessionQueue' :: Maybe Text
customEventData = Maybe Text
a} :: GameSessionQueue)

-- | A list of fleets and\/or fleet aliases that can be used to fulfill game
-- session placement requests in the queue. Destinations are identified by
-- either a fleet ARN or a fleet alias ARN, and are listed in order of
-- placement preference.
gameSessionQueue_destinations :: Lens.Lens' GameSessionQueue (Prelude.Maybe [GameSessionQueueDestination])
gameSessionQueue_destinations :: Lens' GameSessionQueue (Maybe [GameSessionQueueDestination])
gameSessionQueue_destinations = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\GameSessionQueue' {Maybe [GameSessionQueueDestination]
destinations :: Maybe [GameSessionQueueDestination]
$sel:destinations:GameSessionQueue' :: GameSessionQueue -> Maybe [GameSessionQueueDestination]
destinations} -> Maybe [GameSessionQueueDestination]
destinations) (\s :: GameSessionQueue
s@GameSessionQueue' {} Maybe [GameSessionQueueDestination]
a -> GameSessionQueue
s {$sel:destinations:GameSessionQueue' :: Maybe [GameSessionQueueDestination]
destinations = Maybe [GameSessionQueueDestination]
a} :: GameSessionQueue) forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. 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 forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | A list of locations where a queue is allowed to place new game sessions.
-- Locations are specified in the form of Amazon Web Services Region codes,
-- such as @us-west-2@. If this parameter is not set, game sessions can be
-- placed in any queue location.
gameSessionQueue_filterConfiguration :: Lens.Lens' GameSessionQueue (Prelude.Maybe FilterConfiguration)
gameSessionQueue_filterConfiguration :: Lens' GameSessionQueue (Maybe FilterConfiguration)
gameSessionQueue_filterConfiguration = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\GameSessionQueue' {Maybe FilterConfiguration
filterConfiguration :: Maybe FilterConfiguration
$sel:filterConfiguration:GameSessionQueue' :: GameSessionQueue -> Maybe FilterConfiguration
filterConfiguration} -> Maybe FilterConfiguration
filterConfiguration) (\s :: GameSessionQueue
s@GameSessionQueue' {} Maybe FilterConfiguration
a -> GameSessionQueue
s {$sel:filterConfiguration:GameSessionQueue' :: Maybe FilterConfiguration
filterConfiguration = Maybe FilterConfiguration
a} :: GameSessionQueue)

-- | The Amazon Resource Name
-- (<https://docs.aws.amazon.com/AmazonS3/latest/dev/s3-arn-format.html ARN>)
-- that is assigned to a GameLift game session queue resource and uniquely
-- identifies it. ARNs are unique across all Regions. Format is
-- @arn:aws:gamelift:\<region>::gamesessionqueue\/\<queue name>@. In a
-- GameLift game session queue ARN, the resource ID matches the /Name/
-- value.
gameSessionQueue_gameSessionQueueArn :: Lens.Lens' GameSessionQueue (Prelude.Maybe Prelude.Text)
gameSessionQueue_gameSessionQueueArn :: Lens' GameSessionQueue (Maybe Text)
gameSessionQueue_gameSessionQueueArn = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\GameSessionQueue' {Maybe Text
gameSessionQueueArn :: Maybe Text
$sel:gameSessionQueueArn:GameSessionQueue' :: GameSessionQueue -> Maybe Text
gameSessionQueueArn} -> Maybe Text
gameSessionQueueArn) (\s :: GameSessionQueue
s@GameSessionQueue' {} Maybe Text
a -> GameSessionQueue
s {$sel:gameSessionQueueArn:GameSessionQueue' :: Maybe Text
gameSessionQueueArn = Maybe Text
a} :: GameSessionQueue)

-- | A descriptive label that is associated with game session queue. Queue
-- names must be unique within each Region.
gameSessionQueue_name :: Lens.Lens' GameSessionQueue (Prelude.Maybe Prelude.Text)
gameSessionQueue_name :: Lens' GameSessionQueue (Maybe Text)
gameSessionQueue_name = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\GameSessionQueue' {Maybe Text
name :: Maybe Text
$sel:name:GameSessionQueue' :: GameSessionQueue -> Maybe Text
name} -> Maybe Text
name) (\s :: GameSessionQueue
s@GameSessionQueue' {} Maybe Text
a -> GameSessionQueue
s {$sel:name:GameSessionQueue' :: Maybe Text
name = Maybe Text
a} :: GameSessionQueue)

-- | An SNS topic ARN that is set up to receive game session placement
-- notifications. See
-- <https://docs.aws.amazon.com/gamelift/latest/developerguide/queue-notification.html Setting up notifications for game session placement>.
gameSessionQueue_notificationTarget :: Lens.Lens' GameSessionQueue (Prelude.Maybe Prelude.Text)
gameSessionQueue_notificationTarget :: Lens' GameSessionQueue (Maybe Text)
gameSessionQueue_notificationTarget = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\GameSessionQueue' {Maybe Text
notificationTarget :: Maybe Text
$sel:notificationTarget:GameSessionQueue' :: GameSessionQueue -> Maybe Text
notificationTarget} -> Maybe Text
notificationTarget) (\s :: GameSessionQueue
s@GameSessionQueue' {} Maybe Text
a -> GameSessionQueue
s {$sel:notificationTarget:GameSessionQueue' :: Maybe Text
notificationTarget = Maybe Text
a} :: GameSessionQueue)

-- | A set of policies that act as a sliding cap on player latency. FleetIQ
-- works to deliver low latency for most players in a game session. These
-- policies ensure that no individual player can be placed into a game with
-- unreasonably high latency. Use multiple policies to gradually relax
-- latency requirements a step at a time. Multiple policies are applied
-- based on their maximum allowed latency, starting with the lowest value.
gameSessionQueue_playerLatencyPolicies :: Lens.Lens' GameSessionQueue (Prelude.Maybe [PlayerLatencyPolicy])
gameSessionQueue_playerLatencyPolicies :: Lens' GameSessionQueue (Maybe [PlayerLatencyPolicy])
gameSessionQueue_playerLatencyPolicies = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\GameSessionQueue' {Maybe [PlayerLatencyPolicy]
playerLatencyPolicies :: Maybe [PlayerLatencyPolicy]
$sel:playerLatencyPolicies:GameSessionQueue' :: GameSessionQueue -> Maybe [PlayerLatencyPolicy]
playerLatencyPolicies} -> Maybe [PlayerLatencyPolicy]
playerLatencyPolicies) (\s :: GameSessionQueue
s@GameSessionQueue' {} Maybe [PlayerLatencyPolicy]
a -> GameSessionQueue
s {$sel:playerLatencyPolicies:GameSessionQueue' :: Maybe [PlayerLatencyPolicy]
playerLatencyPolicies = Maybe [PlayerLatencyPolicy]
a} :: GameSessionQueue) forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. 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 forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | Custom settings to use when prioritizing destinations and locations for
-- game session placements. This configuration replaces the FleetIQ default
-- prioritization process. Priority types that are not explicitly named
-- will be automatically applied at the end of the prioritization process.
gameSessionQueue_priorityConfiguration :: Lens.Lens' GameSessionQueue (Prelude.Maybe PriorityConfiguration)
gameSessionQueue_priorityConfiguration :: Lens' GameSessionQueue (Maybe PriorityConfiguration)
gameSessionQueue_priorityConfiguration = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\GameSessionQueue' {Maybe PriorityConfiguration
priorityConfiguration :: Maybe PriorityConfiguration
$sel:priorityConfiguration:GameSessionQueue' :: GameSessionQueue -> Maybe PriorityConfiguration
priorityConfiguration} -> Maybe PriorityConfiguration
priorityConfiguration) (\s :: GameSessionQueue
s@GameSessionQueue' {} Maybe PriorityConfiguration
a -> GameSessionQueue
s {$sel:priorityConfiguration:GameSessionQueue' :: Maybe PriorityConfiguration
priorityConfiguration = Maybe PriorityConfiguration
a} :: GameSessionQueue)

-- | The maximum time, in seconds, that a new game session placement request
-- remains in the queue. When a request exceeds this time, the game session
-- placement changes to a @TIMED_OUT@ status.
gameSessionQueue_timeoutInSeconds :: Lens.Lens' GameSessionQueue (Prelude.Maybe Prelude.Natural)
gameSessionQueue_timeoutInSeconds :: Lens' GameSessionQueue (Maybe Natural)
gameSessionQueue_timeoutInSeconds = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\GameSessionQueue' {Maybe Natural
timeoutInSeconds :: Maybe Natural
$sel:timeoutInSeconds:GameSessionQueue' :: GameSessionQueue -> Maybe Natural
timeoutInSeconds} -> Maybe Natural
timeoutInSeconds) (\s :: GameSessionQueue
s@GameSessionQueue' {} Maybe Natural
a -> GameSessionQueue
s {$sel:timeoutInSeconds:GameSessionQueue' :: Maybe Natural
timeoutInSeconds = Maybe Natural
a} :: GameSessionQueue)

instance Data.FromJSON GameSessionQueue where
  parseJSON :: Value -> Parser GameSessionQueue
parseJSON =
    forall a. String -> (Object -> Parser a) -> Value -> Parser a
Data.withObject
      String
"GameSessionQueue"
      ( \Object
x ->
          Maybe Text
-> Maybe [GameSessionQueueDestination]
-> Maybe FilterConfiguration
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe [PlayerLatencyPolicy]
-> Maybe PriorityConfiguration
-> Maybe Natural
-> GameSessionQueue
GameSessionQueue'
            forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"CustomEventData")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"Destinations" forall a. Parser (Maybe a) -> a -> Parser a
Data..!= forall a. Monoid a => a
Prelude.mempty)
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"FilterConfiguration")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"GameSessionQueueArn")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"Name")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"NotificationTarget")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ( Object
x
                            forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"PlayerLatencyPolicies"
                            forall a. Parser (Maybe a) -> a -> Parser a
Data..!= forall a. Monoid a => a
Prelude.mempty
                        )
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"PriorityConfiguration")
            forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> (Object
x forall a. FromJSON a => Object -> Key -> Parser (Maybe a)
Data..:? Key
"TimeoutInSeconds")
      )

instance Prelude.Hashable GameSessionQueue where
  hashWithSalt :: Int -> GameSessionQueue -> Int
hashWithSalt Int
_salt GameSessionQueue' {Maybe Natural
Maybe [GameSessionQueueDestination]
Maybe [PlayerLatencyPolicy]
Maybe Text
Maybe FilterConfiguration
Maybe PriorityConfiguration
timeoutInSeconds :: Maybe Natural
priorityConfiguration :: Maybe PriorityConfiguration
playerLatencyPolicies :: Maybe [PlayerLatencyPolicy]
notificationTarget :: Maybe Text
name :: Maybe Text
gameSessionQueueArn :: Maybe Text
filterConfiguration :: Maybe FilterConfiguration
destinations :: Maybe [GameSessionQueueDestination]
customEventData :: Maybe Text
$sel:timeoutInSeconds:GameSessionQueue' :: GameSessionQueue -> Maybe Natural
$sel:priorityConfiguration:GameSessionQueue' :: GameSessionQueue -> Maybe PriorityConfiguration
$sel:playerLatencyPolicies:GameSessionQueue' :: GameSessionQueue -> Maybe [PlayerLatencyPolicy]
$sel:notificationTarget:GameSessionQueue' :: GameSessionQueue -> Maybe Text
$sel:name:GameSessionQueue' :: GameSessionQueue -> Maybe Text
$sel:gameSessionQueueArn:GameSessionQueue' :: GameSessionQueue -> Maybe Text
$sel:filterConfiguration:GameSessionQueue' :: GameSessionQueue -> Maybe FilterConfiguration
$sel:destinations:GameSessionQueue' :: GameSessionQueue -> Maybe [GameSessionQueueDestination]
$sel:customEventData:GameSessionQueue' :: GameSessionQueue -> Maybe Text
..} =
    Int
_salt
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
customEventData
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe [GameSessionQueueDestination]
destinations
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe FilterConfiguration
filterConfiguration
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
gameSessionQueueArn
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
name
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Text
notificationTarget
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe [PlayerLatencyPolicy]
playerLatencyPolicies
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe PriorityConfiguration
priorityConfiguration
      forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Maybe Natural
timeoutInSeconds

instance Prelude.NFData GameSessionQueue where
  rnf :: GameSessionQueue -> ()
rnf GameSessionQueue' {Maybe Natural
Maybe [GameSessionQueueDestination]
Maybe [PlayerLatencyPolicy]
Maybe Text
Maybe FilterConfiguration
Maybe PriorityConfiguration
timeoutInSeconds :: Maybe Natural
priorityConfiguration :: Maybe PriorityConfiguration
playerLatencyPolicies :: Maybe [PlayerLatencyPolicy]
notificationTarget :: Maybe Text
name :: Maybe Text
gameSessionQueueArn :: Maybe Text
filterConfiguration :: Maybe FilterConfiguration
destinations :: Maybe [GameSessionQueueDestination]
customEventData :: Maybe Text
$sel:timeoutInSeconds:GameSessionQueue' :: GameSessionQueue -> Maybe Natural
$sel:priorityConfiguration:GameSessionQueue' :: GameSessionQueue -> Maybe PriorityConfiguration
$sel:playerLatencyPolicies:GameSessionQueue' :: GameSessionQueue -> Maybe [PlayerLatencyPolicy]
$sel:notificationTarget:GameSessionQueue' :: GameSessionQueue -> Maybe Text
$sel:name:GameSessionQueue' :: GameSessionQueue -> Maybe Text
$sel:gameSessionQueueArn:GameSessionQueue' :: GameSessionQueue -> Maybe Text
$sel:filterConfiguration:GameSessionQueue' :: GameSessionQueue -> Maybe FilterConfiguration
$sel:destinations:GameSessionQueue' :: GameSessionQueue -> Maybe [GameSessionQueueDestination]
$sel:customEventData:GameSessionQueue' :: GameSessionQueue -> Maybe Text
..} =
    forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
customEventData
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe [GameSessionQueueDestination]
destinations
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe FilterConfiguration
filterConfiguration
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
gameSessionQueueArn
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
name
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Text
notificationTarget
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe [PlayerLatencyPolicy]
playerLatencyPolicies
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe PriorityConfiguration
priorityConfiguration
      seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Maybe Natural
timeoutInSeconds