{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
{-# OPTIONS_GHC -fno-warn-unused-binds #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
module Network.Google.Resource.ReplicaPoolUpdater.RollingUpdates.Pause
(
RollingUpdatesPauseResource
, rollingUpdatesPause
, RollingUpdatesPause
, rupRollingUpdate
, rupProject
, rupZone
) where
import Network.Google.Prelude
import Network.Google.ReplicaPoolUpdater.Types
type RollingUpdatesPauseResource =
"replicapoolupdater" :>
"v1beta1" :>
"projects" :>
Capture "project" Text :>
"zones" :>
Capture "zone" Text :>
"rollingUpdates" :>
Capture "rollingUpdate" Text :>
"pause" :>
QueryParam "alt" AltJSON :> Post '[JSON] Operation
data RollingUpdatesPause = RollingUpdatesPause'
{ _rupRollingUpdate :: !Text
, _rupProject :: !Text
, _rupZone :: !Text
} deriving (Eq,Show,Data,Typeable,Generic)
rollingUpdatesPause
:: Text
-> Text
-> Text
-> RollingUpdatesPause
rollingUpdatesPause pRupRollingUpdate_ pRupProject_ pRupZone_ =
RollingUpdatesPause'
{ _rupRollingUpdate = pRupRollingUpdate_
, _rupProject = pRupProject_
, _rupZone = pRupZone_
}
rupRollingUpdate :: Lens' RollingUpdatesPause Text
rupRollingUpdate
= lens _rupRollingUpdate
(\ s a -> s{_rupRollingUpdate = a})
rupProject :: Lens' RollingUpdatesPause Text
rupProject
= lens _rupProject (\ s a -> s{_rupProject = a})
rupZone :: Lens' RollingUpdatesPause Text
rupZone = lens _rupZone (\ s a -> s{_rupZone = a})
instance GoogleRequest RollingUpdatesPause where
type Rs RollingUpdatesPause = Operation
type Scopes RollingUpdatesPause =
'["https://www.googleapis.com/auth/cloud-platform",
"https://www.googleapis.com/auth/replicapool"]
requestClient RollingUpdatesPause'{..}
= go _rupProject _rupZone _rupRollingUpdate
(Just AltJSON)
replicaPoolUpdaterService
where go
= buildClient
(Proxy :: Proxy RollingUpdatesPauseResource)
mempty