{-# 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.RDS.Types.UpgradeTarget
-- 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.RDS.Types.UpgradeTarget where

import qualified Amazonka.Core as Core
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude

-- | The version of the database engine that a DB instance can be upgraded
-- to.
--
-- /See:/ 'newUpgradeTarget' smart constructor.
data UpgradeTarget = UpgradeTarget'
  { -- | The version number of the upgrade target database engine.
    UpgradeTarget -> Maybe Text
engineVersion :: Prelude.Maybe Prelude.Text,
    -- | A list of the supported DB engine modes for the target engine version.
    UpgradeTarget -> Maybe [Text]
supportedEngineModes :: Prelude.Maybe [Prelude.Text],
    -- | A value that indicates whether upgrading to the target version requires
    -- upgrading the major version of the database engine.
    UpgradeTarget -> Maybe Bool
isMajorVersionUpgrade :: Prelude.Maybe Prelude.Bool,
    -- | The name of the upgrade target database engine.
    UpgradeTarget -> Maybe Text
engine :: Prelude.Maybe Prelude.Text,
    -- | A value that indicates whether you can use Aurora global databases with
    -- the target engine version.
    UpgradeTarget -> Maybe Bool
supportsGlobalDatabases :: Prelude.Maybe Prelude.Bool,
    -- | A value that indicates whether the target version is applied to any
    -- source DB instances that have @AutoMinorVersionUpgrade@ set to true.
    UpgradeTarget -> Maybe Bool
autoUpgrade :: Prelude.Maybe Prelude.Bool,
    -- | A value that indicates whether you can use Aurora parallel query with
    -- the target engine version.
    UpgradeTarget -> Maybe Bool
supportsParallelQuery :: Prelude.Maybe Prelude.Bool,
    -- | The version of the database engine that a DB instance can be upgraded
    -- to.
    UpgradeTarget -> Maybe Text
description :: Prelude.Maybe Prelude.Text
  }
  deriving (UpgradeTarget -> UpgradeTarget -> Bool
(UpgradeTarget -> UpgradeTarget -> Bool)
-> (UpgradeTarget -> UpgradeTarget -> Bool) -> Eq UpgradeTarget
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: UpgradeTarget -> UpgradeTarget -> Bool
$c/= :: UpgradeTarget -> UpgradeTarget -> Bool
== :: UpgradeTarget -> UpgradeTarget -> Bool
$c== :: UpgradeTarget -> UpgradeTarget -> Bool
Prelude.Eq, ReadPrec [UpgradeTarget]
ReadPrec UpgradeTarget
Int -> ReadS UpgradeTarget
ReadS [UpgradeTarget]
(Int -> ReadS UpgradeTarget)
-> ReadS [UpgradeTarget]
-> ReadPrec UpgradeTarget
-> ReadPrec [UpgradeTarget]
-> Read UpgradeTarget
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [UpgradeTarget]
$creadListPrec :: ReadPrec [UpgradeTarget]
readPrec :: ReadPrec UpgradeTarget
$creadPrec :: ReadPrec UpgradeTarget
readList :: ReadS [UpgradeTarget]
$creadList :: ReadS [UpgradeTarget]
readsPrec :: Int -> ReadS UpgradeTarget
$creadsPrec :: Int -> ReadS UpgradeTarget
Prelude.Read, Int -> UpgradeTarget -> ShowS
[UpgradeTarget] -> ShowS
UpgradeTarget -> String
(Int -> UpgradeTarget -> ShowS)
-> (UpgradeTarget -> String)
-> ([UpgradeTarget] -> ShowS)
-> Show UpgradeTarget
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [UpgradeTarget] -> ShowS
$cshowList :: [UpgradeTarget] -> ShowS
show :: UpgradeTarget -> String
$cshow :: UpgradeTarget -> String
showsPrec :: Int -> UpgradeTarget -> ShowS
$cshowsPrec :: Int -> UpgradeTarget -> ShowS
Prelude.Show, (forall x. UpgradeTarget -> Rep UpgradeTarget x)
-> (forall x. Rep UpgradeTarget x -> UpgradeTarget)
-> Generic UpgradeTarget
forall x. Rep UpgradeTarget x -> UpgradeTarget
forall x. UpgradeTarget -> Rep UpgradeTarget x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep UpgradeTarget x -> UpgradeTarget
$cfrom :: forall x. UpgradeTarget -> Rep UpgradeTarget x
Prelude.Generic)

-- |
-- Create a value of 'UpgradeTarget' 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:
--
-- 'engineVersion', 'upgradeTarget_engineVersion' - The version number of the upgrade target database engine.
--
-- 'supportedEngineModes', 'upgradeTarget_supportedEngineModes' - A list of the supported DB engine modes for the target engine version.
--
-- 'isMajorVersionUpgrade', 'upgradeTarget_isMajorVersionUpgrade' - A value that indicates whether upgrading to the target version requires
-- upgrading the major version of the database engine.
--
-- 'engine', 'upgradeTarget_engine' - The name of the upgrade target database engine.
--
-- 'supportsGlobalDatabases', 'upgradeTarget_supportsGlobalDatabases' - A value that indicates whether you can use Aurora global databases with
-- the target engine version.
--
-- 'autoUpgrade', 'upgradeTarget_autoUpgrade' - A value that indicates whether the target version is applied to any
-- source DB instances that have @AutoMinorVersionUpgrade@ set to true.
--
-- 'supportsParallelQuery', 'upgradeTarget_supportsParallelQuery' - A value that indicates whether you can use Aurora parallel query with
-- the target engine version.
--
-- 'description', 'upgradeTarget_description' - The version of the database engine that a DB instance can be upgraded
-- to.
newUpgradeTarget ::
  UpgradeTarget
newUpgradeTarget :: UpgradeTarget
newUpgradeTarget =
  UpgradeTarget' :: Maybe Text
-> Maybe [Text]
-> Maybe Bool
-> Maybe Text
-> Maybe Bool
-> Maybe Bool
-> Maybe Bool
-> Maybe Text
-> UpgradeTarget
UpgradeTarget'
    { $sel:engineVersion:UpgradeTarget' :: Maybe Text
engineVersion = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:supportedEngineModes:UpgradeTarget' :: Maybe [Text]
supportedEngineModes = Maybe [Text]
forall a. Maybe a
Prelude.Nothing,
      $sel:isMajorVersionUpgrade:UpgradeTarget' :: Maybe Bool
isMajorVersionUpgrade = Maybe Bool
forall a. Maybe a
Prelude.Nothing,
      $sel:engine:UpgradeTarget' :: Maybe Text
engine = Maybe Text
forall a. Maybe a
Prelude.Nothing,
      $sel:supportsGlobalDatabases:UpgradeTarget' :: Maybe Bool
supportsGlobalDatabases = Maybe Bool
forall a. Maybe a
Prelude.Nothing,
      $sel:autoUpgrade:UpgradeTarget' :: Maybe Bool
autoUpgrade = Maybe Bool
forall a. Maybe a
Prelude.Nothing,
      $sel:supportsParallelQuery:UpgradeTarget' :: Maybe Bool
supportsParallelQuery = Maybe Bool
forall a. Maybe a
Prelude.Nothing,
      $sel:description:UpgradeTarget' :: Maybe Text
description = Maybe Text
forall a. Maybe a
Prelude.Nothing
    }

-- | The version number of the upgrade target database engine.
upgradeTarget_engineVersion :: Lens.Lens' UpgradeTarget (Prelude.Maybe Prelude.Text)
upgradeTarget_engineVersion :: (Maybe Text -> f (Maybe Text)) -> UpgradeTarget -> f UpgradeTarget
upgradeTarget_engineVersion = (UpgradeTarget -> Maybe Text)
-> (UpgradeTarget -> Maybe Text -> UpgradeTarget)
-> Lens UpgradeTarget UpgradeTarget (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpgradeTarget' {Maybe Text
engineVersion :: Maybe Text
$sel:engineVersion:UpgradeTarget' :: UpgradeTarget -> Maybe Text
engineVersion} -> Maybe Text
engineVersion) (\s :: UpgradeTarget
s@UpgradeTarget' {} Maybe Text
a -> UpgradeTarget
s {$sel:engineVersion:UpgradeTarget' :: Maybe Text
engineVersion = Maybe Text
a} :: UpgradeTarget)

