packages feed

amazonka-autoscaling-plans (empty) → 1.6.0

raw patch · 29 files changed

+3140/−0 lines, 29 filesdep +amazonka-autoscaling-plansdep +amazonka-coredep +amazonka-testsetup-changed

Dependencies added: amazonka-autoscaling-plans, amazonka-core, amazonka-test, base, bytestring, tasty, tasty-hunit, text, time, unordered-containers

Files

+ LICENSE view
@@ -0,0 +1,367 @@+Mozilla Public License Version 2.0+==================================++1. Definitions+--------------++1.1. "Contributor"+    means each individual or legal entity that creates, contributes to+    the creation of, or owns Covered Software.++1.2. "Contributor Version"+    means the combination of the Contributions of others (if any) used+    by a Contributor and that particular Contributor's Contribution.++1.3. "Contribution"+    means Covered Software of a particular Contributor.++1.4. "Covered Software"+    means Source Code Form to which the initial Contributor has attached+    the notice in Exhibit A, the Executable Form of such Source Code+    Form, and Modifications of such Source Code Form, in each case+    including portions thereof.++1.5. "Incompatible With Secondary Licenses"+    means++    (a) that the initial Contributor has attached the notice described+        in Exhibit B to the Covered Software; or++    (b) that the Covered Software was made available under the terms of+        version 1.1 or earlier of the License, but not also under the+        terms of a Secondary License.++1.6. "Executable Form"+    means any form of the work other than Source Code Form.++1.7. "Larger Work"+    means a work that combines Covered Software with other material, in+    a separate file or files, that is not Covered Software.++1.8. "License"+    means this document.++1.9. "Licensable"+    means having the right to grant, to the maximum extent possible,+    whether at the time of the initial grant or subsequently, any and+    all of the rights conveyed by this License.++1.10. "Modifications"+    means any of the following:++    (a) any file in Source Code Form that results from an addition to,+        deletion from, or modification of the contents of Covered+        Software; or++    (b) any new file in Source Code Form that contains any Covered+        Software.++1.11. "Patent Claims" of a Contributor+    means any patent claim(s), including without limitation, method,+    process, and apparatus claims, in any patent Licensable by such+    Contributor that would be infringed, but for the grant of the+    License, by the making, using, selling, offering for sale, having+    made, import, or transfer of either its Contributions or its+    Contributor Version.++1.12. "Secondary License"+    means either the GNU General Public License, Version 2.0, the GNU+    Lesser General Public License, Version 2.1, the GNU Affero General+    Public License, Version 3.0, or any later versions of those+    licenses.++1.13. "Source Code Form"+    means the form of the work preferred for making modifications.++1.14. "You" (or "Your")+    means an individual or a legal entity exercising rights under this+    License. For legal entities, "You" includes any entity that+    controls, is controlled by, or is under common control with You. For+    purposes of this definition, "control" means (a) the power, direct+    or indirect, to cause the direction or management of such entity,+    whether by contract or otherwise, or (b) ownership of more than+    fifty percent (50%) of the outstanding shares or beneficial+    ownership of such entity.++2. License Grants and Conditions+--------------------------------++2.1. Grants++Each Contributor hereby grants You a world-wide, royalty-free,+non-exclusive license:++(a) under intellectual property rights (other than patent or trademark)+    Licensable by such Contributor to use, reproduce, make available,+    modify, display, perform, distribute, and otherwise exploit its+    Contributions, either on an unmodified basis, with Modifications, or+    as part of a Larger Work; and++(b) under Patent Claims of such Contributor to make, use, sell, offer+    for sale, have made, import, and otherwise transfer either its+    Contributions or its Contributor Version.++2.2. Effective Date++The licenses granted in Section 2.1 with respect to any Contribution+become effective for each Contribution on the date the Contributor first+distributes such Contribution.++2.3. Limitations on Grant Scope++The licenses granted in this Section 2 are the only rights granted under+this License. No additional rights or licenses will be implied from the+distribution or licensing of Covered Software under this License.+Notwithstanding Section 2.1(b) above, no patent license is granted by a+Contributor:++(a) for any code that a Contributor has removed from Covered Software;+    or++(b) for infringements caused by: (i) Your and any other third party's+    modifications of Covered Software, or (ii) the combination of its+    Contributions with other software (except as part of its Contributor+    Version); or++(c) under Patent Claims infringed by Covered Software in the absence of+    its Contributions.++This License does not grant any rights in the trademarks, service marks,+or logos of any Contributor (except as may be necessary to comply with+the notice requirements in Section 3.4).++2.4. Subsequent Licenses++No Contributor makes additional grants as a result of Your choice to+distribute the Covered Software under a subsequent version of this+License (see Section 10.2) or under the terms of a Secondary License (if+permitted under the terms of Section 3.3).++2.5. Representation++Each Contributor represents that the Contributor believes its+Contributions are its original creation(s) or it has sufficient rights+to grant the rights to its Contributions conveyed by this License.++2.6. Fair Use++This License is not intended to limit any rights You have under+applicable copyright doctrines of fair use, fair dealing, or other+equivalents.++2.7. Conditions++Sections 3.1, 3.2, 3.3, and 3.4 are conditions of the licenses granted+in Section 2.1.++3. Responsibilities+-------------------++3.1. Distribution of Source Form++All distribution of Covered Software in Source Code Form, including any+Modifications that You create or to which You contribute, must be under+the terms of this License. You must inform recipients that the Source+Code Form of the Covered Software is governed by the terms of this+License, and how they can obtain a copy of this License. You may not+attempt to alter or restrict the recipients' rights in the Source Code+Form.++3.2. Distribution of Executable Form++If You distribute Covered Software in Executable Form then:++(a) such Covered Software must also be made available in Source Code+    Form, as described in Section 3.1, and You must inform recipients of+    the Executable Form how they can obtain a copy of such Source Code+    Form by reasonable means in a timely manner, at a charge no more+    than the cost of distribution to the recipient; and++(b) You may distribute such Executable Form under the terms of this+    License, or sublicense it under different terms, provided that the+    license for the Executable Form does not attempt to limit or alter+    the recipients' rights in the Source Code Form under this License.++3.3. Distribution of a Larger Work++You may create and distribute a Larger Work under terms of Your choice,+provided that You also comply with the requirements of this License for+the Covered Software. If the Larger Work is a combination of Covered+Software with a work governed by one or more Secondary Licenses, and the+Covered Software is not Incompatible With Secondary Licenses, this+License permits You to additionally distribute such Covered Software+under the terms of such Secondary License(s), so that the recipient of+the Larger Work may, at their option, further distribute the Covered+Software under the terms of either this License or such Secondary+License(s).++3.4. Notices++You may not remove or alter the substance of any license notices+(including copyright notices, patent notices, disclaimers of warranty,+or limitations of liability) contained within the Source Code Form of+the Covered Software, except that You may alter any license notices to+the extent required to remedy known factual inaccuracies.++3.5. Application of Additional Terms++You may choose to offer, and to charge a fee for, warranty, support,+indemnity or liability obligations to one or more recipients of Covered+Software. However, You may do so only on Your own behalf, and not on+behalf of any Contributor. You must make it absolutely clear that any+such warranty, support, indemnity, or liability obligation is offered by+You alone, and You hereby agree to indemnify every Contributor for any+liability incurred by such Contributor as a result of warranty, support,+indemnity or liability terms You offer. You may include additional+disclaimers of warranty and limitations of liability specific to any+jurisdiction.++4. Inability to Comply Due to Statute or Regulation+---------------------------------------------------++If it is impossible for You to comply with any of the terms of this+License with respect to some or all of the Covered Software due to+statute, judicial order, or regulation then You must: (a) comply with+the terms of this License to the maximum extent possible; and (b)+describe the limitations and the code they affect. Such description must+be placed in a text file included with all distributions of the Covered+Software under this License. Except to the extent prohibited by statute+or regulation, such description must be sufficiently detailed for a+recipient of ordinary skill to be able to understand it.++5. Termination+--------------++5.1. The rights granted under this License will terminate automatically+if You fail to comply with any of its terms. However, if You become+compliant, then the rights granted under this License from a particular+Contributor are reinstated (a) provisionally, unless and until such+Contributor explicitly and finally terminates Your grants, and (b) on an+ongoing basis, if such Contributor fails to notify You of the+non-compliance by some reasonable means prior to 60 days after You have+come back into compliance. Moreover, Your grants from a particular+Contributor are reinstated on an ongoing basis if such Contributor+notifies You of the non-compliance by some reasonable means, this is the+first time You have received notice of non-compliance with this License+from such Contributor, and You become compliant prior to 30 days after+Your receipt of the notice.++5.2. If You initiate litigation against any entity by asserting a patent+infringement claim (excluding declaratory judgment actions,+counter-claims, and cross-claims) alleging that a Contributor Version+directly or indirectly infringes any patent, then the rights granted to+You by any and all Contributors for the Covered Software under Section+2.1 of this License shall terminate.++5.3. In the event of termination under Sections 5.1 or 5.2 above, all+end user license agreements (excluding distributors and resellers) which+have been validly granted by You or Your distributors under this License+prior to termination shall survive termination.++************************************************************************+*                                                                      *+*  6. Disclaimer of Warranty                                           *+*  -------------------------                                           *+*                                                                      *+*  Covered Software is provided under this License on an "as is"       *+*  basis, without warranty of any kind, either expressed, implied, or  *+*  statutory, including, without limitation, warranties that the       *+*  Covered Software is free of defects, merchantable, fit for a        *+*  particular purpose or non-infringing. The entire risk as to the     *+*  quality and performance of the Covered Software is with You.        *+*  Should any Covered Software prove defective in any respect, You     *+*  (not any Contributor) assume the cost of any necessary servicing,   *+*  repair, or correction. This disclaimer of warranty constitutes an   *+*  essential part of this License. No use of any Covered Software is   *+*  authorized under this License except under this disclaimer.         *+*                                                                      *+************************************************************************++************************************************************************+*                                                                      *+*  7. Limitation of Liability                                          *+*  --------------------------                                          *+*                                                                      *+*  Under no circumstances and under no legal theory, whether tort      *+*  (including negligence), contract, or otherwise, shall any           *+*  Contributor, or anyone who distributes Covered Software as          *+*  permitted above, be liable to You for any direct, indirect,         *+*  special, incidental, or consequential damages of any character      *+*  including, without limitation, damages for lost profits, loss of    *+*  goodwill, work stoppage, computer failure or malfunction, or any    *+*  and all other commercial damages or losses, even if such party      *+*  shall have been informed of the possibility of such damages. This   *+*  limitation of liability shall not apply to liability for death or   *+*  personal injury resulting from such party's negligence to the       *+*  extent applicable law prohibits such limitation. Some               *+*  jurisdictions do not allow the exclusion or limitation of           *+*  incidental or consequential damages, so this exclusion and          *+*  limitation may not apply to You.                                    *+*                                                                      *+************************************************************************++8. Litigation+-------------++Any litigation relating to this License may be brought only in the+courts of a jurisdiction where the defendant maintains its principal+place of business and such litigation shall be governed by laws of that+jurisdiction, without reference to its conflict-of-law provisions.+Nothing in this Section shall prevent a party's ability to bring+cross-claims or counter-claims.++9. Miscellaneous+----------------++This License represents the complete agreement concerning the subject+matter hereof. If any provision of this License is held to be+unenforceable, such provision shall be reformed only to the extent+necessary to make it enforceable. Any law or regulation which provides+that the language of a contract shall be construed against the drafter+shall not be used to construe this License against a Contributor.++10. Versions of the License+---------------------------++10.1. New Versions++Mozilla Foundation is the license steward. Except as provided in Section+10.3, no one other than the license steward has the right to modify or+publish new versions of this License. Each version will be given a+distinguishing version number.++10.2. Effect of New Versions++You may distribute the Covered Software under the terms of the version+of the License under which You originally received the Covered Software,+or under the terms of any subsequent version published by the license+steward.++10.3. Modified Versions++If you create software not governed by this License, and you want to+create a new license for such software, you may create and use a+modified version of this License if you rename the license and remove+any references to the name of the license steward (except to note that+such modified license differs from this License).++10.4. Distributing Source Code Form that is Incompatible With Secondary+Licenses++If You choose to distribute Source Code Form that is Incompatible With+Secondary Licenses under the terms of this version of the License, the+notice described in Exhibit B of this License must be attached.++Exhibit A - Source Code Form License Notice+-------------------------------------------++  This Source Code Form is subject to the terms of the Mozilla Public+  License, v. 2.0. If a copy of the MPL was not distributed with this+  file, You can obtain one at http://mozilla.org/MPL/2.0/.++If it is not possible or desirable to put the notice in a particular+file, then You may include the notice in a location (such as a LICENSE+file in a relevant directory) where a recipient would be likely to look+for such a notice.++You may add additional accurate notices of copyright ownership.
+ README.md view
@@ -0,0 +1,45 @@+# Amazon Auto Scaling Plans SDK++* [Version](#version)+* [Description](#description)+* [Contribute](#contribute)+* [Licence](#licence)+++## Version++`1.6.0`+++## Description++Documentation is available via [Hackage](http://hackage.haskell.org/package/amazonka-autoscaling-plans)+and the [AWS API Reference](https://aws.amazon.com/documentation/).++The types from this library are intended to be used with [amazonka](http://hackage.haskell.org/package/amazonka),+which provides mechanisms for specifying AuthN/AuthZ information, sending requests,+and receiving responses.++Lenses are used for constructing and manipulating types,+due to the depth of nesting of AWS types and transparency regarding+de/serialisation into more palatable Haskell values.+The provided lenses should be compatible with any of the major lens libraries+[lens](http://hackage.haskell.org/package/lens) or [lens-family-core](http://hackage.haskell.org/package/lens-family-core).++See [Network.AWS.AutoScalingPlans](http://hackage.haskell.org/package/amazonka-autoscaling-plans/docs/Network-AWS-AutoScalingPlans.html)+or [the AWS documentation](https://aws.amazon.com/documentation/) to get started.+++## Contribute++For any problems, comments, or feedback please create an issue [here on GitHub](https://github.com/brendanhay/amazonka/issues).++> _Note:_ this library is an auto-generated Haskell package. Please see `amazonka-gen` for more information.+++## Licence++`amazonka-autoscaling-plans` is released under the [Mozilla Public License Version 2.0](http://www.mozilla.org/MPL/).++Parts of the code are derived from AWS service descriptions, licensed under Apache 2.0.+Source files subject to this contain an additional licensing clause in their header.
+ Setup.hs view
@@ -0,0 +1,2 @@+import           Distribution.Simple+main = defaultMain
+ amazonka-autoscaling-plans.cabal view
@@ -0,0 +1,90 @@+name:                  amazonka-autoscaling-plans+version:               1.6.0+synopsis:              Amazon Auto Scaling Plans SDK.+homepage:              https://github.com/brendanhay/amazonka+bug-reports:           https://github.com/brendanhay/amazonka/issues+license:               MPL-2.0+license-file:          LICENSE+author:                Brendan Hay+maintainer:            Brendan Hay <brendan.g.hay+amazonka@gmail.com>+copyright:             Copyright (c) 2013-2018 Brendan Hay+category:              Network, AWS, Cloud, Distributed Computing+build-type:            Simple+cabal-version:         >= 1.10+extra-source-files:    README.md fixture/*.yaml fixture/*.proto src/.gitkeep+description:+    The types from this library are intended to be used with+    <http://hackage.haskell.org/package/amazonka amazonka>, which provides+    mechanisms for specifying AuthN/AuthZ information, sending requests,+    and receiving responses.+    .+    Lenses are used for constructing and manipulating types,+    due to the depth of nesting of AWS types and transparency regarding+    de/serialisation into more palatable Haskell values.+    The provided lenses should be compatible with any of the major lens libraries+    such as <http://hackage.haskell.org/package/lens lens> or+    <http://hackage.haskell.org/package/lens-family-core lens-family-core>.+    .+    See "Network.AWS.AutoScalingPlans" or <https://aws.amazon.com/documentation/ the AWS documentation>+    to get started.++source-repository head+    type:              git+    location:          git://github.com/brendanhay/amazonka.git+    subdir:            amazonka-autoscaling-plans++library+    default-language:  Haskell2010+    hs-source-dirs:    src gen++    ghc-options:+        -Wall+        -fwarn-incomplete-uni-patterns+        -fwarn-incomplete-record-updates+        -funbox-strict-fields++    exposed-modules:+          Network.AWS.AutoScalingPlans+        , Network.AWS.AutoScalingPlans.CreateScalingPlan+        , Network.AWS.AutoScalingPlans.DeleteScalingPlan+        , Network.AWS.AutoScalingPlans.DescribeScalingPlanResources+        , Network.AWS.AutoScalingPlans.DescribeScalingPlans+        , Network.AWS.AutoScalingPlans.Types+        , Network.AWS.AutoScalingPlans.UpdateScalingPlan+        , Network.AWS.AutoScalingPlans.Waiters++    other-modules:+          Network.AWS.AutoScalingPlans.Types.Product+        , Network.AWS.AutoScalingPlans.Types.Sum++    build-depends:+          amazonka-core == 1.6.0.*+        , base          >= 4.7     && < 5++test-suite amazonka-autoscaling-plans-test+    type:              exitcode-stdio-1.0+    default-language:  Haskell2010+    hs-source-dirs:    test+    main-is:           Main.hs++    ghc-options:       -Wall -threaded++    -- This section is encoded by the template and any modules added by+    -- hand outside these namespaces will not correctly be added to the+    -- distribution package.+    other-modules:+          Test.AWS.AutoScalingPlans+        , Test.AWS.Gen.AutoScalingPlans+        , Test.AWS.AutoScalingPlans.Internal++    build-depends:+          amazonka-core == 1.6.0.*+        , amazonka-test == 1.6.0.*+        , amazonka-autoscaling-plans+        , base+        , bytestring+        , tasty+        , tasty-hunit+        , text+        , time+        , unordered-containers
+ fixture/CreateScalingPlan.yaml view
@@ -0,0 +1,10 @@+---+method: POST+headers:+  Authorization:         AWS4-HMAC-SHA256 Credential=access/20091028/us-east-1/autoscaling/aws4_request, SignedHeaders=content-type;host;x-amz-content-sha256;x-amz-date, Signature=?+  Host:                  autoscaling.us-east-1.amazonaws.com+  Content-Type:          application/x-www-form-urlencoded; charset=utf-8+  X-Amz-Content-SHA256:  abcdef+  X-Amz-Date:            20091028T223200Z+body:+  ''
+ fixture/CreateScalingPlanResponse.proto view
+ fixture/DeleteScalingPlan.yaml view
@@ -0,0 +1,10 @@+---+method: POST+headers:+  Authorization:         AWS4-HMAC-SHA256 Credential=access/20091028/us-east-1/autoscaling/aws4_request, SignedHeaders=content-type;host;x-amz-content-sha256;x-amz-date, Signature=?+  Host:                  autoscaling.us-east-1.amazonaws.com+  Content-Type:          application/x-www-form-urlencoded; charset=utf-8+  X-Amz-Content-SHA256:  abcdef+  X-Amz-Date:            20091028T223200Z+body:+  ''
+ fixture/DeleteScalingPlanResponse.proto view
+ fixture/DescribeScalingPlanResources.yaml view
@@ -0,0 +1,10 @@+---+method: POST+headers:+  Authorization:         AWS4-HMAC-SHA256 Credential=access/20091028/us-east-1/autoscaling/aws4_request, SignedHeaders=content-type;host;x-amz-content-sha256;x-amz-date, Signature=?+  Host:                  autoscaling.us-east-1.amazonaws.com+  Content-Type:          application/x-www-form-urlencoded; charset=utf-8+  X-Amz-Content-SHA256:  abcdef+  X-Amz-Date:            20091028T223200Z+body:+  ''
+ fixture/DescribeScalingPlanResourcesResponse.proto view
+ fixture/DescribeScalingPlans.yaml view
@@ -0,0 +1,10 @@+---+method: POST+headers:+  Authorization:         AWS4-HMAC-SHA256 Credential=access/20091028/us-east-1/autoscaling/aws4_request, SignedHeaders=content-type;host;x-amz-content-sha256;x-amz-date, Signature=?+  Host:                  autoscaling.us-east-1.amazonaws.com+  Content-Type:          application/x-www-form-urlencoded; charset=utf-8+  X-Amz-Content-SHA256:  abcdef+  X-Amz-Date:            20091028T223200Z+body:+  ''
+ fixture/DescribeScalingPlansResponse.proto view
+ fixture/UpdateScalingPlan.yaml view
@@ -0,0 +1,10 @@+---+method: POST+headers:+  Authorization:         AWS4-HMAC-SHA256 Credential=access/20091028/us-east-1/autoscaling/aws4_request, SignedHeaders=content-type;host;x-amz-content-sha256;x-amz-date, Signature=?+  Host:                  autoscaling.us-east-1.amazonaws.com+  Content-Type:          application/x-www-form-urlencoded; charset=utf-8+  X-Amz-Content-SHA256:  abcdef+  X-Amz-Date:            20091028T223200Z+body:+  ''
+ fixture/UpdateScalingPlanResponse.proto view
+ gen/Network/AWS/AutoScalingPlans.hs view
@@ -0,0 +1,212 @@+{-# OPTIONS_GHC -fno-warn-unused-imports    #-}+{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module      : Network.AWS.AutoScalingPlans+-- Copyright   : (c) 2013-2018 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)+--+-- __AWS Auto Scaling__+--+-- Use AWS Auto Scaling to quickly discover all the scalable AWS resources for your application and configure dynamic scaling for your scalable resources.+--+-- To get started, create a scaling plan with a set of instructions used to configure dynamic scaling for the scalable resources in your application. AWS Auto Scaling creates target tracking scaling policies for the scalable resources in your scaling plan. Target tracking scaling policies adjust the capacity of your scalable resource as required to maintain resource utilization at the target value that you specified.+--+module Network.AWS.AutoScalingPlans+    (+    -- * Service Configuration+      autoScalingPlans++    -- * Errors+    -- $errors++    -- ** ValidationException+    , _ValidationException++    -- ** InvalidNextTokenException+    , _InvalidNextTokenException++    -- ** ConcurrentUpdateException+    , _ConcurrentUpdateException++    -- ** InternalServiceException+    , _InternalServiceException++    -- ** ObjectNotFoundException+    , _ObjectNotFoundException++    -- ** LimitExceededException+    , _LimitExceededException++    -- * Waiters+    -- $waiters++    -- * Operations+    -- $operations++    -- ** DescribeScalingPlanResources+    , module Network.AWS.AutoScalingPlans.DescribeScalingPlanResources++    -- ** CreateScalingPlan+    , module Network.AWS.AutoScalingPlans.CreateScalingPlan++    -- ** DeleteScalingPlan+    , module Network.AWS.AutoScalingPlans.DeleteScalingPlan++    -- ** UpdateScalingPlan+    , module Network.AWS.AutoScalingPlans.UpdateScalingPlan++    -- ** DescribeScalingPlans+    , module Network.AWS.AutoScalingPlans.DescribeScalingPlans++    -- * Types++    -- ** MetricStatistic+    , MetricStatistic (..)++    -- ** PolicyType+    , PolicyType (..)++    -- ** ScalableDimension+    , ScalableDimension (..)++    -- ** ScalingMetricType+    , ScalingMetricType (..)++    -- ** ScalingPlanStatusCode+    , ScalingPlanStatusCode (..)++    -- ** ScalingStatusCode+    , ScalingStatusCode (..)++    -- ** ServiceNamespace+    , ServiceNamespace (..)++    -- ** ApplicationSource+    , ApplicationSource+    , applicationSource+    , asTagFilters+    , asCloudFormationStackARN++    -- ** CustomizedScalingMetricSpecification+    , CustomizedScalingMetricSpecification+    , customizedScalingMetricSpecification+    , csmsDimensions+    , csmsUnit+    , csmsMetricName+    , csmsNamespace+    , csmsStatistic++    -- ** MetricDimension+    , MetricDimension+    , metricDimension+    , mdName+    , mdValue++    -- ** PredefinedScalingMetricSpecification+    , PredefinedScalingMetricSpecification+    , predefinedScalingMetricSpecification+    , psmsResourceLabel+    , psmsPredefinedScalingMetricType++    -- ** ScalingInstruction+    , ScalingInstruction+    , scalingInstruction+    , siServiceNamespace+    , siResourceId+    , siScalableDimension+    , siMinCapacity+    , siMaxCapacity+    , siTargetTrackingConfigurations++    -- ** ScalingPlan+    , ScalingPlan+    , scalingPlan+    , spCreationTime+    , spStatusStartTime+    , spStatusMessage+    , spScalingPlanName+    , spScalingPlanVersion+    , spApplicationSource+    , spScalingInstructions+    , spStatusCode++    -- ** ScalingPlanResource+    , ScalingPlanResource+    , scalingPlanResource+    , sprScalingStatusMessage+    , sprScalingPolicies+    , sprScalingPlanName+    , sprScalingPlanVersion+    , sprServiceNamespace+    , sprResourceId+    , sprScalableDimension+    , sprScalingStatusCode++    -- ** ScalingPolicy+    , ScalingPolicy+    , scalingPolicy+    , spTargetTrackingConfiguration+    , spPolicyName+    , spPolicyType++    -- ** TagFilter+    , TagFilter+    , tagFilter+    , tfValues+    , tfKey++    -- ** TargetTrackingConfiguration+    , TargetTrackingConfiguration+    , targetTrackingConfiguration+    , ttcEstimatedInstanceWarmup+    , ttcPredefinedScalingMetricSpecification+    , ttcScaleInCooldown+    , ttcDisableScaleIn+    , ttcCustomizedScalingMetricSpecification+    , ttcScaleOutCooldown+    , ttcTargetValue+    ) where++import Network.AWS.AutoScalingPlans.CreateScalingPlan+import Network.AWS.AutoScalingPlans.DeleteScalingPlan+import Network.AWS.AutoScalingPlans.DescribeScalingPlanResources+import Network.AWS.AutoScalingPlans.DescribeScalingPlans+import Network.AWS.AutoScalingPlans.Types+import Network.AWS.AutoScalingPlans.UpdateScalingPlan+import Network.AWS.AutoScalingPlans.Waiters++{- $errors+Error matchers are designed for use with the functions provided by+<http://hackage.haskell.org/package/lens/docs/Control-Exception-Lens.html Control.Exception.Lens>.+This allows catching (and rethrowing) service specific errors returned+by 'AutoScalingPlans'.+-}++{- $operations+Some AWS operations return results that are incomplete and require subsequent+requests in order to obtain the entire result set. The process of sending+subsequent requests to continue where a previous request left off is called+pagination. For example, the 'ListObjects' operation of Amazon S3 returns up to+1000 objects at a time, and you must send subsequent requests with the+appropriate Marker in order to retrieve the next page of results.++Operations that have an 'AWSPager' instance can transparently perform subsequent+requests, correctly setting Markers and other request facets to iterate through+the entire result set of a truncated API operation. Operations which support+this have an additional note in the documentation.++Many operations have the ability to filter results on the server side. See the+individual operation parameters for details.+-}++{- $waiters+Waiters poll by repeatedly sending a request until some remote success condition+configured by the 'Wait' specification is fulfilled. The 'Wait' specification+determines how many attempts should be made, in addition to delay and retry strategies.+-}
+ gen/Network/AWS/AutoScalingPlans/CreateScalingPlan.hs view
@@ -0,0 +1,163 @@+{-# LANGUAGE DeriveDataTypeable #-}+{-# LANGUAGE DeriveGeneric      #-}+{-# LANGUAGE OverloadedStrings  #-}+{-# LANGUAGE RecordWildCards    #-}+{-# LANGUAGE TypeFamilies       #-}++{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-binds   #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module      : Network.AWS.AutoScalingPlans.CreateScalingPlan+-- Copyright   : (c) 2013-2018 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)+--+-- Creates a scaling plan.+--+--+-- A scaling plan contains a set of instructions used to configure dynamic scaling for the scalable resources in your application. AWS Auto Scaling creates target tracking scaling policies based on the scaling instructions in your scaling plan.+--+module Network.AWS.AutoScalingPlans.CreateScalingPlan+    (+    -- * Creating a Request+      createScalingPlan+    , CreateScalingPlan+    -- * Request Lenses+    , cspScalingPlanName+    , cspApplicationSource+    , cspScalingInstructions++    -- * Destructuring the Response+    , createScalingPlanResponse+    , CreateScalingPlanResponse+    -- * Response Lenses+    , csprsResponseStatus+    , csprsScalingPlanVersion+    ) where++import Network.AWS.AutoScalingPlans.Types+import Network.AWS.AutoScalingPlans.Types.Product+import Network.AWS.Lens+import Network.AWS.Prelude+import Network.AWS.Request+import Network.AWS.Response++-- | /See:/ 'createScalingPlan' smart constructor.+data CreateScalingPlan = CreateScalingPlan'+  { _cspScalingPlanName     :: !Text+  , _cspApplicationSource   :: !ApplicationSource+  , _cspScalingInstructions :: ![ScalingInstruction]+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'CreateScalingPlan' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'cspScalingPlanName' - The name of the scaling plan. Names cannot contain vertical bars, colons, or forward slashes.+--+-- * 'cspApplicationSource' - A CloudFormation stack or set of tags. You can create one scaling plan per application source.+--+-- * 'cspScalingInstructions' - The scaling instructions.+createScalingPlan+    :: Text -- ^ 'cspScalingPlanName'+    -> ApplicationSource -- ^ 'cspApplicationSource'+    -> CreateScalingPlan+createScalingPlan pScalingPlanName_ pApplicationSource_ =+  CreateScalingPlan'+    { _cspScalingPlanName = pScalingPlanName_+    , _cspApplicationSource = pApplicationSource_+    , _cspScalingInstructions = mempty+    }+++-- | The name of the scaling plan. Names cannot contain vertical bars, colons, or forward slashes.+cspScalingPlanName :: Lens' CreateScalingPlan Text+cspScalingPlanName = lens _cspScalingPlanName (\ s a -> s{_cspScalingPlanName = a})++-- | A CloudFormation stack or set of tags. You can create one scaling plan per application source.+cspApplicationSource :: Lens' CreateScalingPlan ApplicationSource+cspApplicationSource = lens _cspApplicationSource (\ s a -> s{_cspApplicationSource = a})++-- | The scaling instructions.+cspScalingInstructions :: Lens' CreateScalingPlan [ScalingInstruction]+cspScalingInstructions = lens _cspScalingInstructions (\ s a -> s{_cspScalingInstructions = a}) . _Coerce++instance AWSRequest CreateScalingPlan where+        type Rs CreateScalingPlan = CreateScalingPlanResponse+        request = postJSON autoScalingPlans+        response+          = receiveJSON+              (\ s h x ->+                 CreateScalingPlanResponse' <$>+                   (pure (fromEnum s)) <*> (x .:> "ScalingPlanVersion"))++instance Hashable CreateScalingPlan where++instance NFData CreateScalingPlan where++instance ToHeaders CreateScalingPlan where+        toHeaders+          = const+              (mconcat+                 ["X-Amz-Target" =#+                    ("AnyScaleScalingPlannerFrontendService.CreateScalingPlan"+                       :: ByteString),+                  "Content-Type" =#+                    ("application/x-amz-json-1.1" :: ByteString)])++instance ToJSON CreateScalingPlan where+        toJSON CreateScalingPlan'{..}+          = object+              (catMaybes+                 [Just ("ScalingPlanName" .= _cspScalingPlanName),+                  Just ("ApplicationSource" .= _cspApplicationSource),+                  Just+                    ("ScalingInstructions" .= _cspScalingInstructions)])++instance ToPath CreateScalingPlan where+        toPath = const "/"++instance ToQuery CreateScalingPlan where+        toQuery = const mempty++-- | /See:/ 'createScalingPlanResponse' smart constructor.+data CreateScalingPlanResponse = CreateScalingPlanResponse'+  { _csprsResponseStatus     :: !Int+  , _csprsScalingPlanVersion :: !Integer+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'CreateScalingPlanResponse' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'csprsResponseStatus' - -- | The response status code.+--+-- * 'csprsScalingPlanVersion' - The version of the scaling plan. This value is always 1.+createScalingPlanResponse+    :: Int -- ^ 'csprsResponseStatus'+    -> Integer -- ^ 'csprsScalingPlanVersion'+    -> CreateScalingPlanResponse+createScalingPlanResponse pResponseStatus_ pScalingPlanVersion_ =+  CreateScalingPlanResponse'+    { _csprsResponseStatus = pResponseStatus_+    , _csprsScalingPlanVersion = pScalingPlanVersion_+    }+++-- | -- | The response status code.+csprsResponseStatus :: Lens' CreateScalingPlanResponse Int+csprsResponseStatus = lens _csprsResponseStatus (\ s a -> s{_csprsResponseStatus = a})++-- | The version of the scaling plan. This value is always 1.+csprsScalingPlanVersion :: Lens' CreateScalingPlanResponse Integer+csprsScalingPlanVersion = lens _csprsScalingPlanVersion (\ s a -> s{_csprsScalingPlanVersion = a})++instance NFData CreateScalingPlanResponse where
+ gen/Network/AWS/AutoScalingPlans/DeleteScalingPlan.hs view
@@ -0,0 +1,138 @@+{-# LANGUAGE DeriveDataTypeable #-}+{-# LANGUAGE DeriveGeneric      #-}+{-# LANGUAGE OverloadedStrings  #-}+{-# LANGUAGE RecordWildCards    #-}+{-# LANGUAGE TypeFamilies       #-}++{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-binds   #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module      : Network.AWS.AutoScalingPlans.DeleteScalingPlan+-- Copyright   : (c) 2013-2018 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)+--+-- Deletes the specified scaling plan.+--+--+module Network.AWS.AutoScalingPlans.DeleteScalingPlan+    (+    -- * Creating a Request+      deleteScalingPlan+    , DeleteScalingPlan+    -- * Request Lenses+    , dspScalingPlanName+    , dspScalingPlanVersion++    -- * Destructuring the Response+    , deleteScalingPlanResponse+    , DeleteScalingPlanResponse+    -- * Response Lenses+    , dsprsResponseStatus+    ) where++import Network.AWS.AutoScalingPlans.Types+import Network.AWS.AutoScalingPlans.Types.Product+import Network.AWS.Lens+import Network.AWS.Prelude+import Network.AWS.Request+import Network.AWS.Response++-- | /See:/ 'deleteScalingPlan' smart constructor.+data DeleteScalingPlan = DeleteScalingPlan'+  { _dspScalingPlanName    :: !Text+  , _dspScalingPlanVersion :: !Integer+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'DeleteScalingPlan' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'dspScalingPlanName' - The name of the scaling plan.+--+-- * 'dspScalingPlanVersion' - The version of the scaling plan.+deleteScalingPlan+    :: Text -- ^ 'dspScalingPlanName'+    -> Integer -- ^ 'dspScalingPlanVersion'+    -> DeleteScalingPlan+deleteScalingPlan pScalingPlanName_ pScalingPlanVersion_ =+  DeleteScalingPlan'+    { _dspScalingPlanName = pScalingPlanName_+    , _dspScalingPlanVersion = pScalingPlanVersion_+    }+++-- | The name of the scaling plan.+dspScalingPlanName :: Lens' DeleteScalingPlan Text+dspScalingPlanName = lens _dspScalingPlanName (\ s a -> s{_dspScalingPlanName = a})++-- | The version of the scaling plan.+dspScalingPlanVersion :: Lens' DeleteScalingPlan Integer+dspScalingPlanVersion = lens _dspScalingPlanVersion (\ s a -> s{_dspScalingPlanVersion = a})++instance AWSRequest DeleteScalingPlan where+        type Rs DeleteScalingPlan = DeleteScalingPlanResponse+        request = postJSON autoScalingPlans+        response+          = receiveEmpty+              (\ s h x ->+                 DeleteScalingPlanResponse' <$> (pure (fromEnum s)))++instance Hashable DeleteScalingPlan where++instance NFData DeleteScalingPlan where++instance ToHeaders DeleteScalingPlan where+        toHeaders+          = const+              (mconcat+                 ["X-Amz-Target" =#+                    ("AnyScaleScalingPlannerFrontendService.DeleteScalingPlan"+                       :: ByteString),+                  "Content-Type" =#+                    ("application/x-amz-json-1.1" :: ByteString)])++instance ToJSON DeleteScalingPlan where+        toJSON DeleteScalingPlan'{..}+          = object+              (catMaybes+                 [Just ("ScalingPlanName" .= _dspScalingPlanName),+                  Just+                    ("ScalingPlanVersion" .= _dspScalingPlanVersion)])++instance ToPath DeleteScalingPlan where+        toPath = const "/"++instance ToQuery DeleteScalingPlan where+        toQuery = const mempty++-- | /See:/ 'deleteScalingPlanResponse' smart constructor.+newtype DeleteScalingPlanResponse = DeleteScalingPlanResponse'+  { _dsprsResponseStatus :: Int+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'DeleteScalingPlanResponse' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'dsprsResponseStatus' - -- | The response status code.+deleteScalingPlanResponse+    :: Int -- ^ 'dsprsResponseStatus'+    -> DeleteScalingPlanResponse+deleteScalingPlanResponse pResponseStatus_ =+  DeleteScalingPlanResponse' {_dsprsResponseStatus = pResponseStatus_}+++-- | -- | The response status code.+dsprsResponseStatus :: Lens' DeleteScalingPlanResponse Int+dsprsResponseStatus = lens _dsprsResponseStatus (\ s a -> s{_dsprsResponseStatus = a})++instance NFData DeleteScalingPlanResponse where
+ gen/Network/AWS/AutoScalingPlans/DescribeScalingPlanResources.hs view
@@ -0,0 +1,184 @@+{-# LANGUAGE DeriveDataTypeable #-}+{-# LANGUAGE DeriveGeneric      #-}+{-# LANGUAGE OverloadedStrings  #-}+{-# LANGUAGE RecordWildCards    #-}+{-# LANGUAGE TypeFamilies       #-}++{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-binds   #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module      : Network.AWS.AutoScalingPlans.DescribeScalingPlanResources+-- Copyright   : (c) 2013-2018 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)+--+-- Describes the scalable resources in the specified scaling plan.+--+--+module Network.AWS.AutoScalingPlans.DescribeScalingPlanResources+    (+    -- * Creating a Request+      describeScalingPlanResources+    , DescribeScalingPlanResources+    -- * Request Lenses+    , dsprNextToken+    , dsprMaxResults+    , dsprScalingPlanName+    , dsprScalingPlanVersion++    -- * Destructuring the Response+    , describeScalingPlanResourcesResponse+    , DescribeScalingPlanResourcesResponse+    -- * Response Lenses+    , dsprrsNextToken+    , dsprrsScalingPlanResources+    , dsprrsResponseStatus+    ) where++import Network.AWS.AutoScalingPlans.Types+import Network.AWS.AutoScalingPlans.Types.Product+import Network.AWS.Lens+import Network.AWS.Prelude+import Network.AWS.Request+import Network.AWS.Response++-- | /See:/ 'describeScalingPlanResources' smart constructor.+data DescribeScalingPlanResources = DescribeScalingPlanResources'+  { _dsprNextToken          :: !(Maybe Text)+  , _dsprMaxResults         :: !(Maybe Int)+  , _dsprScalingPlanName    :: !Text+  , _dsprScalingPlanVersion :: !Integer+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'DescribeScalingPlanResources' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'dsprNextToken' - The token for the next set of results.+--+-- * 'dsprMaxResults' - The maximum number of scalable resources to return. This value can be between 1 and 50. The default value is 50.+--+-- * 'dsprScalingPlanName' - The name of the scaling plan.+--+-- * 'dsprScalingPlanVersion' - The version of the scaling plan.+describeScalingPlanResources+    :: Text -- ^ 'dsprScalingPlanName'+    -> Integer -- ^ 'dsprScalingPlanVersion'+    -> DescribeScalingPlanResources+describeScalingPlanResources pScalingPlanName_ pScalingPlanVersion_ =+  DescribeScalingPlanResources'+    { _dsprNextToken = Nothing+    , _dsprMaxResults = Nothing+    , _dsprScalingPlanName = pScalingPlanName_+    , _dsprScalingPlanVersion = pScalingPlanVersion_+    }+++-- | The token for the next set of results.+dsprNextToken :: Lens' DescribeScalingPlanResources (Maybe Text)+dsprNextToken = lens _dsprNextToken (\ s a -> s{_dsprNextToken = a})++-- | The maximum number of scalable resources to return. This value can be between 1 and 50. The default value is 50.+dsprMaxResults :: Lens' DescribeScalingPlanResources (Maybe Int)+dsprMaxResults = lens _dsprMaxResults (\ s a -> s{_dsprMaxResults = a})++-- | The name of the scaling plan.+dsprScalingPlanName :: Lens' DescribeScalingPlanResources Text+dsprScalingPlanName = lens _dsprScalingPlanName (\ s a -> s{_dsprScalingPlanName = a})++-- | The version of the scaling plan.+dsprScalingPlanVersion :: Lens' DescribeScalingPlanResources Integer+dsprScalingPlanVersion = lens _dsprScalingPlanVersion (\ s a -> s{_dsprScalingPlanVersion = a})++instance AWSRequest DescribeScalingPlanResources+         where+        type Rs DescribeScalingPlanResources =+             DescribeScalingPlanResourcesResponse+        request = postJSON autoScalingPlans+        response+          = receiveJSON+              (\ s h x ->+                 DescribeScalingPlanResourcesResponse' <$>+                   (x .?> "NextToken") <*>+                     (x .?> "ScalingPlanResources" .!@ mempty)+                     <*> (pure (fromEnum s)))++instance Hashable DescribeScalingPlanResources where++instance NFData DescribeScalingPlanResources where++instance ToHeaders DescribeScalingPlanResources where+        toHeaders+          = const+              (mconcat+                 ["X-Amz-Target" =#+                    ("AnyScaleScalingPlannerFrontendService.DescribeScalingPlanResources"+                       :: ByteString),+                  "Content-Type" =#+                    ("application/x-amz-json-1.1" :: ByteString)])++instance ToJSON DescribeScalingPlanResources where+        toJSON DescribeScalingPlanResources'{..}+          = object+              (catMaybes+                 [("NextToken" .=) <$> _dsprNextToken,+                  ("MaxResults" .=) <$> _dsprMaxResults,+                  Just ("ScalingPlanName" .= _dsprScalingPlanName),+                  Just+                    ("ScalingPlanVersion" .= _dsprScalingPlanVersion)])++instance ToPath DescribeScalingPlanResources where+        toPath = const "/"++instance ToQuery DescribeScalingPlanResources where+        toQuery = const mempty++-- | /See:/ 'describeScalingPlanResourcesResponse' smart constructor.+data DescribeScalingPlanResourcesResponse = DescribeScalingPlanResourcesResponse'+  { _dsprrsNextToken            :: !(Maybe Text)+  , _dsprrsScalingPlanResources :: !(Maybe [ScalingPlanResource])+  , _dsprrsResponseStatus       :: !Int+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'DescribeScalingPlanResourcesResponse' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'dsprrsNextToken' - The token required to get the next set of results. This value is @null@ if there are no more results to return.+--+-- * 'dsprrsScalingPlanResources' - Information about the scalable resources.+--+-- * 'dsprrsResponseStatus' - -- | The response status code.+describeScalingPlanResourcesResponse+    :: Int -- ^ 'dsprrsResponseStatus'+    -> DescribeScalingPlanResourcesResponse+describeScalingPlanResourcesResponse pResponseStatus_ =+  DescribeScalingPlanResourcesResponse'+    { _dsprrsNextToken = Nothing+    , _dsprrsScalingPlanResources = Nothing+    , _dsprrsResponseStatus = pResponseStatus_+    }+++-- | The token required to get the next set of results. This value is @null@ if there are no more results to return.+dsprrsNextToken :: Lens' DescribeScalingPlanResourcesResponse (Maybe Text)+dsprrsNextToken = lens _dsprrsNextToken (\ s a -> s{_dsprrsNextToken = a})++-- | Information about the scalable resources.+dsprrsScalingPlanResources :: Lens' DescribeScalingPlanResourcesResponse [ScalingPlanResource]+dsprrsScalingPlanResources = lens _dsprrsScalingPlanResources (\ s a -> s{_dsprrsScalingPlanResources = a}) . _Default . _Coerce++-- | -- | The response status code.+dsprrsResponseStatus :: Lens' DescribeScalingPlanResourcesResponse Int+dsprrsResponseStatus = lens _dsprrsResponseStatus (\ s a -> s{_dsprrsResponseStatus = a})++instance NFData DescribeScalingPlanResourcesResponse+         where
+ gen/Network/AWS/AutoScalingPlans/DescribeScalingPlans.hs view
@@ -0,0 +1,189 @@+{-# LANGUAGE DeriveDataTypeable #-}+{-# LANGUAGE DeriveGeneric      #-}+{-# LANGUAGE OverloadedStrings  #-}+{-# LANGUAGE RecordWildCards    #-}+{-# LANGUAGE TypeFamilies       #-}++{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-binds   #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module      : Network.AWS.AutoScalingPlans.DescribeScalingPlans+-- Copyright   : (c) 2013-2018 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)+--+-- Describes the specified scaling plans or all of your scaling plans.+--+--+module Network.AWS.AutoScalingPlans.DescribeScalingPlans+    (+    -- * Creating a Request+      describeScalingPlans+    , DescribeScalingPlans+    -- * Request Lenses+    , dScalingPlanVersion+    , dScalingPlanNames+    , dNextToken+    , dApplicationSources+    , dMaxResults++    -- * Destructuring the Response+    , describeScalingPlansResponse+    , DescribeScalingPlansResponse+    -- * Response Lenses+    , drsScalingPlans+    , drsNextToken+    , drsResponseStatus+    ) where++import Network.AWS.AutoScalingPlans.Types+import Network.AWS.AutoScalingPlans.Types.Product+import Network.AWS.Lens+import Network.AWS.Prelude+import Network.AWS.Request+import Network.AWS.Response++-- | /See:/ 'describeScalingPlans' smart constructor.+data DescribeScalingPlans = DescribeScalingPlans'+  { _dScalingPlanVersion :: !(Maybe Integer)+  , _dScalingPlanNames   :: !(Maybe [Text])+  , _dNextToken          :: !(Maybe Text)+  , _dApplicationSources :: !(Maybe [ApplicationSource])+  , _dMaxResults         :: !(Maybe Int)+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'DescribeScalingPlans' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'dScalingPlanVersion' - The version of the scaling plan. If you specify a scaling plan version, you must also specify a scaling plan name.+--+-- * 'dScalingPlanNames' - The names of the scaling plans (up to 10). If you specify application sources, you cannot specify scaling plan names.+--+-- * 'dNextToken' - The token for the next set of results.+--+-- * 'dApplicationSources' - The sources for the applications (up to 10). If you specify scaling plan names, you cannot specify application sources.+--+-- * 'dMaxResults' - The maximum number of scalable resources to return. This value can be between 1 and 50. The default value is 50.+describeScalingPlans+    :: DescribeScalingPlans+describeScalingPlans =+  DescribeScalingPlans'+    { _dScalingPlanVersion = Nothing+    , _dScalingPlanNames = Nothing+    , _dNextToken = Nothing+    , _dApplicationSources = Nothing+    , _dMaxResults = Nothing+    }+++-- | The version of the scaling plan. If you specify a scaling plan version, you must also specify a scaling plan name.+dScalingPlanVersion :: Lens' DescribeScalingPlans (Maybe Integer)+dScalingPlanVersion = lens _dScalingPlanVersion (\ s a -> s{_dScalingPlanVersion = a})++-- | The names of the scaling plans (up to 10). If you specify application sources, you cannot specify scaling plan names.+dScalingPlanNames :: Lens' DescribeScalingPlans [Text]+dScalingPlanNames = lens _dScalingPlanNames (\ s a -> s{_dScalingPlanNames = a}) . _Default . _Coerce++-- | The token for the next set of results.+dNextToken :: Lens' DescribeScalingPlans (Maybe Text)+dNextToken = lens _dNextToken (\ s a -> s{_dNextToken = a})++-- | The sources for the applications (up to 10). If you specify scaling plan names, you cannot specify application sources.+dApplicationSources :: Lens' DescribeScalingPlans [ApplicationSource]+dApplicationSources = lens _dApplicationSources (\ s a -> s{_dApplicationSources = a}) . _Default . _Coerce++-- | The maximum number of scalable resources to return. This value can be between 1 and 50. The default value is 50.+dMaxResults :: Lens' DescribeScalingPlans (Maybe Int)+dMaxResults = lens _dMaxResults (\ s a -> s{_dMaxResults = a})++instance AWSRequest DescribeScalingPlans where+        type Rs DescribeScalingPlans =+             DescribeScalingPlansResponse+        request = postJSON autoScalingPlans+        response+          = receiveJSON+              (\ s h x ->+                 DescribeScalingPlansResponse' <$>+                   (x .?> "ScalingPlans" .!@ mempty) <*>+                     (x .?> "NextToken")+                     <*> (pure (fromEnum s)))++instance Hashable DescribeScalingPlans where++instance NFData DescribeScalingPlans where++instance ToHeaders DescribeScalingPlans where+        toHeaders+          = const+              (mconcat+                 ["X-Amz-Target" =#+                    ("AnyScaleScalingPlannerFrontendService.DescribeScalingPlans"+                       :: ByteString),+                  "Content-Type" =#+                    ("application/x-amz-json-1.1" :: ByteString)])++instance ToJSON DescribeScalingPlans where+        toJSON DescribeScalingPlans'{..}+          = object+              (catMaybes+                 [("ScalingPlanVersion" .=) <$> _dScalingPlanVersion,+                  ("ScalingPlanNames" .=) <$> _dScalingPlanNames,+                  ("NextToken" .=) <$> _dNextToken,+                  ("ApplicationSources" .=) <$> _dApplicationSources,+                  ("MaxResults" .=) <$> _dMaxResults])++instance ToPath DescribeScalingPlans where+        toPath = const "/"++instance ToQuery DescribeScalingPlans where+        toQuery = const mempty++-- | /See:/ 'describeScalingPlansResponse' smart constructor.+data DescribeScalingPlansResponse = DescribeScalingPlansResponse'+  { _drsScalingPlans   :: !(Maybe [ScalingPlan])+  , _drsNextToken      :: !(Maybe Text)+  , _drsResponseStatus :: !Int+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'DescribeScalingPlansResponse' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'drsScalingPlans' - Information about the scaling plans.+--+-- * 'drsNextToken' - The token required to get the next set of results. This value is @null@ if there are no more results to return.+--+-- * 'drsResponseStatus' - -- | The response status code.+describeScalingPlansResponse+    :: Int -- ^ 'drsResponseStatus'+    -> DescribeScalingPlansResponse+describeScalingPlansResponse pResponseStatus_ =+  DescribeScalingPlansResponse'+    { _drsScalingPlans = Nothing+    , _drsNextToken = Nothing+    , _drsResponseStatus = pResponseStatus_+    }+++-- | Information about the scaling plans.+drsScalingPlans :: Lens' DescribeScalingPlansResponse [ScalingPlan]+drsScalingPlans = lens _drsScalingPlans (\ s a -> s{_drsScalingPlans = a}) . _Default . _Coerce++-- | The token required to get the next set of results. This value is @null@ if there are no more results to return.+drsNextToken :: Lens' DescribeScalingPlansResponse (Maybe Text)+drsNextToken = lens _drsNextToken (\ s a -> s{_drsNextToken = a})++-- | -- | The response status code.+drsResponseStatus :: Lens' DescribeScalingPlansResponse Int+drsResponseStatus = lens _drsResponseStatus (\ s a -> s{_drsResponseStatus = a})++instance NFData DescribeScalingPlansResponse where
+ gen/Network/AWS/AutoScalingPlans/Types.hs view
@@ -0,0 +1,223 @@+{-# LANGUAGE OverloadedStrings #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module      : Network.AWS.AutoScalingPlans.Types+-- Copyright   : (c) 2013-2018 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 Network.AWS.AutoScalingPlans.Types+    (+    -- * Service Configuration+      autoScalingPlans++    -- * Errors+    , _ValidationException+    , _InvalidNextTokenException+    , _ConcurrentUpdateException+    , _InternalServiceException+    , _ObjectNotFoundException+    , _LimitExceededException++    -- * MetricStatistic+    , MetricStatistic (..)++    -- * PolicyType+    , PolicyType (..)++    -- * ScalableDimension+    , ScalableDimension (..)++    -- * ScalingMetricType+    , ScalingMetricType (..)++    -- * ScalingPlanStatusCode+    , ScalingPlanStatusCode (..)++    -- * ScalingStatusCode+    , ScalingStatusCode (..)++    -- * ServiceNamespace+    , ServiceNamespace (..)++    -- * ApplicationSource+    , ApplicationSource+    , applicationSource+    , asTagFilters+    , asCloudFormationStackARN++    -- * CustomizedScalingMetricSpecification+    , CustomizedScalingMetricSpecification+    , customizedScalingMetricSpecification+    , csmsDimensions+    , csmsUnit+    , csmsMetricName+    , csmsNamespace+    , csmsStatistic++    -- * MetricDimension+    , MetricDimension+    , metricDimension+    , mdName+    , mdValue++    -- * PredefinedScalingMetricSpecification+    , PredefinedScalingMetricSpecification+    , predefinedScalingMetricSpecification+    , psmsResourceLabel+    , psmsPredefinedScalingMetricType++    -- * ScalingInstruction+    , ScalingInstruction+    , scalingInstruction+    , siServiceNamespace+    , siResourceId+    , siScalableDimension+    , siMinCapacity+    , siMaxCapacity+    , siTargetTrackingConfigurations++    -- * ScalingPlan+    , ScalingPlan+    , scalingPlan+    , spCreationTime+    , spStatusStartTime+    , spStatusMessage+    , spScalingPlanName+    , spScalingPlanVersion+    , spApplicationSource+    , spScalingInstructions+    , spStatusCode++    -- * ScalingPlanResource+    , ScalingPlanResource+    , scalingPlanResource+    , sprScalingStatusMessage+    , sprScalingPolicies+    , sprScalingPlanName+    , sprScalingPlanVersion+    , sprServiceNamespace+    , sprResourceId+    , sprScalableDimension+    , sprScalingStatusCode++    -- * ScalingPolicy+    , ScalingPolicy+    , scalingPolicy+    , spTargetTrackingConfiguration+    , spPolicyName+    , spPolicyType++    -- * TagFilter+    , TagFilter+    , tagFilter+    , tfValues+    , tfKey++    -- * TargetTrackingConfiguration+    , TargetTrackingConfiguration+    , targetTrackingConfiguration+    , ttcEstimatedInstanceWarmup+    , ttcPredefinedScalingMetricSpecification+    , ttcScaleInCooldown+    , ttcDisableScaleIn+    , ttcCustomizedScalingMetricSpecification+    , ttcScaleOutCooldown+    , ttcTargetValue+    ) where++import Network.AWS.AutoScalingPlans.Types.Product+import Network.AWS.AutoScalingPlans.Types.Sum+import Network.AWS.Lens+import Network.AWS.Prelude+import Network.AWS.Sign.V4++-- | API version @2018-01-06@ of the Amazon Auto Scaling Plans SDK configuration.+autoScalingPlans :: Service+autoScalingPlans =+  Service+    { _svcAbbrev = "AutoScalingPlans"+    , _svcSigner = v4+    , _svcPrefix = "autoscaling"+    , _svcVersion = "2018-01-06"+    , _svcEndpoint = defaultEndpoint autoScalingPlans+    , _svcTimeout = Just 70+    , _svcCheck = statusSuccess+    , _svcError = parseJSONError "AutoScalingPlans"+    , _svcRetry = retry+    }+  where+    retry =+      Exponential+        { _retryBase = 5.0e-2+        , _retryGrowth = 2+        , _retryAttempts = 5+        , _retryCheck = check+        }+    check e+      | has (hasCode "ThrottledException" . hasStatus 400) e =+        Just "throttled_exception"+      | has (hasStatus 429) e = Just "too_many_requests"+      | has (hasCode "ThrottlingException" . hasStatus 400) e =+        Just "throttling_exception"+      | has (hasCode "Throttling" . hasStatus 400) e = Just "throttling"+      | has (hasStatus 504) e = Just "gateway_timeout"+      | has (hasCode "RequestThrottledException" . hasStatus 400) e =+        Just "request_throttled_exception"+      | has (hasStatus 502) e = Just "bad_gateway"+      | has (hasStatus 503) e = Just "service_unavailable"+      | has (hasStatus 500) e = Just "general_server_error"+      | has (hasStatus 509) e = Just "limit_exceeded"+      | otherwise = Nothing+++-- | An exception was thrown for a validation issue. Review the parameters provided.+--+--+_ValidationException :: AsError a => Getting (First ServiceError) a ServiceError+_ValidationException = _MatchServiceError autoScalingPlans "ValidationException"+++-- | The token provided is not valid.+--+--+_InvalidNextTokenException :: AsError a => Getting (First ServiceError) a ServiceError+_InvalidNextTokenException =+  _MatchServiceError autoScalingPlans "InvalidNextTokenException"+++-- | Concurrent updates caused an exception, for example, if you request an update to a scaling plan that already has a pending update.+--+--+_ConcurrentUpdateException :: AsError a => Getting (First ServiceError) a ServiceError+_ConcurrentUpdateException =+  _MatchServiceError autoScalingPlans "ConcurrentUpdateException"+++-- | The service encountered an internal error.+--+--+_InternalServiceException :: AsError a => Getting (First ServiceError) a ServiceError+_InternalServiceException =+  _MatchServiceError autoScalingPlans "InternalServiceException"+++-- | The specified object could not be found.+--+--+_ObjectNotFoundException :: AsError a => Getting (First ServiceError) a ServiceError+_ObjectNotFoundException =+  _MatchServiceError autoScalingPlans "ObjectNotFoundException"+++-- | Your account exceeded a limit. This exception is thrown when a per-account resource limit is exceeded.+--+--+_LimitExceededException :: AsError a => Getting (First ServiceError) a ServiceError+_LimitExceededException =+  _MatchServiceError autoScalingPlans "LimitExceededException"+
+ gen/Network/AWS/AutoScalingPlans/Types/Product.hs view
@@ -0,0 +1,808 @@+{-# LANGUAGE DeriveDataTypeable #-}+{-# LANGUAGE DeriveGeneric      #-}+{-# LANGUAGE OverloadedStrings  #-}+{-# LANGUAGE RecordWildCards    #-}++{-# OPTIONS_GHC -fno-warn-unused-imports #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module      : Network.AWS.AutoScalingPlans.Types.Product+-- Copyright   : (c) 2013-2018 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 Network.AWS.AutoScalingPlans.Types.Product where++import Network.AWS.AutoScalingPlans.Types.Sum+import Network.AWS.Lens+import Network.AWS.Prelude++-- | Represents an application source.+--+--+--+-- /See:/ 'applicationSource' smart constructor.+data ApplicationSource = ApplicationSource'+  { _asTagFilters             :: !(Maybe [TagFilter])+  , _asCloudFormationStackARN :: !(Maybe Text)+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'ApplicationSource' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'asTagFilters' - A set of tags (up to 50).+--+-- * 'asCloudFormationStackARN' - The Amazon Resource Name (ARN) of a CloudFormation stack.+applicationSource+    :: ApplicationSource+applicationSource =+  ApplicationSource'+    {_asTagFilters = Nothing, _asCloudFormationStackARN = Nothing}+++-- | A set of tags (up to 50).+asTagFilters :: Lens' ApplicationSource [TagFilter]+asTagFilters = lens _asTagFilters (\ s a -> s{_asTagFilters = a}) . _Default . _Coerce++-- | The Amazon Resource Name (ARN) of a CloudFormation stack.+asCloudFormationStackARN :: Lens' ApplicationSource (Maybe Text)+asCloudFormationStackARN = lens _asCloudFormationStackARN (\ s a -> s{_asCloudFormationStackARN = a})++instance FromJSON ApplicationSource where+        parseJSON+          = withObject "ApplicationSource"+              (\ x ->+                 ApplicationSource' <$>+                   (x .:? "TagFilters" .!= mempty) <*>+                     (x .:? "CloudFormationStackARN"))++instance Hashable ApplicationSource where++instance NFData ApplicationSource where++instance ToJSON ApplicationSource where+        toJSON ApplicationSource'{..}+          = object+              (catMaybes+                 [("TagFilters" .=) <$> _asTagFilters,+                  ("CloudFormationStackARN" .=) <$>+                    _asCloudFormationStackARN])++-- | Represents a customized metric for a target tracking policy.+--+--+--+-- /See:/ 'customizedScalingMetricSpecification' smart constructor.+data CustomizedScalingMetricSpecification = CustomizedScalingMetricSpecification'+  { _csmsDimensions :: !(Maybe [MetricDimension])+  , _csmsUnit       :: !(Maybe Text)+  , _csmsMetricName :: !Text+  , _csmsNamespace  :: !Text+  , _csmsStatistic  :: !MetricStatistic+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'CustomizedScalingMetricSpecification' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'csmsDimensions' - The dimensions of the metric.+--+-- * 'csmsUnit' - The unit of the metric.+--+-- * 'csmsMetricName' - The name of the metric.+--+-- * 'csmsNamespace' - The namespace of the metric.+--+-- * 'csmsStatistic' - The statistic of the metric.+customizedScalingMetricSpecification+    :: Text -- ^ 'csmsMetricName'+    -> Text -- ^ 'csmsNamespace'+    -> MetricStatistic -- ^ 'csmsStatistic'+    -> CustomizedScalingMetricSpecification+customizedScalingMetricSpecification pMetricName_ pNamespace_ pStatistic_ =+  CustomizedScalingMetricSpecification'+    { _csmsDimensions = Nothing+    , _csmsUnit = Nothing+    , _csmsMetricName = pMetricName_+    , _csmsNamespace = pNamespace_+    , _csmsStatistic = pStatistic_+    }+++-- | The dimensions of the metric.+csmsDimensions :: Lens' CustomizedScalingMetricSpecification [MetricDimension]+csmsDimensions = lens _csmsDimensions (\ s a -> s{_csmsDimensions = a}) . _Default . _Coerce++-- | The unit of the metric.+csmsUnit :: Lens' CustomizedScalingMetricSpecification (Maybe Text)+csmsUnit = lens _csmsUnit (\ s a -> s{_csmsUnit = a})++-- | The name of the metric.+csmsMetricName :: Lens' CustomizedScalingMetricSpecification Text+csmsMetricName = lens _csmsMetricName (\ s a -> s{_csmsMetricName = a})++-- | The namespace of the metric.+csmsNamespace :: Lens' CustomizedScalingMetricSpecification Text+csmsNamespace = lens _csmsNamespace (\ s a -> s{_csmsNamespace = a})++-- | The statistic of the metric.+csmsStatistic :: Lens' CustomizedScalingMetricSpecification MetricStatistic+csmsStatistic = lens _csmsStatistic (\ s a -> s{_csmsStatistic = a})++instance FromJSON+           CustomizedScalingMetricSpecification+         where+        parseJSON+          = withObject "CustomizedScalingMetricSpecification"+              (\ x ->+                 CustomizedScalingMetricSpecification' <$>+                   (x .:? "Dimensions" .!= mempty) <*> (x .:? "Unit")+                     <*> (x .: "MetricName")+                     <*> (x .: "Namespace")+                     <*> (x .: "Statistic"))++instance Hashable+           CustomizedScalingMetricSpecification+         where++instance NFData CustomizedScalingMetricSpecification+         where++instance ToJSON CustomizedScalingMetricSpecification+         where+        toJSON CustomizedScalingMetricSpecification'{..}+          = object+              (catMaybes+                 [("Dimensions" .=) <$> _csmsDimensions,+                  ("Unit" .=) <$> _csmsUnit,+                  Just ("MetricName" .= _csmsMetricName),+                  Just ("Namespace" .= _csmsNamespace),+                  Just ("Statistic" .= _csmsStatistic)])++-- | Represents a dimension for a customized metric.+--+--+--+-- /See:/ 'metricDimension' smart constructor.+data MetricDimension = MetricDimension'+  { _mdName  :: !Text+  , _mdValue :: !Text+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'MetricDimension' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'mdName' - The name of the dimension.+--+-- * 'mdValue' - The value of the dimension.+metricDimension+    :: Text -- ^ 'mdName'+    -> Text -- ^ 'mdValue'+    -> MetricDimension+metricDimension pName_ pValue_ =+  MetricDimension' {_mdName = pName_, _mdValue = pValue_}+++-- | The name of the dimension.+mdName :: Lens' MetricDimension Text+mdName = lens _mdName (\ s a -> s{_mdName = a})++-- | The value of the dimension.+mdValue :: Lens' MetricDimension Text+mdValue = lens _mdValue (\ s a -> s{_mdValue = a})++instance FromJSON MetricDimension where+        parseJSON+          = withObject "MetricDimension"+              (\ x ->+                 MetricDimension' <$>+                   (x .: "Name") <*> (x .: "Value"))++instance Hashable MetricDimension where++instance NFData MetricDimension where++instance ToJSON MetricDimension where+        toJSON MetricDimension'{..}+          = object+              (catMaybes+                 [Just ("Name" .= _mdName),+                  Just ("Value" .= _mdValue)])++-- | Represents a predefined metric for a target tracking policy.+--+--+--+-- /See:/ 'predefinedScalingMetricSpecification' smart constructor.+data PredefinedScalingMetricSpecification = PredefinedScalingMetricSpecification'+  { _psmsResourceLabel               :: !(Maybe Text)+  , _psmsPredefinedScalingMetricType :: !ScalingMetricType+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'PredefinedScalingMetricSpecification' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'psmsResourceLabel' - Identifies the resource associated with the metric type. You can't specify a resource label unless the metric type is @ALBRequestCountPerTarget@ and there is a target group for an Application Load Balancer attached to the Auto Scaling group, Spot Fleet request, or ECS service. The format is app/<load-balancer-name>/<load-balancer-id>/targetgroup/<target-group-name>/<target-group-id>, where:     * app/<load-balancer-name>/<load-balancer-id> is the final portion of the load balancer ARN     * targetgroup/<target-group-name>/<target-group-id> is the final portion of the target group ARN.+--+-- * 'psmsPredefinedScalingMetricType' - The metric type. The @ALBRequestCountPerTarget@ metric type applies only to Auto Scaling groups, Sport Fleet requests, and ECS services.+predefinedScalingMetricSpecification+    :: ScalingMetricType -- ^ 'psmsPredefinedScalingMetricType'+    -> PredefinedScalingMetricSpecification+predefinedScalingMetricSpecification pPredefinedScalingMetricType_ =+  PredefinedScalingMetricSpecification'+    { _psmsResourceLabel = Nothing+    , _psmsPredefinedScalingMetricType = pPredefinedScalingMetricType_+    }+++-- | Identifies the resource associated with the metric type. You can't specify a resource label unless the metric type is @ALBRequestCountPerTarget@ and there is a target group for an Application Load Balancer attached to the Auto Scaling group, Spot Fleet request, or ECS service. The format is app/<load-balancer-name>/<load-balancer-id>/targetgroup/<target-group-name>/<target-group-id>, where:     * app/<load-balancer-name>/<load-balancer-id> is the final portion of the load balancer ARN     * targetgroup/<target-group-name>/<target-group-id> is the final portion of the target group ARN.+psmsResourceLabel :: Lens' PredefinedScalingMetricSpecification (Maybe Text)+psmsResourceLabel = lens _psmsResourceLabel (\ s a -> s{_psmsResourceLabel = a})++-- | The metric type. The @ALBRequestCountPerTarget@ metric type applies only to Auto Scaling groups, Sport Fleet requests, and ECS services.+psmsPredefinedScalingMetricType :: Lens' PredefinedScalingMetricSpecification ScalingMetricType+psmsPredefinedScalingMetricType = lens _psmsPredefinedScalingMetricType (\ s a -> s{_psmsPredefinedScalingMetricType = a})++instance FromJSON+           PredefinedScalingMetricSpecification+         where+        parseJSON+          = withObject "PredefinedScalingMetricSpecification"+              (\ x ->+                 PredefinedScalingMetricSpecification' <$>+                   (x .:? "ResourceLabel") <*>+                     (x .: "PredefinedScalingMetricType"))++instance Hashable+           PredefinedScalingMetricSpecification+         where++instance NFData PredefinedScalingMetricSpecification+         where++instance ToJSON PredefinedScalingMetricSpecification+         where+        toJSON PredefinedScalingMetricSpecification'{..}+          = object+              (catMaybes+                 [("ResourceLabel" .=) <$> _psmsResourceLabel,+                  Just+                    ("PredefinedScalingMetricType" .=+                       _psmsPredefinedScalingMetricType)])++-- | Specifies the scaling configuration for a scalable resource.+--+--+--+-- /See:/ 'scalingInstruction' smart constructor.+data ScalingInstruction = ScalingInstruction'+  { _siServiceNamespace             :: !ServiceNamespace+  , _siResourceId                   :: !Text+  , _siScalableDimension            :: !ScalableDimension+  , _siMinCapacity                  :: !Int+  , _siMaxCapacity                  :: !Int+  , _siTargetTrackingConfigurations :: ![TargetTrackingConfiguration]+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'ScalingInstruction' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'siServiceNamespace' - The namespace of the AWS service.+--+-- * 'siResourceId' - The ID of the resource. This string consists of the resource type and unique identifier.     * Auto Scaling group - The resource type is @autoScalingGroup@ and the unique identifier is the name of the Auto Scaling group. Example: @autoScalingGroup/my-asg@ .     * ECS service - The resource type is @service@ and the unique identifier is the cluster name and service name. Example: @service/default/sample-webapp@ .     * Spot fleet request - The resource type is @spot-fleet-request@ and the unique identifier is the Spot fleet request ID. Example: @spot-fleet-request/sfr-73fbd2ce-aa30-494c-8788-1cee4EXAMPLE@ .     * DynamoDB table - The resource type is @table@ and the unique identifier is the resource ID. Example: @table/my-table@ .     * DynamoDB global secondary index - The resource type is @index@ and the unique identifier is the resource ID. Example: @table/my-table/index/my-table-index@ .     * Aurora DB cluster - The resource type is @cluster@ and the unique identifier is the cluster name. Example: @cluster:my-db-cluster@ .+--+-- * 'siScalableDimension' - The scalable dimension associated with the resource.     * @autoscaling:autoScalingGroup:DesiredCapacity@ - The desired capacity of an Auto Scaling group.     * @ecs:service:DesiredCount@ - The desired task count of an ECS service.     * @ec2:spot-fleet-request:TargetCapacity@ - The target capacity of a Spot fleet request.     * @dynamodb:table:ReadCapacityUnits@ - The provisioned read capacity for a DynamoDB table.     * @dynamodb:table:WriteCapacityUnits@ - The provisioned write capacity for a DynamoDB table.     * @dynamodb:index:ReadCapacityUnits@ - The provisioned read capacity for a DynamoDB global secondary index.     * @dynamodb:index:WriteCapacityUnits@ - The provisioned write capacity for a DynamoDB global secondary index.     * @rds:cluster:ReadReplicaCount@ - The count of Aurora Replicas in an Aurora DB cluster. Available for Aurora MySQL-compatible edition.+--+-- * 'siMinCapacity' - The minimum value to scale to in response to a scale in event.+--+-- * 'siMaxCapacity' - The maximum value to scale to in response to a scale out event.+--+-- * 'siTargetTrackingConfigurations' - The target tracking scaling policies (up to 10).+scalingInstruction+    :: ServiceNamespace -- ^ 'siServiceNamespace'+    -> Text -- ^ 'siResourceId'+    -> ScalableDimension -- ^ 'siScalableDimension'+    -> Int -- ^ 'siMinCapacity'+    -> Int -- ^ 'siMaxCapacity'+    -> ScalingInstruction+scalingInstruction pServiceNamespace_ pResourceId_ pScalableDimension_ pMinCapacity_ pMaxCapacity_ =+  ScalingInstruction'+    { _siServiceNamespace = pServiceNamespace_+    , _siResourceId = pResourceId_+    , _siScalableDimension = pScalableDimension_+    , _siMinCapacity = pMinCapacity_+    , _siMaxCapacity = pMaxCapacity_+    , _siTargetTrackingConfigurations = mempty+    }+++-- | The namespace of the AWS service.+siServiceNamespace :: Lens' ScalingInstruction ServiceNamespace+siServiceNamespace = lens _siServiceNamespace (\ s a -> s{_siServiceNamespace = a})++-- | The ID of the resource. This string consists of the resource type and unique identifier.     * Auto Scaling group - The resource type is @autoScalingGroup@ and the unique identifier is the name of the Auto Scaling group. Example: @autoScalingGroup/my-asg@ .     * ECS service - The resource type is @service@ and the unique identifier is the cluster name and service name. Example: @service/default/sample-webapp@ .     * Spot fleet request - The resource type is @spot-fleet-request@ and the unique identifier is the Spot fleet request ID. Example: @spot-fleet-request/sfr-73fbd2ce-aa30-494c-8788-1cee4EXAMPLE@ .     * DynamoDB table - The resource type is @table@ and the unique identifier is the resource ID. Example: @table/my-table@ .     * DynamoDB global secondary index - The resource type is @index@ and the unique identifier is the resource ID. Example: @table/my-table/index/my-table-index@ .     * Aurora DB cluster - The resource type is @cluster@ and the unique identifier is the cluster name. Example: @cluster:my-db-cluster@ .+siResourceId :: Lens' ScalingInstruction Text+siResourceId = lens _siResourceId (\ s a -> s{_siResourceId = a})++-- | The scalable dimension associated with the resource.     * @autoscaling:autoScalingGroup:DesiredCapacity@ - The desired capacity of an Auto Scaling group.     * @ecs:service:DesiredCount@ - The desired task count of an ECS service.     * @ec2:spot-fleet-request:TargetCapacity@ - The target capacity of a Spot fleet request.     * @dynamodb:table:ReadCapacityUnits@ - The provisioned read capacity for a DynamoDB table.     * @dynamodb:table:WriteCapacityUnits@ - The provisioned write capacity for a DynamoDB table.     * @dynamodb:index:ReadCapacityUnits@ - The provisioned read capacity for a DynamoDB global secondary index.     * @dynamodb:index:WriteCapacityUnits@ - The provisioned write capacity for a DynamoDB global secondary index.     * @rds:cluster:ReadReplicaCount@ - The count of Aurora Replicas in an Aurora DB cluster. Available for Aurora MySQL-compatible edition.+siScalableDimension :: Lens' ScalingInstruction ScalableDimension+siScalableDimension = lens _siScalableDimension (\ s a -> s{_siScalableDimension = a})++-- | The minimum value to scale to in response to a scale in event.+siMinCapacity :: Lens' ScalingInstruction Int+siMinCapacity = lens _siMinCapacity (\ s a -> s{_siMinCapacity = a})++-- | The maximum value to scale to in response to a scale out event.+siMaxCapacity :: Lens' ScalingInstruction Int+siMaxCapacity = lens _siMaxCapacity (\ s a -> s{_siMaxCapacity = a})++-- | The target tracking scaling policies (up to 10).+siTargetTrackingConfigurations :: Lens' ScalingInstruction [TargetTrackingConfiguration]+siTargetTrackingConfigurations = lens _siTargetTrackingConfigurations (\ s a -> s{_siTargetTrackingConfigurations = a}) . _Coerce++instance FromJSON ScalingInstruction where+        parseJSON+          = withObject "ScalingInstruction"+              (\ x ->+                 ScalingInstruction' <$>+                   (x .: "ServiceNamespace") <*> (x .: "ResourceId") <*>+                     (x .: "ScalableDimension")+                     <*> (x .: "MinCapacity")+                     <*> (x .: "MaxCapacity")+                     <*>+                     (x .:? "TargetTrackingConfigurations" .!= mempty))++instance Hashable ScalingInstruction where++instance NFData ScalingInstruction where++instance ToJSON ScalingInstruction where+        toJSON ScalingInstruction'{..}+          = object+              (catMaybes+                 [Just ("ServiceNamespace" .= _siServiceNamespace),+                  Just ("ResourceId" .= _siResourceId),+                  Just ("ScalableDimension" .= _siScalableDimension),+                  Just ("MinCapacity" .= _siMinCapacity),+                  Just ("MaxCapacity" .= _siMaxCapacity),+                  Just+                    ("TargetTrackingConfigurations" .=+                       _siTargetTrackingConfigurations)])++-- | Represents a scaling plan.+--+--+--+-- /See:/ 'scalingPlan' smart constructor.+data ScalingPlan = ScalingPlan'+  { _spCreationTime        :: !(Maybe POSIX)+  , _spStatusStartTime     :: !(Maybe POSIX)+  , _spStatusMessage       :: !(Maybe Text)+  , _spScalingPlanName     :: !Text+  , _spScalingPlanVersion  :: !Integer+  , _spApplicationSource   :: !ApplicationSource+  , _spScalingInstructions :: ![ScalingInstruction]+  , _spStatusCode          :: !ScalingPlanStatusCode+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'ScalingPlan' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'spCreationTime' - The Unix timestamp when the scaling plan was created.+--+-- * 'spStatusStartTime' - The Unix timestamp when the scaling plan entered the current status.+--+-- * 'spStatusMessage' - A simple message about the current status of the scaling plan.+--+-- * 'spScalingPlanName' - The name of the scaling plan.+--+-- * 'spScalingPlanVersion' - The version of the scaling plan.+--+-- * 'spApplicationSource' - The application source.+--+-- * 'spScalingInstructions' - The scaling instructions.+--+-- * 'spStatusCode' - The status of the scaling plan.     * @Active@ - The scaling plan is active.     * @ActiveWithProblems@ - The scaling plan is active, but the scaling configuration for one or more resources could not be applied.     * @CreationInProgress@ - The scaling plan is being created.     * @CreationFailed@ - The scaling plan could not be created.     * @DeletionInProgress@ - The scaling plan is being deleted.     * @DeletionFailed@ - The scaling plan could not be deleted.+scalingPlan+    :: Text -- ^ 'spScalingPlanName'+    -> Integer -- ^ 'spScalingPlanVersion'+    -> ApplicationSource -- ^ 'spApplicationSource'+    -> ScalingPlanStatusCode -- ^ 'spStatusCode'+    -> ScalingPlan+scalingPlan pScalingPlanName_ pScalingPlanVersion_ pApplicationSource_ pStatusCode_ =+  ScalingPlan'+    { _spCreationTime = Nothing+    , _spStatusStartTime = Nothing+    , _spStatusMessage = Nothing+    , _spScalingPlanName = pScalingPlanName_+    , _spScalingPlanVersion = pScalingPlanVersion_+    , _spApplicationSource = pApplicationSource_+    , _spScalingInstructions = mempty+    , _spStatusCode = pStatusCode_+    }+++-- | The Unix timestamp when the scaling plan was created.+spCreationTime :: Lens' ScalingPlan (Maybe UTCTime)+spCreationTime = lens _spCreationTime (\ s a -> s{_spCreationTime = a}) . mapping _Time++-- | The Unix timestamp when the scaling plan entered the current status.+spStatusStartTime :: Lens' ScalingPlan (Maybe UTCTime)+spStatusStartTime = lens _spStatusStartTime (\ s a -> s{_spStatusStartTime = a}) . mapping _Time++-- | A simple message about the current status of the scaling plan.+spStatusMessage :: Lens' ScalingPlan (Maybe Text)+spStatusMessage = lens _spStatusMessage (\ s a -> s{_spStatusMessage = a})++-- | The name of the scaling plan.+spScalingPlanName :: Lens' ScalingPlan Text+spScalingPlanName = lens _spScalingPlanName (\ s a -> s{_spScalingPlanName = a})++-- | The version of the scaling plan.+spScalingPlanVersion :: Lens' ScalingPlan Integer+spScalingPlanVersion = lens _spScalingPlanVersion (\ s a -> s{_spScalingPlanVersion = a})++-- | The application source.+spApplicationSource :: Lens' ScalingPlan ApplicationSource+spApplicationSource = lens _spApplicationSource (\ s a -> s{_spApplicationSource = a})++-- | The scaling instructions.+spScalingInstructions :: Lens' ScalingPlan [ScalingInstruction]+spScalingInstructions = lens _spScalingInstructions (\ s a -> s{_spScalingInstructions = a}) . _Coerce++-- | The status of the scaling plan.     * @Active@ - The scaling plan is active.     * @ActiveWithProblems@ - The scaling plan is active, but the scaling configuration for one or more resources could not be applied.     * @CreationInProgress@ - The scaling plan is being created.     * @CreationFailed@ - The scaling plan could not be created.     * @DeletionInProgress@ - The scaling plan is being deleted.     * @DeletionFailed@ - The scaling plan could not be deleted.+spStatusCode :: Lens' ScalingPlan ScalingPlanStatusCode+spStatusCode = lens _spStatusCode (\ s a -> s{_spStatusCode = a})++instance FromJSON ScalingPlan where+        parseJSON+          = withObject "ScalingPlan"+              (\ x ->+                 ScalingPlan' <$>+                   (x .:? "CreationTime") <*> (x .:? "StatusStartTime")+                     <*> (x .:? "StatusMessage")+                     <*> (x .: "ScalingPlanName")+                     <*> (x .: "ScalingPlanVersion")+                     <*> (x .: "ApplicationSource")+                     <*> (x .:? "ScalingInstructions" .!= mempty)+                     <*> (x .: "StatusCode"))++instance Hashable ScalingPlan where++instance NFData ScalingPlan where++-- | Represents a scalable resource.+--+--+--+-- /See:/ 'scalingPlanResource' smart constructor.+data ScalingPlanResource = ScalingPlanResource'+  { _sprScalingStatusMessage :: !(Maybe Text)+  , _sprScalingPolicies      :: !(Maybe [ScalingPolicy])+  , _sprScalingPlanName      :: !Text+  , _sprScalingPlanVersion   :: !Integer+  , _sprServiceNamespace     :: !ServiceNamespace+  , _sprResourceId           :: !Text+  , _sprScalableDimension    :: !ScalableDimension+  , _sprScalingStatusCode    :: !ScalingStatusCode+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'ScalingPlanResource' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'sprScalingStatusMessage' - A simple message about the current scaling status of the resource.+--+-- * 'sprScalingPolicies' - The scaling policies.+--+-- * 'sprScalingPlanName' - The name of the scaling plan.+--+-- * 'sprScalingPlanVersion' - The version of the scaling plan.+--+-- * 'sprServiceNamespace' - The namespace of the AWS service.+--+-- * 'sprResourceId' - The ID of the resource. This string consists of the resource type and unique identifier.     * Auto Scaling group - The resource type is @autoScalingGroup@ and the unique identifier is the name of the Auto Scaling group. Example: @autoScalingGroup/my-asg@ .     * ECS service - The resource type is @service@ and the unique identifier is the cluster name and service name. Example: @service/default/sample-webapp@ .     * Spot fleet request - The resource type is @spot-fleet-request@ and the unique identifier is the Spot fleet request ID. Example: @spot-fleet-request/sfr-73fbd2ce-aa30-494c-8788-1cee4EXAMPLE@ .     * DynamoDB table - The resource type is @table@ and the unique identifier is the resource ID. Example: @table/my-table@ .     * DynamoDB global secondary index - The resource type is @index@ and the unique identifier is the resource ID. Example: @table/my-table/index/my-table-index@ .     * Aurora DB cluster - The resource type is @cluster@ and the unique identifier is the cluster name. Example: @cluster:my-db-cluster@ .+--+-- * 'sprScalableDimension' - The scalable dimension for the resource.     * @autoscaling:autoScalingGroup:DesiredCapacity@ - The desired capacity of an Auto Scaling group.     * @ecs:service:DesiredCount@ - The desired task count of an ECS service.     * @ec2:spot-fleet-request:TargetCapacity@ - The target capacity of a Spot fleet request.     * @dynamodb:table:ReadCapacityUnits@ - The provisioned read capacity for a DynamoDB table.     * @dynamodb:table:WriteCapacityUnits@ - The provisioned write capacity for a DynamoDB table.     * @dynamodb:index:ReadCapacityUnits@ - The provisioned read capacity for a DynamoDB global secondary index.     * @dynamodb:index:WriteCapacityUnits@ - The provisioned write capacity for a DynamoDB global secondary index.     * @rds:cluster:ReadReplicaCount@ - The count of Aurora Replicas in an Aurora DB cluster. Available for Aurora MySQL-compatible edition.+--+-- * 'sprScalingStatusCode' - The scaling status of the resource.     * @Active@ - The scaling configuration is active.     * @Inactive@ - The scaling configuration is not active because the scaling plan is being created or the scaling configuration could not be applied. Check the status message for more information.     * @PartiallyActive@ - The scaling configuration is partially active because the scaling plan is being created or deleted or the scaling configuration could not be fully applied. Check the status message for more information.+scalingPlanResource+    :: Text -- ^ 'sprScalingPlanName'+    -> Integer -- ^ 'sprScalingPlanVersion'+    -> ServiceNamespace -- ^ 'sprServiceNamespace'+    -> Text -- ^ 'sprResourceId'+    -> ScalableDimension -- ^ 'sprScalableDimension'+    -> ScalingStatusCode -- ^ 'sprScalingStatusCode'+    -> ScalingPlanResource+scalingPlanResource pScalingPlanName_ pScalingPlanVersion_ pServiceNamespace_ pResourceId_ pScalableDimension_ pScalingStatusCode_ =+  ScalingPlanResource'+    { _sprScalingStatusMessage = Nothing+    , _sprScalingPolicies = Nothing+    , _sprScalingPlanName = pScalingPlanName_+    , _sprScalingPlanVersion = pScalingPlanVersion_+    , _sprServiceNamespace = pServiceNamespace_+    , _sprResourceId = pResourceId_+    , _sprScalableDimension = pScalableDimension_+    , _sprScalingStatusCode = pScalingStatusCode_+    }+++-- | A simple message about the current scaling status of the resource.+sprScalingStatusMessage :: Lens' ScalingPlanResource (Maybe Text)+sprScalingStatusMessage = lens _sprScalingStatusMessage (\ s a -> s{_sprScalingStatusMessage = a})++-- | The scaling policies.+sprScalingPolicies :: Lens' ScalingPlanResource [ScalingPolicy]+sprScalingPolicies = lens _sprScalingPolicies (\ s a -> s{_sprScalingPolicies = a}) . _Default . _Coerce++-- | The name of the scaling plan.+sprScalingPlanName :: Lens' ScalingPlanResource Text+sprScalingPlanName = lens _sprScalingPlanName (\ s a -> s{_sprScalingPlanName = a})++-- | The version of the scaling plan.+sprScalingPlanVersion :: Lens' ScalingPlanResource Integer+sprScalingPlanVersion = lens _sprScalingPlanVersion (\ s a -> s{_sprScalingPlanVersion = a})++-- | The namespace of the AWS service.+sprServiceNamespace :: Lens' ScalingPlanResource ServiceNamespace+sprServiceNamespace = lens _sprServiceNamespace (\ s a -> s{_sprServiceNamespace = a})++-- | The ID of the resource. This string consists of the resource type and unique identifier.     * Auto Scaling group - The resource type is @autoScalingGroup@ and the unique identifier is the name of the Auto Scaling group. Example: @autoScalingGroup/my-asg@ .     * ECS service - The resource type is @service@ and the unique identifier is the cluster name and service name. Example: @service/default/sample-webapp@ .     * Spot fleet request - The resource type is @spot-fleet-request@ and the unique identifier is the Spot fleet request ID. Example: @spot-fleet-request/sfr-73fbd2ce-aa30-494c-8788-1cee4EXAMPLE@ .     * DynamoDB table - The resource type is @table@ and the unique identifier is the resource ID. Example: @table/my-table@ .     * DynamoDB global secondary index - The resource type is @index@ and the unique identifier is the resource ID. Example: @table/my-table/index/my-table-index@ .     * Aurora DB cluster - The resource type is @cluster@ and the unique identifier is the cluster name. Example: @cluster:my-db-cluster@ .+sprResourceId :: Lens' ScalingPlanResource Text+sprResourceId = lens _sprResourceId (\ s a -> s{_sprResourceId = a})++-- | The scalable dimension for the resource.     * @autoscaling:autoScalingGroup:DesiredCapacity@ - The desired capacity of an Auto Scaling group.     * @ecs:service:DesiredCount@ - The desired task count of an ECS service.     * @ec2:spot-fleet-request:TargetCapacity@ - The target capacity of a Spot fleet request.     * @dynamodb:table:ReadCapacityUnits@ - The provisioned read capacity for a DynamoDB table.     * @dynamodb:table:WriteCapacityUnits@ - The provisioned write capacity for a DynamoDB table.     * @dynamodb:index:ReadCapacityUnits@ - The provisioned read capacity for a DynamoDB global secondary index.     * @dynamodb:index:WriteCapacityUnits@ - The provisioned write capacity for a DynamoDB global secondary index.     * @rds:cluster:ReadReplicaCount@ - The count of Aurora Replicas in an Aurora DB cluster. Available for Aurora MySQL-compatible edition.+sprScalableDimension :: Lens' ScalingPlanResource ScalableDimension+sprScalableDimension = lens _sprScalableDimension (\ s a -> s{_sprScalableDimension = a})++-- | The scaling status of the resource.     * @Active@ - The scaling configuration is active.     * @Inactive@ - The scaling configuration is not active because the scaling plan is being created or the scaling configuration could not be applied. Check the status message for more information.     * @PartiallyActive@ - The scaling configuration is partially active because the scaling plan is being created or deleted or the scaling configuration could not be fully applied. Check the status message for more information.+sprScalingStatusCode :: Lens' ScalingPlanResource ScalingStatusCode+sprScalingStatusCode = lens _sprScalingStatusCode (\ s a -> s{_sprScalingStatusCode = a})++instance FromJSON ScalingPlanResource where+        parseJSON+          = withObject "ScalingPlanResource"+              (\ x ->+                 ScalingPlanResource' <$>+                   (x .:? "ScalingStatusMessage") <*>+                     (x .:? "ScalingPolicies" .!= mempty)+                     <*> (x .: "ScalingPlanName")+                     <*> (x .: "ScalingPlanVersion")+                     <*> (x .: "ServiceNamespace")+                     <*> (x .: "ResourceId")+                     <*> (x .: "ScalableDimension")+                     <*> (x .: "ScalingStatusCode"))++instance Hashable ScalingPlanResource where++instance NFData ScalingPlanResource where++-- | Represents a scaling policy.+--+--+--+-- /See:/ 'scalingPolicy' smart constructor.+data ScalingPolicy = ScalingPolicy'+  { _spTargetTrackingConfiguration :: !(Maybe TargetTrackingConfiguration)+  , _spPolicyName                  :: !Text+  , _spPolicyType                  :: !PolicyType+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'ScalingPolicy' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'spTargetTrackingConfiguration' - The target tracking scaling policy.+--+-- * 'spPolicyName' - The name of the scaling policy.+--+-- * 'spPolicyType' - The type of scaling policy.+scalingPolicy+    :: Text -- ^ 'spPolicyName'+    -> PolicyType -- ^ 'spPolicyType'+    -> ScalingPolicy+scalingPolicy pPolicyName_ pPolicyType_ =+  ScalingPolicy'+    { _spTargetTrackingConfiguration = Nothing+    , _spPolicyName = pPolicyName_+    , _spPolicyType = pPolicyType_+    }+++-- | The target tracking scaling policy.+spTargetTrackingConfiguration :: Lens' ScalingPolicy (Maybe TargetTrackingConfiguration)+spTargetTrackingConfiguration = lens _spTargetTrackingConfiguration (\ s a -> s{_spTargetTrackingConfiguration = a})++-- | The name of the scaling policy.+spPolicyName :: Lens' ScalingPolicy Text+spPolicyName = lens _spPolicyName (\ s a -> s{_spPolicyName = a})++-- | The type of scaling policy.+spPolicyType :: Lens' ScalingPolicy PolicyType+spPolicyType = lens _spPolicyType (\ s a -> s{_spPolicyType = a})++instance FromJSON ScalingPolicy where+        parseJSON+          = withObject "ScalingPolicy"+              (\ x ->+                 ScalingPolicy' <$>+                   (x .:? "TargetTrackingConfiguration") <*>+                     (x .: "PolicyName")+                     <*> (x .: "PolicyType"))++instance Hashable ScalingPolicy where++instance NFData ScalingPolicy where++-- | Represents a tag.+--+--+--+-- /See:/ 'tagFilter' smart constructor.+data TagFilter = TagFilter'+  { _tfValues :: !(Maybe [Text])+  , _tfKey    :: !(Maybe Text)+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'TagFilter' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'tfValues' - The tag values (0 to 20).+--+-- * 'tfKey' - The tag key.+tagFilter+    :: TagFilter+tagFilter = TagFilter' {_tfValues = Nothing, _tfKey = Nothing}+++-- | The tag values (0 to 20).+tfValues :: Lens' TagFilter [Text]+tfValues = lens _tfValues (\ s a -> s{_tfValues = a}) . _Default . _Coerce++-- | The tag key.+tfKey :: Lens' TagFilter (Maybe Text)+tfKey = lens _tfKey (\ s a -> s{_tfKey = a})++instance FromJSON TagFilter where+        parseJSON+          = withObject "TagFilter"+              (\ x ->+                 TagFilter' <$>+                   (x .:? "Values" .!= mempty) <*> (x .:? "Key"))++instance Hashable TagFilter where++instance NFData TagFilter where++instance ToJSON TagFilter where+        toJSON TagFilter'{..}+          = object+              (catMaybes+                 [("Values" .=) <$> _tfValues, ("Key" .=) <$> _tfKey])++-- | Represents a target tracking scaling policy.+--+--+--+-- /See:/ 'targetTrackingConfiguration' smart constructor.+data TargetTrackingConfiguration = TargetTrackingConfiguration'+  { _ttcEstimatedInstanceWarmup :: !(Maybe Int)+  , _ttcPredefinedScalingMetricSpecification :: !(Maybe PredefinedScalingMetricSpecification)+  , _ttcScaleInCooldown :: !(Maybe Int)+  , _ttcDisableScaleIn :: !(Maybe Bool)+  , _ttcCustomizedScalingMetricSpecification :: !(Maybe CustomizedScalingMetricSpecification)+  , _ttcScaleOutCooldown :: !(Maybe Int)+  , _ttcTargetValue :: !Double+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'TargetTrackingConfiguration' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'ttcEstimatedInstanceWarmup' - The estimated time, in seconds, until a newly launched instance can contribute to the CloudWatch metrics. This value is used only if the resource is an Auto Scaling group.+--+-- * 'ttcPredefinedScalingMetricSpecification' - A predefined metric.+--+-- * 'ttcScaleInCooldown' - The amount of time, in seconds, after a scale in activity completes before another scale in activity can start. This value is not used if the scalable resource is an Auto Scaling group. The cooldown period is used to block subsequent scale in requests until it has expired. The intention is to scale in conservatively to protect your application's availability. However, if another alarm triggers a scale out policy during the cooldown period after a scale-in, AWS Auto Scaling scales out your scalable target immediately.+--+-- * 'ttcDisableScaleIn' - Indicates whether scale in by the target tracking policy is disabled. If the value is @true@ , scale in is disabled and the target tracking policy won't remove capacity from the scalable resource. Otherwise, scale in is enabled and the target tracking policy can remove capacity from the scalable resource. The default value is @false@ .+--+-- * 'ttcCustomizedScalingMetricSpecification' - A customized metric.+--+-- * 'ttcScaleOutCooldown' - The amount of time, in seconds, after a scale out activity completes before another scale out activity can start. This value is not used if the scalable resource is an Auto Scaling group. While the cooldown period is in effect, the capacity that has been added by the previous scale out event that initiated the cooldown is calculated as part of the desired capacity for the next scale out. The intention is to continuously (but not excessively) scale out.+--+-- * 'ttcTargetValue' - The target value for the metric. The range is 8.515920e-109 to 1.174271e+108 (Base 10) or 2e-360 to 2e360 (Base 2).+targetTrackingConfiguration+    :: Double -- ^ 'ttcTargetValue'+    -> TargetTrackingConfiguration+targetTrackingConfiguration pTargetValue_ =+  TargetTrackingConfiguration'+    { _ttcEstimatedInstanceWarmup = Nothing+    , _ttcPredefinedScalingMetricSpecification = Nothing+    , _ttcScaleInCooldown = Nothing+    , _ttcDisableScaleIn = Nothing+    , _ttcCustomizedScalingMetricSpecification = Nothing+    , _ttcScaleOutCooldown = Nothing+    , _ttcTargetValue = pTargetValue_+    }+++-- | The estimated time, in seconds, until a newly launched instance can contribute to the CloudWatch metrics. This value is used only if the resource is an Auto Scaling group.+ttcEstimatedInstanceWarmup :: Lens' TargetTrackingConfiguration (Maybe Int)+ttcEstimatedInstanceWarmup = lens _ttcEstimatedInstanceWarmup (\ s a -> s{_ttcEstimatedInstanceWarmup = a})++-- | A predefined metric.+ttcPredefinedScalingMetricSpecification :: Lens' TargetTrackingConfiguration (Maybe PredefinedScalingMetricSpecification)+ttcPredefinedScalingMetricSpecification = lens _ttcPredefinedScalingMetricSpecification (\ s a -> s{_ttcPredefinedScalingMetricSpecification = a})++-- | The amount of time, in seconds, after a scale in activity completes before another scale in activity can start. This value is not used if the scalable resource is an Auto Scaling group. The cooldown period is used to block subsequent scale in requests until it has expired. The intention is to scale in conservatively to protect your application's availability. However, if another alarm triggers a scale out policy during the cooldown period after a scale-in, AWS Auto Scaling scales out your scalable target immediately.+ttcScaleInCooldown :: Lens' TargetTrackingConfiguration (Maybe Int)+ttcScaleInCooldown = lens _ttcScaleInCooldown (\ s a -> s{_ttcScaleInCooldown = a})++-- | Indicates whether scale in by the target tracking policy is disabled. If the value is @true@ , scale in is disabled and the target tracking policy won't remove capacity from the scalable resource. Otherwise, scale in is enabled and the target tracking policy can remove capacity from the scalable resource. The default value is @false@ .+ttcDisableScaleIn :: Lens' TargetTrackingConfiguration (Maybe Bool)+ttcDisableScaleIn = lens _ttcDisableScaleIn (\ s a -> s{_ttcDisableScaleIn = a})++-- | A customized metric.+ttcCustomizedScalingMetricSpecification :: Lens' TargetTrackingConfiguration (Maybe CustomizedScalingMetricSpecification)+ttcCustomizedScalingMetricSpecification = lens _ttcCustomizedScalingMetricSpecification (\ s a -> s{_ttcCustomizedScalingMetricSpecification = a})++-- | The amount of time, in seconds, after a scale out activity completes before another scale out activity can start. This value is not used if the scalable resource is an Auto Scaling group. While the cooldown period is in effect, the capacity that has been added by the previous scale out event that initiated the cooldown is calculated as part of the desired capacity for the next scale out. The intention is to continuously (but not excessively) scale out.+ttcScaleOutCooldown :: Lens' TargetTrackingConfiguration (Maybe Int)+ttcScaleOutCooldown = lens _ttcScaleOutCooldown (\ s a -> s{_ttcScaleOutCooldown = a})++-- | The target value for the metric. The range is 8.515920e-109 to 1.174271e+108 (Base 10) or 2e-360 to 2e360 (Base 2).+ttcTargetValue :: Lens' TargetTrackingConfiguration Double+ttcTargetValue = lens _ttcTargetValue (\ s a -> s{_ttcTargetValue = a})++instance FromJSON TargetTrackingConfiguration where+        parseJSON+          = withObject "TargetTrackingConfiguration"+              (\ x ->+                 TargetTrackingConfiguration' <$>+                   (x .:? "EstimatedInstanceWarmup") <*>+                     (x .:? "PredefinedScalingMetricSpecification")+                     <*> (x .:? "ScaleInCooldown")+                     <*> (x .:? "DisableScaleIn")+                     <*> (x .:? "CustomizedScalingMetricSpecification")+                     <*> (x .:? "ScaleOutCooldown")+                     <*> (x .: "TargetValue"))++instance Hashable TargetTrackingConfiguration where++instance NFData TargetTrackingConfiguration where++instance ToJSON TargetTrackingConfiguration where+        toJSON TargetTrackingConfiguration'{..}+          = object+              (catMaybes+                 [("EstimatedInstanceWarmup" .=) <$>+                    _ttcEstimatedInstanceWarmup,+                  ("PredefinedScalingMetricSpecification" .=) <$>+                    _ttcPredefinedScalingMetricSpecification,+                  ("ScaleInCooldown" .=) <$> _ttcScaleInCooldown,+                  ("DisableScaleIn" .=) <$> _ttcDisableScaleIn,+                  ("CustomizedScalingMetricSpecification" .=) <$>+                    _ttcCustomizedScalingMetricSpecification,+                  ("ScaleOutCooldown" .=) <$> _ttcScaleOutCooldown,+                  Just ("TargetValue" .= _ttcTargetValue)])
+ gen/Network/AWS/AutoScalingPlans/Types/Sum.hs view
@@ -0,0 +1,308 @@+{-# LANGUAGE DeriveDataTypeable #-}+{-# LANGUAGE DeriveGeneric      #-}+{-# LANGUAGE LambdaCase         #-}+{-# LANGUAGE OverloadedStrings  #-}++{-# OPTIONS_GHC -fno-warn-unused-imports #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module      : Network.AWS.AutoScalingPlans.Types.Sum+-- Copyright   : (c) 2013-2018 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 Network.AWS.AutoScalingPlans.Types.Sum where++import Network.AWS.Prelude++data MetricStatistic+  = Average+  | Maximum+  | Minimum+  | SampleCount+  | Sum+  deriving (Eq, Ord, Read, Show, Enum, Bounded, Data, Typeable, Generic)+++instance FromText MetricStatistic where+    parser = takeLowerText >>= \case+        "average" -> pure Average+        "maximum" -> pure Maximum+        "minimum" -> pure Minimum+        "samplecount" -> pure SampleCount+        "sum" -> pure Sum+        e -> fromTextError $ "Failure parsing MetricStatistic from value: '" <> e+           <> "'. Accepted values: average, maximum, minimum, samplecount, sum"++instance ToText MetricStatistic where+    toText = \case+        Average -> "Average"+        Maximum -> "Maximum"+        Minimum -> "Minimum"+        SampleCount -> "SampleCount"+        Sum -> "Sum"++instance Hashable     MetricStatistic+instance NFData       MetricStatistic+instance ToByteString MetricStatistic+instance ToQuery      MetricStatistic+instance ToHeader     MetricStatistic++instance ToJSON MetricStatistic where+    toJSON = toJSONText++instance FromJSON MetricStatistic where+    parseJSON = parseJSONText "MetricStatistic"++data PolicyType =+  TargetTrackingScaling+  deriving (Eq, Ord, Read, Show, Enum, Bounded, Data, Typeable, Generic)+++instance FromText PolicyType where+    parser = takeLowerText >>= \case+        "targettrackingscaling" -> pure TargetTrackingScaling+        e -> fromTextError $ "Failure parsing PolicyType from value: '" <> e+           <> "'. Accepted values: targettrackingscaling"++instance ToText PolicyType where+    toText = \case+        TargetTrackingScaling -> "TargetTrackingScaling"++instance Hashable     PolicyType+instance NFData       PolicyType+instance ToByteString PolicyType+instance ToQuery      PolicyType+instance ToHeader     PolicyType++instance FromJSON PolicyType where+    parseJSON = parseJSONText "PolicyType"++data ScalableDimension+  = AutoscalingAutoScalingGroupDesiredCapacity+  | DynamodbIndexReadCapacityUnits+  | DynamodbIndexWriteCapacityUnits+  | DynamodbTableReadCapacityUnits+  | DynamodbTableWriteCapacityUnits+  | EC2SpotFleetRequestTargetCapacity+  | EcsServiceDesiredCount+  | RDSClusterReadReplicaCount+  deriving (Eq, Ord, Read, Show, Enum, Bounded, Data, Typeable, Generic)+++instance FromText ScalableDimension where+    parser = takeLowerText >>= \case+        "autoscaling:autoscalinggroup:desiredcapacity" -> pure AutoscalingAutoScalingGroupDesiredCapacity+        "dynamodb:index:readcapacityunits" -> pure DynamodbIndexReadCapacityUnits+        "dynamodb:index:writecapacityunits" -> pure DynamodbIndexWriteCapacityUnits+        "dynamodb:table:readcapacityunits" -> pure DynamodbTableReadCapacityUnits+        "dynamodb:table:writecapacityunits" -> pure DynamodbTableWriteCapacityUnits+        "ec2:spot-fleet-request:targetcapacity" -> pure EC2SpotFleetRequestTargetCapacity+        "ecs:service:desiredcount" -> pure EcsServiceDesiredCount+        "rds:cluster:readreplicacount" -> pure RDSClusterReadReplicaCount+        e -> fromTextError $ "Failure parsing ScalableDimension from value: '" <> e+           <> "'. Accepted values: autoscaling:autoscalinggroup:desiredcapacity, dynamodb:index:readcapacityunits, dynamodb:index:writecapacityunits, dynamodb:table:readcapacityunits, dynamodb:table:writecapacityunits, ec2:spot-fleet-request:targetcapacity, ecs:service:desiredcount, rds:cluster:readreplicacount"++instance ToText ScalableDimension where+    toText = \case+        AutoscalingAutoScalingGroupDesiredCapacity -> "autoscaling:autoScalingGroup:DesiredCapacity"+        DynamodbIndexReadCapacityUnits -> "dynamodb:index:ReadCapacityUnits"+        DynamodbIndexWriteCapacityUnits -> "dynamodb:index:WriteCapacityUnits"+        DynamodbTableReadCapacityUnits -> "dynamodb:table:ReadCapacityUnits"+        DynamodbTableWriteCapacityUnits -> "dynamodb:table:WriteCapacityUnits"+        EC2SpotFleetRequestTargetCapacity -> "ec2:spot-fleet-request:TargetCapacity"+        EcsServiceDesiredCount -> "ecs:service:DesiredCount"+        RDSClusterReadReplicaCount -> "rds:cluster:ReadReplicaCount"++instance Hashable     ScalableDimension+instance NFData       ScalableDimension+instance ToByteString ScalableDimension+instance ToQuery      ScalableDimension+instance ToHeader     ScalableDimension++instance ToJSON ScalableDimension where+    toJSON = toJSONText++instance FromJSON ScalableDimension where+    parseJSON = parseJSONText "ScalableDimension"++data ScalingMetricType+  = ALBRequestCountPerTarget+  | ASGAverageCPUUtilization+  | ASGAverageNetworkIn+  | ASGAverageNetworkOut+  | DynamoDBReadCapacityUtilization+  | DynamoDBWriteCapacityUtilization+  | EC2SpotFleetRequestAverageCPUUtilization+  | EC2SpotFleetRequestAverageNetworkIn+  | EC2SpotFleetRequestAverageNetworkOut+  | ECSServiceAverageCPUUtilization+  | ECSServiceAverageMemoryUtilization+  | RDSReaderAverageCPUUtilization+  | RDSReaderAverageDatabaseConnections+  deriving (Eq, Ord, Read, Show, Enum, Bounded, Data, Typeable, Generic)+++instance FromText ScalingMetricType where+    parser = takeLowerText >>= \case+        "albrequestcountpertarget" -> pure ALBRequestCountPerTarget+        "asgaveragecpuutilization" -> pure ASGAverageCPUUtilization+        "asgaveragenetworkin" -> pure ASGAverageNetworkIn+        "asgaveragenetworkout" -> pure ASGAverageNetworkOut+        "dynamodbreadcapacityutilization" -> pure DynamoDBReadCapacityUtilization+        "dynamodbwritecapacityutilization" -> pure DynamoDBWriteCapacityUtilization+        "ec2spotfleetrequestaveragecpuutilization" -> pure EC2SpotFleetRequestAverageCPUUtilization+        "ec2spotfleetrequestaveragenetworkin" -> pure EC2SpotFleetRequestAverageNetworkIn+        "ec2spotfleetrequestaveragenetworkout" -> pure EC2SpotFleetRequestAverageNetworkOut+        "ecsserviceaveragecpuutilization" -> pure ECSServiceAverageCPUUtilization+        "ecsserviceaveragememoryutilization" -> pure ECSServiceAverageMemoryUtilization+        "rdsreaderaveragecpuutilization" -> pure RDSReaderAverageCPUUtilization+        "rdsreaderaveragedatabaseconnections" -> pure RDSReaderAverageDatabaseConnections+        e -> fromTextError $ "Failure parsing ScalingMetricType from value: '" <> e+           <> "'. Accepted values: albrequestcountpertarget, asgaveragecpuutilization, asgaveragenetworkin, asgaveragenetworkout, dynamodbreadcapacityutilization, dynamodbwritecapacityutilization, ec2spotfleetrequestaveragecpuutilization, ec2spotfleetrequestaveragenetworkin, ec2spotfleetrequestaveragenetworkout, ecsserviceaveragecpuutilization, ecsserviceaveragememoryutilization, rdsreaderaveragecpuutilization, rdsreaderaveragedatabaseconnections"++instance ToText ScalingMetricType where+    toText = \case+        ALBRequestCountPerTarget -> "ALBRequestCountPerTarget"+        ASGAverageCPUUtilization -> "ASGAverageCPUUtilization"+        ASGAverageNetworkIn -> "ASGAverageNetworkIn"+        ASGAverageNetworkOut -> "ASGAverageNetworkOut"+        DynamoDBReadCapacityUtilization -> "DynamoDBReadCapacityUtilization"+        DynamoDBWriteCapacityUtilization -> "DynamoDBWriteCapacityUtilization"+        EC2SpotFleetRequestAverageCPUUtilization -> "EC2SpotFleetRequestAverageCPUUtilization"+        EC2SpotFleetRequestAverageNetworkIn -> "EC2SpotFleetRequestAverageNetworkIn"+        EC2SpotFleetRequestAverageNetworkOut -> "EC2SpotFleetRequestAverageNetworkOut"+        ECSServiceAverageCPUUtilization -> "ECSServiceAverageCPUUtilization"+        ECSServiceAverageMemoryUtilization -> "ECSServiceAverageMemoryUtilization"+        RDSReaderAverageCPUUtilization -> "RDSReaderAverageCPUUtilization"+        RDSReaderAverageDatabaseConnections -> "RDSReaderAverageDatabaseConnections"++instance Hashable     ScalingMetricType+instance NFData       ScalingMetricType+instance ToByteString ScalingMetricType+instance ToQuery      ScalingMetricType+instance ToHeader     ScalingMetricType++instance ToJSON ScalingMetricType where+    toJSON = toJSONText++instance FromJSON ScalingMetricType where+    parseJSON = parseJSONText "ScalingMetricType"++data ScalingPlanStatusCode+  = SPSCActive+  | SPSCActiveWithProblems+  | SPSCCreationFailed+  | SPSCCreationInProgress+  | SPSCDeletionFailed+  | SPSCDeletionInProgress+  | SPSCUpdateFailed+  | SPSCUpdateInProgress+  deriving (Eq, Ord, Read, Show, Enum, Bounded, Data, Typeable, Generic)+++instance FromText ScalingPlanStatusCode where+    parser = takeLowerText >>= \case+        "active" -> pure SPSCActive+        "activewithproblems" -> pure SPSCActiveWithProblems+        "creationfailed" -> pure SPSCCreationFailed+        "creationinprogress" -> pure SPSCCreationInProgress+        "deletionfailed" -> pure SPSCDeletionFailed+        "deletioninprogress" -> pure SPSCDeletionInProgress+        "updatefailed" -> pure SPSCUpdateFailed+        "updateinprogress" -> pure SPSCUpdateInProgress+        e -> fromTextError $ "Failure parsing ScalingPlanStatusCode from value: '" <> e+           <> "'. Accepted values: active, activewithproblems, creationfailed, creationinprogress, deletionfailed, deletioninprogress, updatefailed, updateinprogress"++instance ToText ScalingPlanStatusCode where+    toText = \case+        SPSCActive -> "Active"+        SPSCActiveWithProblems -> "ActiveWithProblems"+        SPSCCreationFailed -> "CreationFailed"+        SPSCCreationInProgress -> "CreationInProgress"+        SPSCDeletionFailed -> "DeletionFailed"+        SPSCDeletionInProgress -> "DeletionInProgress"+        SPSCUpdateFailed -> "UpdateFailed"+        SPSCUpdateInProgress -> "UpdateInProgress"++instance Hashable     ScalingPlanStatusCode+instance NFData       ScalingPlanStatusCode+instance ToByteString ScalingPlanStatusCode+instance ToQuery      ScalingPlanStatusCode+instance ToHeader     ScalingPlanStatusCode++instance FromJSON ScalingPlanStatusCode where+    parseJSON = parseJSONText "ScalingPlanStatusCode"++data ScalingStatusCode+  = Active+  | Inactive+  | PartiallyActive+  deriving (Eq, Ord, Read, Show, Enum, Bounded, Data, Typeable, Generic)+++instance FromText ScalingStatusCode where+    parser = takeLowerText >>= \case+        "active" -> pure Active+        "inactive" -> pure Inactive+        "partiallyactive" -> pure PartiallyActive+        e -> fromTextError $ "Failure parsing ScalingStatusCode from value: '" <> e+           <> "'. Accepted values: active, inactive, partiallyactive"++instance ToText ScalingStatusCode where+    toText = \case+        Active -> "Active"+        Inactive -> "Inactive"+        PartiallyActive -> "PartiallyActive"++instance Hashable     ScalingStatusCode+instance NFData       ScalingStatusCode+instance ToByteString ScalingStatusCode+instance ToQuery      ScalingStatusCode+instance ToHeader     ScalingStatusCode++instance FromJSON ScalingStatusCode where+    parseJSON = parseJSONText "ScalingStatusCode"++data ServiceNamespace+  = Autoscaling+  | Dynamodb+  | EC2+  | Ecs+  | RDS+  deriving (Eq, Ord, Read, Show, Enum, Bounded, Data, Typeable, Generic)+++instance FromText ServiceNamespace where+    parser = takeLowerText >>= \case+        "autoscaling" -> pure Autoscaling+        "dynamodb" -> pure Dynamodb+        "ec2" -> pure EC2+        "ecs" -> pure Ecs+        "rds" -> pure RDS+        e -> fromTextError $ "Failure parsing ServiceNamespace from value: '" <> e+           <> "'. Accepted values: autoscaling, dynamodb, ec2, ecs, rds"++instance ToText ServiceNamespace where+    toText = \case+        Autoscaling -> "autoscaling"+        Dynamodb -> "dynamodb"+        EC2 -> "ec2"+        Ecs -> "ecs"+        RDS -> "rds"++instance Hashable     ServiceNamespace+instance NFData       ServiceNamespace+instance ToByteString ServiceNamespace+instance ToQuery      ServiceNamespace+instance ToHeader     ServiceNamespace++instance ToJSON ServiceNamespace where+    toJSON = toJSONText++instance FromJSON ServiceNamespace where+    parseJSON = parseJSONText "ServiceNamespace"
+ gen/Network/AWS/AutoScalingPlans/UpdateScalingPlan.hs view
@@ -0,0 +1,161 @@+{-# LANGUAGE DeriveDataTypeable #-}+{-# LANGUAGE DeriveGeneric      #-}+{-# LANGUAGE OverloadedStrings  #-}+{-# LANGUAGE RecordWildCards    #-}+{-# LANGUAGE TypeFamilies       #-}++{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-binds   #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module      : Network.AWS.AutoScalingPlans.UpdateScalingPlan+-- Copyright   : (c) 2013-2018 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)+--+-- Updates the scaling plan for the specified scaling plan.+--+--+-- You cannot update a scaling plan if it is in the process of being created, updated, or deleted.+--+module Network.AWS.AutoScalingPlans.UpdateScalingPlan+    (+    -- * Creating a Request+      updateScalingPlan+    , UpdateScalingPlan+    -- * Request Lenses+    , uspScalingInstructions+    , uspApplicationSource+    , uspScalingPlanName+    , uspScalingPlanVersion++    -- * Destructuring the Response+    , updateScalingPlanResponse+    , UpdateScalingPlanResponse+    -- * Response Lenses+    , usprsResponseStatus+    ) where++import Network.AWS.AutoScalingPlans.Types+import Network.AWS.AutoScalingPlans.Types.Product+import Network.AWS.Lens+import Network.AWS.Prelude+import Network.AWS.Request+import Network.AWS.Response++-- | /See:/ 'updateScalingPlan' smart constructor.+data UpdateScalingPlan = UpdateScalingPlan'+  { _uspScalingInstructions :: !(Maybe [ScalingInstruction])+  , _uspApplicationSource   :: !(Maybe ApplicationSource)+  , _uspScalingPlanName     :: !Text+  , _uspScalingPlanVersion  :: !Integer+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'UpdateScalingPlan' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'uspScalingInstructions' - The scaling instructions.+--+-- * 'uspApplicationSource' - A CloudFormation stack or set of tags.+--+-- * 'uspScalingPlanName' - The name of the scaling plan.+--+-- * 'uspScalingPlanVersion' - The version number.+updateScalingPlan+    :: Text -- ^ 'uspScalingPlanName'+    -> Integer -- ^ 'uspScalingPlanVersion'+    -> UpdateScalingPlan+updateScalingPlan pScalingPlanName_ pScalingPlanVersion_ =+  UpdateScalingPlan'+    { _uspScalingInstructions = Nothing+    , _uspApplicationSource = Nothing+    , _uspScalingPlanName = pScalingPlanName_+    , _uspScalingPlanVersion = pScalingPlanVersion_+    }+++-- | The scaling instructions.+uspScalingInstructions :: Lens' UpdateScalingPlan [ScalingInstruction]+uspScalingInstructions = lens _uspScalingInstructions (\ s a -> s{_uspScalingInstructions = a}) . _Default . _Coerce++-- | A CloudFormation stack or set of tags.+uspApplicationSource :: Lens' UpdateScalingPlan (Maybe ApplicationSource)+uspApplicationSource = lens _uspApplicationSource (\ s a -> s{_uspApplicationSource = a})++-- | The name of the scaling plan.+uspScalingPlanName :: Lens' UpdateScalingPlan Text+uspScalingPlanName = lens _uspScalingPlanName (\ s a -> s{_uspScalingPlanName = a})++-- | The version number.+uspScalingPlanVersion :: Lens' UpdateScalingPlan Integer+uspScalingPlanVersion = lens _uspScalingPlanVersion (\ s a -> s{_uspScalingPlanVersion = a})++instance AWSRequest UpdateScalingPlan where+        type Rs UpdateScalingPlan = UpdateScalingPlanResponse+        request = postJSON autoScalingPlans+        response+          = receiveEmpty+              (\ s h x ->+                 UpdateScalingPlanResponse' <$> (pure (fromEnum s)))++instance Hashable UpdateScalingPlan where++instance NFData UpdateScalingPlan where++instance ToHeaders UpdateScalingPlan where+        toHeaders+          = const+              (mconcat+                 ["X-Amz-Target" =#+                    ("AnyScaleScalingPlannerFrontendService.UpdateScalingPlan"+                       :: ByteString),+                  "Content-Type" =#+                    ("application/x-amz-json-1.1" :: ByteString)])++instance ToJSON UpdateScalingPlan where+        toJSON UpdateScalingPlan'{..}+          = object+              (catMaybes+                 [("ScalingInstructions" .=) <$>+                    _uspScalingInstructions,+                  ("ApplicationSource" .=) <$> _uspApplicationSource,+                  Just ("ScalingPlanName" .= _uspScalingPlanName),+                  Just+                    ("ScalingPlanVersion" .= _uspScalingPlanVersion)])++instance ToPath UpdateScalingPlan where+        toPath = const "/"++instance ToQuery UpdateScalingPlan where+        toQuery = const mempty++-- | /See:/ 'updateScalingPlanResponse' smart constructor.+newtype UpdateScalingPlanResponse = UpdateScalingPlanResponse'+  { _usprsResponseStatus :: Int+  } deriving (Eq, Read, Show, Data, Typeable, Generic)+++-- | Creates a value of 'UpdateScalingPlanResponse' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'usprsResponseStatus' - -- | The response status code.+updateScalingPlanResponse+    :: Int -- ^ 'usprsResponseStatus'+    -> UpdateScalingPlanResponse+updateScalingPlanResponse pResponseStatus_ =+  UpdateScalingPlanResponse' {_usprsResponseStatus = pResponseStatus_}+++-- | -- | The response status code.+usprsResponseStatus :: Lens' UpdateScalingPlanResponse Int+usprsResponseStatus = lens _usprsResponseStatus (\ s a -> s{_usprsResponseStatus = a})++instance NFData UpdateScalingPlanResponse where
+ gen/Network/AWS/AutoScalingPlans/Waiters.hs view
@@ -0,0 +1,21 @@+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE TypeFamilies      #-}++{-# OPTIONS_GHC -fno-warn-unused-imports #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module      : Network.AWS.AutoScalingPlans.Waiters+-- Copyright   : (c) 2013-2018 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 Network.AWS.AutoScalingPlans.Waiters where++import Network.AWS.AutoScalingPlans.Types+import Network.AWS.Lens+import Network.AWS.Prelude+import Network.AWS.Waiter
+ src/.gitkeep view
+ test/Main.hs view
@@ -0,0 +1,21 @@+{-# OPTIONS_GHC -fno-warn-unused-imports #-}++-- |+-- Module      : Main+-- Copyright   : (c) 2013-2018 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 Main (main) where++import Test.Tasty+import Test.AWS.AutoScalingPlans+import Test.AWS.AutoScalingPlans.Internal++main :: IO ()+main = defaultMain $ testGroup "AutoScalingPlans"+    [ testGroup "tests"    tests+    , testGroup "fixtures" fixtures+    ]
+ test/Test/AWS/AutoScalingPlans.hs view
@@ -0,0 +1,20 @@+-- |+-- Module      : Test.AWS.AutoScalingPlans+-- Copyright   : (c) 2013-2018 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 Test.AWS.AutoScalingPlans+    ( tests+    , fixtures+    ) where++import Test.Tasty (TestTree)++tests :: [TestTree]+tests = []++fixtures :: [TestTree]+fixtures = []
+ test/Test/AWS/AutoScalingPlans/Internal.hs view
@@ -0,0 +1,9 @@+-- |+-- Module      : Test.AWS.AutoScalingPlans.Internal+-- Copyright   : (c) 2013-2018 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 Test.AWS.AutoScalingPlans.Internal where
+ test/Test/AWS/Gen/AutoScalingPlans.hs view
@@ -0,0 +1,129 @@+{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-orphans        #-}++-- Derived from AWS service descriptions, licensed under Apache 2.0.++-- |+-- Module      : Test.AWS.Gen.AutoScalingPlans+-- Copyright   : (c) 2013-2018 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 Test.AWS.Gen.AutoScalingPlans where++import Data.Proxy+import Network.AWS.AutoScalingPlans+import Test.AWS.AutoScalingPlans.Internal+import Test.AWS.Fixture+import Test.AWS.Prelude+import Test.Tasty++-- Auto-generated: the actual test selection needs to be manually placed into+-- the top-level so that real test data can be incrementally added.+--+-- This commented snippet is what the entire set should look like:++-- fixtures :: TestTree+-- fixtures =+--     [ testGroup "request"+--         [ requestDescribeScalingPlanResources $+--             describeScalingPlanResources+--+--         , requestCreateScalingPlan $+--             createScalingPlan+--+--         , requestDeleteScalingPlan $+--             deleteScalingPlan+--+--         , requestUpdateScalingPlan $+--             updateScalingPlan+--+--         , requestDescribeScalingPlans $+--             describeScalingPlans+--+--           ]++--     , testGroup "response"+--         [ responseDescribeScalingPlanResources $+--             describeScalingPlanResourcesResponse+--+--         , responseCreateScalingPlan $+--             createScalingPlanResponse+--+--         , responseDeleteScalingPlan $+--             deleteScalingPlanResponse+--+--         , responseUpdateScalingPlan $+--             updateScalingPlanResponse+--+--         , responseDescribeScalingPlans $+--             describeScalingPlansResponse+--+--           ]+--     ]++-- Requests++requestDescribeScalingPlanResources :: DescribeScalingPlanResources -> TestTree+requestDescribeScalingPlanResources = req+    "DescribeScalingPlanResources"+    "fixture/DescribeScalingPlanResources.yaml"++requestCreateScalingPlan :: CreateScalingPlan -> TestTree+requestCreateScalingPlan = req+    "CreateScalingPlan"+    "fixture/CreateScalingPlan.yaml"++requestDeleteScalingPlan :: DeleteScalingPlan -> TestTree+requestDeleteScalingPlan = req+    "DeleteScalingPlan"+    "fixture/DeleteScalingPlan.yaml"++requestUpdateScalingPlan :: UpdateScalingPlan -> TestTree+requestUpdateScalingPlan = req+    "UpdateScalingPlan"+    "fixture/UpdateScalingPlan.yaml"++requestDescribeScalingPlans :: DescribeScalingPlans -> TestTree+requestDescribeScalingPlans = req+    "DescribeScalingPlans"+    "fixture/DescribeScalingPlans.yaml"++-- Responses++responseDescribeScalingPlanResources :: DescribeScalingPlanResourcesResponse -> TestTree+responseDescribeScalingPlanResources = res+    "DescribeScalingPlanResourcesResponse"+    "fixture/DescribeScalingPlanResourcesResponse.proto"+    autoScalingPlans+    (Proxy :: Proxy DescribeScalingPlanResources)++responseCreateScalingPlan :: CreateScalingPlanResponse -> TestTree+responseCreateScalingPlan = res+    "CreateScalingPlanResponse"+    "fixture/CreateScalingPlanResponse.proto"+    autoScalingPlans+    (Proxy :: Proxy CreateScalingPlan)++responseDeleteScalingPlan :: DeleteScalingPlanResponse -> TestTree+responseDeleteScalingPlan = res+    "DeleteScalingPlanResponse"+    "fixture/DeleteScalingPlanResponse.proto"+    autoScalingPlans+    (Proxy :: Proxy DeleteScalingPlan)++responseUpdateScalingPlan :: UpdateScalingPlanResponse -> TestTree+responseUpdateScalingPlan = res+    "UpdateScalingPlanResponse"+    "fixture/UpdateScalingPlanResponse.proto"+    autoScalingPlans+    (Proxy :: Proxy UpdateScalingPlan)++responseDescribeScalingPlans :: DescribeScalingPlansResponse -> TestTree+responseDescribeScalingPlans = res+    "DescribeScalingPlansResponse"+    "fixture/DescribeScalingPlansResponse.proto"+    autoScalingPlans+    (Proxy :: Proxy DescribeScalingPlans)