module Network.AWS.Redshift.ResetClusterParameterGroup
(
resetClusterParameterGroup
, ResetClusterParameterGroup
, rcpgResetAllParameters
, rcpgParameters
, rcpgParameterGroupName
, clusterParameterGroupNameMessage
, ClusterParameterGroupNameMessage
, cpgnmParameterGroupStatus
, cpgnmParameterGroupName
) where
import Network.AWS.Prelude
import Network.AWS.Redshift.Types
import Network.AWS.Redshift.Types.Product
import Network.AWS.Request
import Network.AWS.Response
data ResetClusterParameterGroup = ResetClusterParameterGroup'
{ _rcpgResetAllParameters :: !(Maybe Bool)
, _rcpgParameters :: !(Maybe [Parameter])
, _rcpgParameterGroupName :: !Text
} deriving (Eq,Read,Show,Data,Typeable,Generic)
resetClusterParameterGroup
:: Text
-> ResetClusterParameterGroup
resetClusterParameterGroup pParameterGroupName_ =
ResetClusterParameterGroup'
{ _rcpgResetAllParameters = Nothing
, _rcpgParameters = Nothing
, _rcpgParameterGroupName = pParameterGroupName_
}
rcpgResetAllParameters :: Lens' ResetClusterParameterGroup (Maybe Bool)
rcpgResetAllParameters = lens _rcpgResetAllParameters (\ s a -> s{_rcpgResetAllParameters = a});
rcpgParameters :: Lens' ResetClusterParameterGroup [Parameter]
rcpgParameters = lens _rcpgParameters (\ s a -> s{_rcpgParameters = a}) . _Default . _Coerce;
rcpgParameterGroupName :: Lens' ResetClusterParameterGroup Text
rcpgParameterGroupName = lens _rcpgParameterGroupName (\ s a -> s{_rcpgParameterGroupName = a});
instance AWSRequest ResetClusterParameterGroup where
type Rs ResetClusterParameterGroup =
ClusterParameterGroupNameMessage
request = postQuery redshift
response
= receiveXMLWrapper
"ResetClusterParameterGroupResult"
(\ s h x -> parseXML x)
instance ToHeaders ResetClusterParameterGroup where
toHeaders = const mempty
instance ToPath ResetClusterParameterGroup where
toPath = const "/"
instance ToQuery ResetClusterParameterGroup where
toQuery ResetClusterParameterGroup'{..}
= mconcat
["Action" =:
("ResetClusterParameterGroup" :: ByteString),
"Version" =: ("2012-12-01" :: ByteString),
"ResetAllParameters" =: _rcpgResetAllParameters,
"Parameters" =:
toQuery
(toQueryList "Parameter" <$> _rcpgParameters),
"ParameterGroupName" =: _rcpgParameterGroupName]