-- | A list of the supported DB engine modes for the target engine version.
upgradeTarget_supportedEngineModes :: Lens.Lens' UpgradeTarget (Prelude.Maybe [Prelude.Text])
upgradeTarget_supportedEngineModes :: (Maybe [Text] -> f (Maybe [Text]))
-> UpgradeTarget -> f UpgradeTarget
upgradeTarget_supportedEngineModes = (UpgradeTarget -> Maybe [Text])
-> (UpgradeTarget -> Maybe [Text] -> UpgradeTarget)
-> Lens UpgradeTarget UpgradeTarget (Maybe [Text]) (Maybe [Text])
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpgradeTarget' {Maybe [Text]
supportedEngineModes :: Maybe [Text]
$sel:supportedEngineModes:UpgradeTarget' :: UpgradeTarget -> Maybe [Text]
supportedEngineModes} -> Maybe [Text]
supportedEngineModes) (\s :: UpgradeTarget
s@UpgradeTarget' {} Maybe [Text]
a -> UpgradeTarget
s {$sel:supportedEngineModes:UpgradeTarget' :: Maybe [Text]
supportedEngineModes = Maybe [Text]
a} :: UpgradeTarget) ((Maybe [Text] -> f (Maybe [Text]))
 -> UpgradeTarget -> f UpgradeTarget)
-> ((Maybe [Text] -> f (Maybe [Text]))
    -> Maybe [Text] -> f (Maybe [Text]))
-> (Maybe [Text] -> f (Maybe [Text]))
-> UpgradeTarget
-> f UpgradeTarget
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. AnIso [Text] [Text] [Text] [Text]
-> Iso (Maybe [Text]) (Maybe [Text]) (Maybe [Text]) (Maybe [Text])
forall (f :: * -> *) (g :: * -> *) s t a b.
(Functor f, Functor g) =>
AnIso s t a b -> Iso (f s) (g t) (f a) (g b)
Lens.mapping AnIso [Text] [Text] [Text] [Text]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced

-- | A value that indicates whether upgrading to the target version requires
-- upgrading the major version of the database engine.
upgradeTarget_isMajorVersionUpgrade :: Lens.Lens' UpgradeTarget (Prelude.Maybe Prelude.Bool)
upgradeTarget_isMajorVersionUpgrade :: (Maybe Bool -> f (Maybe Bool)) -> UpgradeTarget -> f UpgradeTarget
upgradeTarget_isMajorVersionUpgrade = (UpgradeTarget -> Maybe Bool)
-> (UpgradeTarget -> Maybe Bool -> UpgradeTarget)
-> Lens UpgradeTarget UpgradeTarget (Maybe Bool) (Maybe Bool)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpgradeTarget' {Maybe Bool
isMajorVersionUpgrade :: Maybe Bool
$sel:isMajorVersionUpgrade:UpgradeTarget' :: UpgradeTarget -> Maybe Bool
isMajorVersionUpgrade} -> Maybe Bool
isMajorVersionUpgrade) (\s :: UpgradeTarget
s@UpgradeTarget' {} Maybe Bool
a -> UpgradeTarget
s {$sel:isMajorVersionUpgrade:UpgradeTarget' :: Maybe Bool
isMajorVersionUpgrade = Maybe Bool
a} :: UpgradeTarget)

-- | The name of the upgrade target database engine.
upgradeTarget_engine :: Lens.Lens' UpgradeTarget (Prelude.Maybe Prelude.Text)
upgradeTarget_engine :: (Maybe Text -> f (Maybe Text)) -> UpgradeTarget -> f UpgradeTarget
upgradeTarget_engine = (UpgradeTarget -> Maybe Text)
-> (UpgradeTarget -> Maybe Text -> UpgradeTarget)
-> Lens UpgradeTarget UpgradeTarget (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpgradeTarget' {Maybe Text
engine :: Maybe Text
$sel:engine:UpgradeTarget' :: UpgradeTarget -> Maybe Text
engine} -> Maybe Text
engine) (\s :: UpgradeTarget
s@UpgradeTarget' {} Maybe Text
a -> UpgradeTarget
s {$sel:engine:UpgradeTarget' :: Maybe Text
engine = Maybe Text
a} :: UpgradeTarget)

-- | A value that indicates whether you can use Aurora global databases with
-- the target engine version.
upgradeTarget_supportsGlobalDatabases :: Lens.Lens' UpgradeTarget (Prelude.Maybe Prelude.Bool)
upgradeTarget_supportsGlobalDatabases :: (Maybe Bool -> f (Maybe Bool)) -> UpgradeTarget -> f UpgradeTarget
upgradeTarget_supportsGlobalDatabases = (UpgradeTarget -> Maybe Bool)
-> (UpgradeTarget -> Maybe Bool -> UpgradeTarget)
-> Lens UpgradeTarget UpgradeTarget (Maybe Bool) (Maybe Bool)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpgradeTarget' {Maybe Bool
supportsGlobalDatabases :: Maybe Bool
$sel:supportsGlobalDatabases:UpgradeTarget' :: UpgradeTarget -> Maybe Bool
supportsGlobalDatabases} -> Maybe Bool
supportsGlobalDatabases) (\s :: UpgradeTarget
s@UpgradeTarget' {} Maybe Bool
a -> UpgradeTarget
s {$sel:supportsGlobalDatabases:UpgradeTarget' :: Maybe Bool
supportsGlobalDatabases = Maybe Bool
a} :: UpgradeTarget)

-- | A value that indicates whether the target version is applied to any
-- source DB instances that have @AutoMinorVersionUpgrade@ set to true.
upgradeTarget_autoUpgrade :: Lens.Lens' UpgradeTarget (Prelude.Maybe Prelude.Bool)
upgradeTarget_autoUpgrade :: (Maybe Bool -> f (Maybe Bool)) -> UpgradeTarget -> f UpgradeTarget
upgradeTarget_autoUpgrade = (UpgradeTarget -> Maybe Bool)
-> (UpgradeTarget -> Maybe Bool -> UpgradeTarget)
-> Lens UpgradeTarget UpgradeTarget (Maybe Bool) (Maybe Bool)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpgradeTarget' {Maybe Bool
autoUpgrade :: Maybe Bool
$sel:autoUpgrade:UpgradeTarget' :: UpgradeTarget -> Maybe Bool
autoUpgrade} -> Maybe Bool
autoUpgrade) (\s :: UpgradeTarget
s@UpgradeTarget' {} Maybe Bool
a -> UpgradeTarget
s {$sel:autoUpgrade:UpgradeTarget' :: Maybe Bool
autoUpgrade = Maybe Bool
a} :: UpgradeTarget)

-- | A value that indicates whether you can use Aurora parallel query with
-- the target engine version.
upgradeTarget_supportsParallelQuery :: Lens.Lens' UpgradeTarget (Prelude.Maybe Prelude.Bool)
upgradeTarget_supportsParallelQuery :: (Maybe Bool -> f (Maybe Bool)) -> UpgradeTarget -> f UpgradeTarget
upgradeTarget_supportsParallelQuery = (UpgradeTarget -> Maybe Bool)
-> (UpgradeTarget -> Maybe Bool -> UpgradeTarget)
-> Lens UpgradeTarget UpgradeTarget (Maybe Bool) (Maybe Bool)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpgradeTarget' {Maybe Bool
supportsParallelQuery :: Maybe Bool
$sel:supportsParallelQuery:UpgradeTarget' :: UpgradeTarget -> Maybe Bool
supportsParallelQuery} -> Maybe Bool
supportsParallelQuery) (\s :: UpgradeTarget
s@UpgradeTarget' {} Maybe Bool
a -> UpgradeTarget
s {$sel:supportsParallelQuery:UpgradeTarget' :: Maybe Bool
supportsParallelQuery = Maybe Bool
a} :: UpgradeTarget)

-- | The version of the database engine that a DB instance can be upgraded
-- to.
upgradeTarget_description :: Lens.Lens' UpgradeTarget (Prelude.Maybe Prelude.Text)
upgradeTarget_description :: (Maybe Text -> f (Maybe Text)) -> UpgradeTarget -> f UpgradeTarget
upgradeTarget_description = (UpgradeTarget -> Maybe Text)
-> (UpgradeTarget -> Maybe Text -> UpgradeTarget)
-> Lens UpgradeTarget UpgradeTarget (Maybe Text) (Maybe Text)
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UpgradeTarget' {Maybe Text
description :: Maybe Text
$sel:description:UpgradeTarget' :: UpgradeTarget -> Maybe Text
description} -> Maybe Text
description) (\s :: UpgradeTarget
s@UpgradeTarget' {} Maybe Text
a -> UpgradeTarget
s {$sel:description:UpgradeTarget' :: Maybe Text
description = Maybe Text
a} :: UpgradeTarget)

instance Core.FromXML UpgradeTarget where
  parseXML :: [Node] -> Either String UpgradeTarget
parseXML [Node]
x =
    Maybe Text
-> Maybe [Text]
-> Maybe Bool
-> Maybe Text
-> Maybe Bool
-> Maybe Bool
-> Maybe Bool
-> Maybe Text
-> UpgradeTarget
UpgradeTarget'
      (Maybe Text
 -> Maybe [Text]
 -> Maybe Bool
 -> Maybe Text
 -> Maybe Bool
 -> Maybe Bool
 -> Maybe Bool
 -> Maybe Text
 -> UpgradeTarget)
-> Either String (Maybe Text)
-> Either
     String
     (Maybe [Text]
      -> Maybe Bool
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Bool
      -> Maybe Bool
      -> Maybe Text
      -> UpgradeTarget)
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Prelude.<$> ([Node]
x [Node] -> Text -> Either String (Maybe Text)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"EngineVersion")
      Either
  String
  (Maybe [Text]
   -> Maybe Bool
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Bool
   -> Maybe Bool
   -> Maybe Text
   -> UpgradeTarget)
-> Either String (Maybe [Text])
-> Either
     String
     (Maybe Bool
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Bool
      -> Maybe Bool
      -> Maybe Text
      -> UpgradeTarget)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ( [Node]
x [Node] -> Text -> Either String (Maybe [Node])
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"SupportedEngineModes"
                      Either String (Maybe [Node]) -> [Node] -> Either String [Node]
forall (f :: * -> *) a. Functor f => f (Maybe a) -> a -> f a
Core..!@ [Node]
forall a. Monoid a => a
Prelude.mempty
                      Either String [Node]
-> ([Node] -> Either String (Maybe [Text]))
-> Either String (Maybe [Text])
forall (m :: * -> *) a b. Monad m => m a -> (a -> m b) -> m b
Prelude.>>= ([Node] -> Either String [Text])
-> [Node] -> Either String (Maybe [Text])
forall (f :: * -> *) a b.
Applicative f =>
([a] -> f b) -> [a] -> f (Maybe b)
Core.may (Text -> [Node] -> Either String [Text]
forall a. FromXML a => Text -> [Node] -> Either String [a]
Core.parseXMLList Text
"member")
                  )
      Either
  String
  (Maybe Bool
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Bool
   -> Maybe Bool
   -> Maybe Text
   -> UpgradeTarget)
-> Either String (Maybe Bool)
-> Either
     String
     (Maybe Text
      -> Maybe Bool
      -> Maybe Bool
      -> Maybe Bool
      -> Maybe Text
      -> UpgradeTarget)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node] -> Text -> Either String (Maybe Bool)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"IsMajorVersionUpgrade")
      Either
  String
  (Maybe Text
   -> Maybe Bool
   -> Maybe Bool
   -> Maybe Bool
   -> Maybe Text
   -> UpgradeTarget)
-> Either String (Maybe Text)
-> Either
     String
     (Maybe Bool
      -> Maybe Bool -> Maybe Bool -> Maybe Text -> UpgradeTarget)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node] -> Text -> Either String (Maybe Text)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"Engine")
      Either
  String
  (Maybe Bool
   -> Maybe Bool -> Maybe Bool -> Maybe Text -> UpgradeTarget)
-> Either String (Maybe Bool)
-> Either
     String (Maybe Bool -> Maybe Bool -> Maybe Text -> UpgradeTarget)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node] -> Text -> Either String (Maybe Bool)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"SupportsGlobalDatabases")
      Either
  String (Maybe Bool -> Maybe Bool -> Maybe Text -> UpgradeTarget)
-> Either String (Maybe Bool)
-> Either String (Maybe Bool -> Maybe Text -> UpgradeTarget)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node] -> Text -> Either String (Maybe Bool)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"AutoUpgrade")
      Either String (Maybe Bool -> Maybe Text -> UpgradeTarget)
-> Either String (Maybe Bool)
-> Either String (Maybe Text -> UpgradeTarget)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node] -> Text -> Either String (Maybe Bool)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"SupportsParallelQuery")
      Either String (Maybe Text -> UpgradeTarget)
-> Either String (Maybe Text) -> Either String UpgradeTarget
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
Prelude.<*> ([Node]
x [Node] -> Text -> Either String (Maybe Text)
forall a. FromXML a => [Node] -> Text -> Either String (Maybe a)
Core..@? Text
"Description")

instance Prelude.Hashable UpgradeTarget

instance Prelude.NFData UpgradeTarget