1// Code generated by private/model/cli/gen-api/main.go. DO NOT EDIT.
2
3package autoscalingplans
4
5import (
6	"fmt"
7	"time"
8
9	"github.com/aws/aws-sdk-go/aws"
10	"github.com/aws/aws-sdk-go/aws/awsutil"
11	"github.com/aws/aws-sdk-go/aws/request"
12	"github.com/aws/aws-sdk-go/private/protocol"
13	"github.com/aws/aws-sdk-go/private/protocol/jsonrpc"
14)
15
16const opCreateScalingPlan = "CreateScalingPlan"
17
18// CreateScalingPlanRequest generates a "aws/request.Request" representing the
19// client's request for the CreateScalingPlan operation. The "output" return
20// value will be populated with the request's response once the request completes
21// successfully.
22//
23// Use "Send" method on the returned Request to send the API call to the service.
24// the "output" return value is not valid until after Send returns without error.
25//
26// See CreateScalingPlan for more information on using the CreateScalingPlan
27// API call, and error handling.
28//
29// This method is useful when you want to inject custom logic or configuration
30// into the SDK's request lifecycle. Such as custom headers, or retry logic.
31//
32//
33//    // Example sending a request using the CreateScalingPlanRequest method.
34//    req, resp := client.CreateScalingPlanRequest(params)
35//
36//    err := req.Send()
37//    if err == nil { // resp is now filled
38//        fmt.Println(resp)
39//    }
40//
41// See also, https://docs.aws.amazon.com/goto/WebAPI/autoscaling-plans-2018-01-06/CreateScalingPlan
42func (c *AutoScalingPlans) CreateScalingPlanRequest(input *CreateScalingPlanInput) (req *request.Request, output *CreateScalingPlanOutput) {
43	op := &request.Operation{
44		Name:       opCreateScalingPlan,
45		HTTPMethod: "POST",
46		HTTPPath:   "/",
47	}
48
49	if input == nil {
50		input = &CreateScalingPlanInput{}
51	}
52
53	output = &CreateScalingPlanOutput{}
54	req = c.newRequest(op, input, output)
55	return
56}
57
58// CreateScalingPlan API operation for AWS Auto Scaling Plans.
59//
60// Creates a scaling plan.
61//
62// Returns awserr.Error for service API and SDK errors. Use runtime type assertions
63// with awserr.Error's Code and Message methods to get detailed information about
64// the error.
65//
66// See the AWS API reference guide for AWS Auto Scaling Plans's
67// API operation CreateScalingPlan for usage and error information.
68//
69// Returned Error Codes:
70//   * ErrCodeValidationException "ValidationException"
71//   An exception was thrown for a validation issue. Review the parameters provided.
72//
73//   * ErrCodeLimitExceededException "LimitExceededException"
74//   Your account exceeded a limit. This exception is thrown when a per-account
75//   resource limit is exceeded.
76//
77//   * ErrCodeConcurrentUpdateException "ConcurrentUpdateException"
78//   Concurrent updates caused an exception, for example, if you request an update
79//   to a scaling plan that already has a pending update.
80//
81//   * ErrCodeInternalServiceException "InternalServiceException"
82//   The service encountered an internal error.
83//
84// See also, https://docs.aws.amazon.com/goto/WebAPI/autoscaling-plans-2018-01-06/CreateScalingPlan
85func (c *AutoScalingPlans) CreateScalingPlan(input *CreateScalingPlanInput) (*CreateScalingPlanOutput, error) {
86	req, out := c.CreateScalingPlanRequest(input)
87	return out, req.Send()
88}
89
90// CreateScalingPlanWithContext is the same as CreateScalingPlan with the addition of
91// the ability to pass a context and additional request options.
92//
93// See CreateScalingPlan for details on how to use this API operation.
94//
95// The context must be non-nil and will be used for request cancellation. If
96// the context is nil a panic will occur. In the future the SDK may create
97// sub-contexts for http.Requests. See https://golang.org/pkg/context/
98// for more information on using Contexts.
99func (c *AutoScalingPlans) CreateScalingPlanWithContext(ctx aws.Context, input *CreateScalingPlanInput, opts ...request.Option) (*CreateScalingPlanOutput, error) {
100	req, out := c.CreateScalingPlanRequest(input)
101	req.SetContext(ctx)
102	req.ApplyOptions(opts...)
103	return out, req.Send()
104}
105
106const opDeleteScalingPlan = "DeleteScalingPlan"
107
108// DeleteScalingPlanRequest generates a "aws/request.Request" representing the
109// client's request for the DeleteScalingPlan operation. The "output" return
110// value will be populated with the request's response once the request completes
111// successfully.
112//
113// Use "Send" method on the returned Request to send the API call to the service.
114// the "output" return value is not valid until after Send returns without error.
115//
116// See DeleteScalingPlan for more information on using the DeleteScalingPlan
117// API call, and error handling.
118//
119// This method is useful when you want to inject custom logic or configuration
120// into the SDK's request lifecycle. Such as custom headers, or retry logic.
121//
122//
123//    // Example sending a request using the DeleteScalingPlanRequest method.
124//    req, resp := client.DeleteScalingPlanRequest(params)
125//
126//    err := req.Send()
127//    if err == nil { // resp is now filled
128//        fmt.Println(resp)
129//    }
130//
131// See also, https://docs.aws.amazon.com/goto/WebAPI/autoscaling-plans-2018-01-06/DeleteScalingPlan
132func (c *AutoScalingPlans) DeleteScalingPlanRequest(input *DeleteScalingPlanInput) (req *request.Request, output *DeleteScalingPlanOutput) {
133	op := &request.Operation{
134		Name:       opDeleteScalingPlan,
135		HTTPMethod: "POST",
136		HTTPPath:   "/",
137	}
138
139	if input == nil {
140		input = &DeleteScalingPlanInput{}
141	}
142
143	output = &DeleteScalingPlanOutput{}
144	req = c.newRequest(op, input, output)
145	req.Handlers.Unmarshal.Swap(jsonrpc.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler)
146	return
147}
148
149// DeleteScalingPlan API operation for AWS Auto Scaling Plans.
150//
151// Deletes the specified scaling plan.
152//
153// Deleting a scaling plan deletes the underlying ScalingInstruction for all
154// of the scalable resources that are covered by the plan.
155//
156// If the plan has launched resources or has scaling activities in progress,
157// you must delete those resources separately.
158//
159// Returns awserr.Error for service API and SDK errors. Use runtime type assertions
160// with awserr.Error's Code and Message methods to get detailed information about
161// the error.
162//
163// See the AWS API reference guide for AWS Auto Scaling Plans's
164// API operation DeleteScalingPlan for usage and error information.
165//
166// Returned Error Codes:
167//   * ErrCodeValidationException "ValidationException"
168//   An exception was thrown for a validation issue. Review the parameters provided.
169//
170//   * ErrCodeObjectNotFoundException "ObjectNotFoundException"
171//   The specified object could not be found.
172//
173//   * ErrCodeConcurrentUpdateException "ConcurrentUpdateException"
174//   Concurrent updates caused an exception, for example, if you request an update
175//   to a scaling plan that already has a pending update.
176//
177//   * ErrCodeInternalServiceException "InternalServiceException"
178//   The service encountered an internal error.
179//
180// See also, https://docs.aws.amazon.com/goto/WebAPI/autoscaling-plans-2018-01-06/DeleteScalingPlan
181func (c *AutoScalingPlans) DeleteScalingPlan(input *DeleteScalingPlanInput) (*DeleteScalingPlanOutput, error) {
182	req, out := c.DeleteScalingPlanRequest(input)
183	return out, req.Send()
184}
185
186// DeleteScalingPlanWithContext is the same as DeleteScalingPlan with the addition of
187// the ability to pass a context and additional request options.
188//
189// See DeleteScalingPlan for details on how to use this API operation.
190//
191// The context must be non-nil and will be used for request cancellation. If
192// the context is nil a panic will occur. In the future the SDK may create
193// sub-contexts for http.Requests. See https://golang.org/pkg/context/
194// for more information on using Contexts.
195func (c *AutoScalingPlans) DeleteScalingPlanWithContext(ctx aws.Context, input *DeleteScalingPlanInput, opts ...request.Option) (*DeleteScalingPlanOutput, error) {
196	req, out := c.DeleteScalingPlanRequest(input)
197	req.SetContext(ctx)
198	req.ApplyOptions(opts...)
199	return out, req.Send()
200}
201
202const opDescribeScalingPlanResources = "DescribeScalingPlanResources"
203
204// DescribeScalingPlanResourcesRequest generates a "aws/request.Request" representing the
205// client's request for the DescribeScalingPlanResources operation. The "output" return
206// value will be populated with the request's response once the request completes
207// successfully.
208//
209// Use "Send" method on the returned Request to send the API call to the service.
210// the "output" return value is not valid until after Send returns without error.
211//
212// See DescribeScalingPlanResources for more information on using the DescribeScalingPlanResources
213// API call, and error handling.
214//
215// This method is useful when you want to inject custom logic or configuration
216// into the SDK's request lifecycle. Such as custom headers, or retry logic.
217//
218//
219//    // Example sending a request using the DescribeScalingPlanResourcesRequest method.
220//    req, resp := client.DescribeScalingPlanResourcesRequest(params)
221//
222//    err := req.Send()
223//    if err == nil { // resp is now filled
224//        fmt.Println(resp)
225//    }
226//
227// See also, https://docs.aws.amazon.com/goto/WebAPI/autoscaling-plans-2018-01-06/DescribeScalingPlanResources
228func (c *AutoScalingPlans) DescribeScalingPlanResourcesRequest(input *DescribeScalingPlanResourcesInput) (req *request.Request, output *DescribeScalingPlanResourcesOutput) {
229	op := &request.Operation{
230		Name:       opDescribeScalingPlanResources,
231		HTTPMethod: "POST",
232		HTTPPath:   "/",
233	}
234
235	if input == nil {
236		input = &DescribeScalingPlanResourcesInput{}
237	}
238
239	output = &DescribeScalingPlanResourcesOutput{}
240	req = c.newRequest(op, input, output)
241	return
242}
243
244// DescribeScalingPlanResources API operation for AWS Auto Scaling Plans.
245//
246// Describes the scalable resources in the specified scaling plan.
247//
248// Returns awserr.Error for service API and SDK errors. Use runtime type assertions
249// with awserr.Error's Code and Message methods to get detailed information about
250// the error.
251//
252// See the AWS API reference guide for AWS Auto Scaling Plans's
253// API operation DescribeScalingPlanResources for usage and error information.
254//
255// Returned Error Codes:
256//   * ErrCodeValidationException "ValidationException"
257//   An exception was thrown for a validation issue. Review the parameters provided.
258//
259//   * ErrCodeInvalidNextTokenException "InvalidNextTokenException"
260//   The token provided is not valid.
261//
262//   * ErrCodeConcurrentUpdateException "ConcurrentUpdateException"
263//   Concurrent updates caused an exception, for example, if you request an update
264//   to a scaling plan that already has a pending update.
265//
266//   * ErrCodeInternalServiceException "InternalServiceException"
267//   The service encountered an internal error.
268//
269// See also, https://docs.aws.amazon.com/goto/WebAPI/autoscaling-plans-2018-01-06/DescribeScalingPlanResources
270func (c *AutoScalingPlans) DescribeScalingPlanResources(input *DescribeScalingPlanResourcesInput) (*DescribeScalingPlanResourcesOutput, error) {
271	req, out := c.DescribeScalingPlanResourcesRequest(input)
272	return out, req.Send()
273}
274
275// DescribeScalingPlanResourcesWithContext is the same as DescribeScalingPlanResources with the addition of
276// the ability to pass a context and additional request options.
277//
278// See DescribeScalingPlanResources for details on how to use this API operation.
279//
280// The context must be non-nil and will be used for request cancellation. If
281// the context is nil a panic will occur. In the future the SDK may create
282// sub-contexts for http.Requests. See https://golang.org/pkg/context/
283// for more information on using Contexts.
284func (c *AutoScalingPlans) DescribeScalingPlanResourcesWithContext(ctx aws.Context, input *DescribeScalingPlanResourcesInput, opts ...request.Option) (*DescribeScalingPlanResourcesOutput, error) {
285	req, out := c.DescribeScalingPlanResourcesRequest(input)
286	req.SetContext(ctx)
287	req.ApplyOptions(opts...)
288	return out, req.Send()
289}
290
291const opDescribeScalingPlans = "DescribeScalingPlans"
292
293// DescribeScalingPlansRequest generates a "aws/request.Request" representing the
294// client's request for the DescribeScalingPlans operation. The "output" return
295// value will be populated with the request's response once the request completes
296// successfully.
297//
298// Use "Send" method on the returned Request to send the API call to the service.
299// the "output" return value is not valid until after Send returns without error.
300//
301// See DescribeScalingPlans for more information on using the DescribeScalingPlans
302// API call, and error handling.
303//
304// This method is useful when you want to inject custom logic or configuration
305// into the SDK's request lifecycle. Such as custom headers, or retry logic.
306//
307//
308//    // Example sending a request using the DescribeScalingPlansRequest method.
309//    req, resp := client.DescribeScalingPlansRequest(params)
310//
311//    err := req.Send()
312//    if err == nil { // resp is now filled
313//        fmt.Println(resp)
314//    }
315//
316// See also, https://docs.aws.amazon.com/goto/WebAPI/autoscaling-plans-2018-01-06/DescribeScalingPlans
317func (c *AutoScalingPlans) DescribeScalingPlansRequest(input *DescribeScalingPlansInput) (req *request.Request, output *DescribeScalingPlansOutput) {
318	op := &request.Operation{
319		Name:       opDescribeScalingPlans,
320		HTTPMethod: "POST",
321		HTTPPath:   "/",
322	}
323
324	if input == nil {
325		input = &DescribeScalingPlansInput{}
326	}
327
328	output = &DescribeScalingPlansOutput{}
329	req = c.newRequest(op, input, output)
330	return
331}
332
333// DescribeScalingPlans API operation for AWS Auto Scaling Plans.
334//
335// Describes one or more of your scaling plans.
336//
337// Returns awserr.Error for service API and SDK errors. Use runtime type assertions
338// with awserr.Error's Code and Message methods to get detailed information about
339// the error.
340//
341// See the AWS API reference guide for AWS Auto Scaling Plans's
342// API operation DescribeScalingPlans for usage and error information.
343//
344// Returned Error Codes:
345//   * ErrCodeValidationException "ValidationException"
346//   An exception was thrown for a validation issue. Review the parameters provided.
347//
348//   * ErrCodeInvalidNextTokenException "InvalidNextTokenException"
349//   The token provided is not valid.
350//
351//   * ErrCodeConcurrentUpdateException "ConcurrentUpdateException"
352//   Concurrent updates caused an exception, for example, if you request an update
353//   to a scaling plan that already has a pending update.
354//
355//   * ErrCodeInternalServiceException "InternalServiceException"
356//   The service encountered an internal error.
357//
358// See also, https://docs.aws.amazon.com/goto/WebAPI/autoscaling-plans-2018-01-06/DescribeScalingPlans
359func (c *AutoScalingPlans) DescribeScalingPlans(input *DescribeScalingPlansInput) (*DescribeScalingPlansOutput, error) {
360	req, out := c.DescribeScalingPlansRequest(input)
361	return out, req.Send()
362}
363
364// DescribeScalingPlansWithContext is the same as DescribeScalingPlans with the addition of
365// the ability to pass a context and additional request options.
366//
367// See DescribeScalingPlans for details on how to use this API operation.
368//
369// The context must be non-nil and will be used for request cancellation. If
370// the context is nil a panic will occur. In the future the SDK may create
371// sub-contexts for http.Requests. See https://golang.org/pkg/context/
372// for more information on using Contexts.
373func (c *AutoScalingPlans) DescribeScalingPlansWithContext(ctx aws.Context, input *DescribeScalingPlansInput, opts ...request.Option) (*DescribeScalingPlansOutput, error) {
374	req, out := c.DescribeScalingPlansRequest(input)
375	req.SetContext(ctx)
376	req.ApplyOptions(opts...)
377	return out, req.Send()
378}
379
380const opGetScalingPlanResourceForecastData = "GetScalingPlanResourceForecastData"
381
382// GetScalingPlanResourceForecastDataRequest generates a "aws/request.Request" representing the
383// client's request for the GetScalingPlanResourceForecastData operation. The "output" return
384// value will be populated with the request's response once the request completes
385// successfully.
386//
387// Use "Send" method on the returned Request to send the API call to the service.
388// the "output" return value is not valid until after Send returns without error.
389//
390// See GetScalingPlanResourceForecastData for more information on using the GetScalingPlanResourceForecastData
391// API call, and error handling.
392//
393// This method is useful when you want to inject custom logic or configuration
394// into the SDK's request lifecycle. Such as custom headers, or retry logic.
395//
396//
397//    // Example sending a request using the GetScalingPlanResourceForecastDataRequest method.
398//    req, resp := client.GetScalingPlanResourceForecastDataRequest(params)
399//
400//    err := req.Send()
401//    if err == nil { // resp is now filled
402//        fmt.Println(resp)
403//    }
404//
405// See also, https://docs.aws.amazon.com/goto/WebAPI/autoscaling-plans-2018-01-06/GetScalingPlanResourceForecastData
406func (c *AutoScalingPlans) GetScalingPlanResourceForecastDataRequest(input *GetScalingPlanResourceForecastDataInput) (req *request.Request, output *GetScalingPlanResourceForecastDataOutput) {
407	op := &request.Operation{
408		Name:       opGetScalingPlanResourceForecastData,
409		HTTPMethod: "POST",
410		HTTPPath:   "/",
411	}
412
413	if input == nil {
414		input = &GetScalingPlanResourceForecastDataInput{}
415	}
416
417	output = &GetScalingPlanResourceForecastDataOutput{}
418	req = c.newRequest(op, input, output)
419	return
420}
421
422// GetScalingPlanResourceForecastData API operation for AWS Auto Scaling Plans.
423//
424// Retrieves the forecast data for a scalable resource.
425//
426// Capacity forecasts are represented as predicted values, or data points, that
427// are calculated using historical data points from a specified CloudWatch load
428// metric. Data points are available for up to 56 days.
429//
430// Returns awserr.Error for service API and SDK errors. Use runtime type assertions
431// with awserr.Error's Code and Message methods to get detailed information about
432// the error.
433//
434// See the AWS API reference guide for AWS Auto Scaling Plans's
435// API operation GetScalingPlanResourceForecastData for usage and error information.
436//
437// Returned Error Codes:
438//   * ErrCodeValidationException "ValidationException"
439//   An exception was thrown for a validation issue. Review the parameters provided.
440//
441//   * ErrCodeInternalServiceException "InternalServiceException"
442//   The service encountered an internal error.
443//
444// See also, https://docs.aws.amazon.com/goto/WebAPI/autoscaling-plans-2018-01-06/GetScalingPlanResourceForecastData
445func (c *AutoScalingPlans) GetScalingPlanResourceForecastData(input *GetScalingPlanResourceForecastDataInput) (*GetScalingPlanResourceForecastDataOutput, error) {
446	req, out := c.GetScalingPlanResourceForecastDataRequest(input)
447	return out, req.Send()
448}
449
450// GetScalingPlanResourceForecastDataWithContext is the same as GetScalingPlanResourceForecastData with the addition of
451// the ability to pass a context and additional request options.
452//
453// See GetScalingPlanResourceForecastData for details on how to use this API operation.
454//
455// The context must be non-nil and will be used for request cancellation. If
456// the context is nil a panic will occur. In the future the SDK may create
457// sub-contexts for http.Requests. See https://golang.org/pkg/context/
458// for more information on using Contexts.
459func (c *AutoScalingPlans) GetScalingPlanResourceForecastDataWithContext(ctx aws.Context, input *GetScalingPlanResourceForecastDataInput, opts ...request.Option) (*GetScalingPlanResourceForecastDataOutput, error) {
460	req, out := c.GetScalingPlanResourceForecastDataRequest(input)
461	req.SetContext(ctx)
462	req.ApplyOptions(opts...)
463	return out, req.Send()
464}
465
466const opUpdateScalingPlan = "UpdateScalingPlan"
467
468// UpdateScalingPlanRequest generates a "aws/request.Request" representing the
469// client's request for the UpdateScalingPlan operation. The "output" return
470// value will be populated with the request's response once the request completes
471// successfully.
472//
473// Use "Send" method on the returned Request to send the API call to the service.
474// the "output" return value is not valid until after Send returns without error.
475//
476// See UpdateScalingPlan for more information on using the UpdateScalingPlan
477// API call, and error handling.
478//
479// This method is useful when you want to inject custom logic or configuration
480// into the SDK's request lifecycle. Such as custom headers, or retry logic.
481//
482//
483//    // Example sending a request using the UpdateScalingPlanRequest method.
484//    req, resp := client.UpdateScalingPlanRequest(params)
485//
486//    err := req.Send()
487//    if err == nil { // resp is now filled
488//        fmt.Println(resp)
489//    }
490//
491// See also, https://docs.aws.amazon.com/goto/WebAPI/autoscaling-plans-2018-01-06/UpdateScalingPlan
492func (c *AutoScalingPlans) UpdateScalingPlanRequest(input *UpdateScalingPlanInput) (req *request.Request, output *UpdateScalingPlanOutput) {
493	op := &request.Operation{
494		Name:       opUpdateScalingPlan,
495		HTTPMethod: "POST",
496		HTTPPath:   "/",
497	}
498
499	if input == nil {
500		input = &UpdateScalingPlanInput{}
501	}
502
503	output = &UpdateScalingPlanOutput{}
504	req = c.newRequest(op, input, output)
505	req.Handlers.Unmarshal.Swap(jsonrpc.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler)
506	return
507}
508
509// UpdateScalingPlan API operation for AWS Auto Scaling Plans.
510//
511// Updates the specified scaling plan.
512//
513// You cannot update a scaling plan if it is in the process of being created,
514// updated, or deleted.
515//
516// Returns awserr.Error for service API and SDK errors. Use runtime type assertions
517// with awserr.Error's Code and Message methods to get detailed information about
518// the error.
519//
520// See the AWS API reference guide for AWS Auto Scaling Plans's
521// API operation UpdateScalingPlan for usage and error information.
522//
523// Returned Error Codes:
524//   * ErrCodeValidationException "ValidationException"
525//   An exception was thrown for a validation issue. Review the parameters provided.
526//
527//   * ErrCodeConcurrentUpdateException "ConcurrentUpdateException"
528//   Concurrent updates caused an exception, for example, if you request an update
529//   to a scaling plan that already has a pending update.
530//
531//   * ErrCodeInternalServiceException "InternalServiceException"
532//   The service encountered an internal error.
533//
534//   * ErrCodeObjectNotFoundException "ObjectNotFoundException"
535//   The specified object could not be found.
536//
537// See also, https://docs.aws.amazon.com/goto/WebAPI/autoscaling-plans-2018-01-06/UpdateScalingPlan
538func (c *AutoScalingPlans) UpdateScalingPlan(input *UpdateScalingPlanInput) (*UpdateScalingPlanOutput, error) {
539	req, out := c.UpdateScalingPlanRequest(input)
540	return out, req.Send()
541}
542
543// UpdateScalingPlanWithContext is the same as UpdateScalingPlan with the addition of
544// the ability to pass a context and additional request options.
545//
546// See UpdateScalingPlan for details on how to use this API operation.
547//
548// The context must be non-nil and will be used for request cancellation. If
549// the context is nil a panic will occur. In the future the SDK may create
550// sub-contexts for http.Requests. See https://golang.org/pkg/context/
551// for more information on using Contexts.
552func (c *AutoScalingPlans) UpdateScalingPlanWithContext(ctx aws.Context, input *UpdateScalingPlanInput, opts ...request.Option) (*UpdateScalingPlanOutput, error) {
553	req, out := c.UpdateScalingPlanRequest(input)
554	req.SetContext(ctx)
555	req.ApplyOptions(opts...)
556	return out, req.Send()
557}
558
559// Represents an application source.
560type ApplicationSource struct {
561	_ struct{} `type:"structure"`
562
563	// The Amazon Resource Name (ARN) of a AWS CloudFormation stack.
564	CloudFormationStackARN *string `type:"string"`
565
566	// A set of tags (up to 50).
567	TagFilters []*TagFilter `type:"list"`
568}
569
570// String returns the string representation
571func (s ApplicationSource) String() string {
572	return awsutil.Prettify(s)
573}
574
575// GoString returns the string representation
576func (s ApplicationSource) GoString() string {
577	return s.String()
578}
579
580// Validate inspects the fields of the type to determine if they are valid.
581func (s *ApplicationSource) Validate() error {
582	invalidParams := request.ErrInvalidParams{Context: "ApplicationSource"}
583	if s.TagFilters != nil {
584		for i, v := range s.TagFilters {
585			if v == nil {
586				continue
587			}
588			if err := v.Validate(); err != nil {
589				invalidParams.AddNested(fmt.Sprintf("%s[%v]", "TagFilters", i), err.(request.ErrInvalidParams))
590			}
591		}
592	}
593
594	if invalidParams.Len() > 0 {
595		return invalidParams
596	}
597	return nil
598}
599
600// SetCloudFormationStackARN sets the CloudFormationStackARN field's value.
601func (s *ApplicationSource) SetCloudFormationStackARN(v string) *ApplicationSource {
602	s.CloudFormationStackARN = &v
603	return s
604}
605
606// SetTagFilters sets the TagFilters field's value.
607func (s *ApplicationSource) SetTagFilters(v []*TagFilter) *ApplicationSource {
608	s.TagFilters = v
609	return s
610}
611
612type CreateScalingPlanInput struct {
613	_ struct{} `type:"structure"`
614
615	// A CloudFormation stack or set of tags. You can create one scaling plan per
616	// application source.
617	//
618	// ApplicationSource is a required field
619	ApplicationSource *ApplicationSource `type:"structure" required:"true"`
620
621	// The scaling instructions.
622	//
623	// ScalingInstructions is a required field
624	ScalingInstructions []*ScalingInstruction `type:"list" required:"true"`
625
626	// The name of the scaling plan. Names cannot contain vertical bars, colons,
627	// or forward slashes.
628	//
629	// ScalingPlanName is a required field
630	ScalingPlanName *string `min:"1" type:"string" required:"true"`
631}
632
633// String returns the string representation
634func (s CreateScalingPlanInput) String() string {
635	return awsutil.Prettify(s)
636}
637
638// GoString returns the string representation
639func (s CreateScalingPlanInput) GoString() string {
640	return s.String()
641}
642
643// Validate inspects the fields of the type to determine if they are valid.
644func (s *CreateScalingPlanInput) Validate() error {
645	invalidParams := request.ErrInvalidParams{Context: "CreateScalingPlanInput"}
646	if s.ApplicationSource == nil {
647		invalidParams.Add(request.NewErrParamRequired("ApplicationSource"))
648	}
649	if s.ScalingInstructions == nil {
650		invalidParams.Add(request.NewErrParamRequired("ScalingInstructions"))
651	}
652	if s.ScalingPlanName == nil {
653		invalidParams.Add(request.NewErrParamRequired("ScalingPlanName"))
654	}
655	if s.ScalingPlanName != nil && len(*s.ScalingPlanName) < 1 {
656		invalidParams.Add(request.NewErrParamMinLen("ScalingPlanName", 1))
657	}
658	if s.ApplicationSource != nil {
659		if err := s.ApplicationSource.Validate(); err != nil {
660			invalidParams.AddNested("ApplicationSource", err.(request.ErrInvalidParams))
661		}
662	}
663	if s.ScalingInstructions != nil {
664		for i, v := range s.ScalingInstructions {
665			if v == nil {
666				continue
667			}
668			if err := v.Validate(); err != nil {
669				invalidParams.AddNested(fmt.Sprintf("%s[%v]", "ScalingInstructions", i), err.(request.ErrInvalidParams))
670			}
671		}
672	}
673
674	if invalidParams.Len() > 0 {
675		return invalidParams
676	}
677	return nil
678}
679
680// SetApplicationSource sets the ApplicationSource field's value.
681func (s *CreateScalingPlanInput) SetApplicationSource(v *ApplicationSource) *CreateScalingPlanInput {
682	s.ApplicationSource = v
683	return s
684}
685
686// SetScalingInstructions sets the ScalingInstructions field's value.
687func (s *CreateScalingPlanInput) SetScalingInstructions(v []*ScalingInstruction) *CreateScalingPlanInput {
688	s.ScalingInstructions = v
689	return s
690}
691
692// SetScalingPlanName sets the ScalingPlanName field's value.
693func (s *CreateScalingPlanInput) SetScalingPlanName(v string) *CreateScalingPlanInput {
694	s.ScalingPlanName = &v
695	return s
696}
697
698type CreateScalingPlanOutput struct {
699	_ struct{} `type:"structure"`
700
701	// The version number of the scaling plan. This value is always 1.
702	//
703	// Currently, you cannot specify multiple scaling plan versions.
704	//
705	// ScalingPlanVersion is a required field
706	ScalingPlanVersion *int64 `type:"long" required:"true"`
707}
708
709// String returns the string representation
710func (s CreateScalingPlanOutput) String() string {
711	return awsutil.Prettify(s)
712}
713
714// GoString returns the string representation
715func (s CreateScalingPlanOutput) GoString() string {
716	return s.String()
717}
718
719// SetScalingPlanVersion sets the ScalingPlanVersion field's value.
720func (s *CreateScalingPlanOutput) SetScalingPlanVersion(v int64) *CreateScalingPlanOutput {
721	s.ScalingPlanVersion = &v
722	return s
723}
724
725// Represents a CloudWatch metric of your choosing that can be used for predictive
726// scaling.
727//
728// For predictive scaling to work with a customized load metric specification,
729// AWS Auto Scaling needs access to the Sum and Average statistics that CloudWatch
730// computes from metric data. Statistics are calculations used to aggregate
731// data over specified time periods.
732//
733// When you choose a load metric, make sure that the required Sum and Average
734// statistics for your metric are available in CloudWatch and that they provide
735// relevant data for predictive scaling. The Sum statistic must represent the
736// total load on the resource, and the Average statistic must represent the
737// average load per capacity unit of the resource. For example, there is a metric
738// that counts the number of requests processed by your Auto Scaling group.
739// If the Sum statistic represents the total request count processed by the
740// group, then the Average statistic for the specified metric must represent
741// the average request count processed by each instance of the group.
742//
743// For information about terminology, available metrics, or how to publish new
744// metrics, see Amazon CloudWatch Concepts (https://docs.aws.amazon.com/AmazonCloudWatch/latest/monitoring/cloudwatch_concepts.html)
745// in the Amazon CloudWatch User Guide.
746type CustomizedLoadMetricSpecification struct {
747	_ struct{} `type:"structure"`
748
749	// The dimensions of the metric.
750	//
751	// Conditional: If you published your metric with dimensions, you must specify
752	// the same dimensions in your customized load metric specification.
753	Dimensions []*MetricDimension `type:"list"`
754
755	// The name of the metric.
756	//
757	// MetricName is a required field
758	MetricName *string `type:"string" required:"true"`
759
760	// The namespace of the metric.
761	//
762	// Namespace is a required field
763	Namespace *string `type:"string" required:"true"`
764
765	// The statistic of the metric. Currently, the value must always be Sum.
766	//
767	// Statistic is a required field
768	Statistic *string `type:"string" required:"true" enum:"MetricStatistic"`
769
770	// The unit of the metric.
771	Unit *string `type:"string"`
772}
773
774// String returns the string representation
775func (s CustomizedLoadMetricSpecification) String() string {
776	return awsutil.Prettify(s)
777}
778
779// GoString returns the string representation
780func (s CustomizedLoadMetricSpecification) GoString() string {
781	return s.String()
782}
783
784// Validate inspects the fields of the type to determine if they are valid.
785func (s *CustomizedLoadMetricSpecification) Validate() error {
786	invalidParams := request.ErrInvalidParams{Context: "CustomizedLoadMetricSpecification"}
787	if s.MetricName == nil {
788		invalidParams.Add(request.NewErrParamRequired("MetricName"))
789	}
790	if s.Namespace == nil {
791		invalidParams.Add(request.NewErrParamRequired("Namespace"))
792	}
793	if s.Statistic == nil {
794		invalidParams.Add(request.NewErrParamRequired("Statistic"))
795	}
796	if s.Dimensions != nil {
797		for i, v := range s.Dimensions {
798			if v == nil {
799				continue
800			}
801			if err := v.Validate(); err != nil {
802				invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Dimensions", i), err.(request.ErrInvalidParams))
803			}
804		}
805	}
806
807	if invalidParams.Len() > 0 {
808		return invalidParams
809	}
810	return nil
811}
812
813// SetDimensions sets the Dimensions field's value.
814func (s *CustomizedLoadMetricSpecification) SetDimensions(v []*MetricDimension) *CustomizedLoadMetricSpecification {
815	s.Dimensions = v
816	return s
817}
818
819// SetMetricName sets the MetricName field's value.
820func (s *CustomizedLoadMetricSpecification) SetMetricName(v string) *CustomizedLoadMetricSpecification {
821	s.MetricName = &v
822	return s
823}
824
825// SetNamespace sets the Namespace field's value.
826func (s *CustomizedLoadMetricSpecification) SetNamespace(v string) *CustomizedLoadMetricSpecification {
827	s.Namespace = &v
828	return s
829}
830
831// SetStatistic sets the Statistic field's value.
832func (s *CustomizedLoadMetricSpecification) SetStatistic(v string) *CustomizedLoadMetricSpecification {
833	s.Statistic = &v
834	return s
835}
836
837// SetUnit sets the Unit field's value.
838func (s *CustomizedLoadMetricSpecification) SetUnit(v string) *CustomizedLoadMetricSpecification {
839	s.Unit = &v
840	return s
841}
842
843// Represents a CloudWatch metric of your choosing that can be used for dynamic
844// scaling as part of a target tracking scaling policy.
845//
846// To create your customized scaling metric specification:
847//
848//    * Add values for each required parameter from CloudWatch. You can use
849//    an existing metric, or a new metric that you create. To use your own metric,
850//    you must first publish the metric to CloudWatch. For more information,
851//    see Publish Custom Metrics (https://docs.aws.amazon.com/AmazonCloudWatch/latest/monitoring/publishingMetrics.html)
852//    in the Amazon CloudWatch User Guide.
853//
854//    * Choose a metric that changes proportionally with capacity. The value
855//    of the metric should increase or decrease in inverse proportion to the
856//    number of capacity units. That is, the value of the metric should decrease
857//    when capacity increases.
858//
859// For more information about CloudWatch, see Amazon CloudWatch Concepts (https://docs.aws.amazon.com/AmazonCloudWatch/latest/monitoring/cloudwatch_concepts.html).
860type CustomizedScalingMetricSpecification struct {
861	_ struct{} `type:"structure"`
862
863	// The dimensions of the metric.
864	//
865	// Conditional: If you published your metric with dimensions, you must specify
866	// the same dimensions in your customized scaling metric specification.
867	Dimensions []*MetricDimension `type:"list"`
868
869	// The name of the metric.
870	//
871	// MetricName is a required field
872	MetricName *string `type:"string" required:"true"`
873
874	// The namespace of the metric.
875	//
876	// Namespace is a required field
877	Namespace *string `type:"string" required:"true"`
878
879	// The statistic of the metric.
880	//
881	// Statistic is a required field
882	Statistic *string `type:"string" required:"true" enum:"MetricStatistic"`
883
884	// The unit of the metric.
885	Unit *string `type:"string"`
886}
887
888// String returns the string representation
889func (s CustomizedScalingMetricSpecification) String() string {
890	return awsutil.Prettify(s)
891}
892
893// GoString returns the string representation
894func (s CustomizedScalingMetricSpecification) GoString() string {
895	return s.String()
896}
897
898// Validate inspects the fields of the type to determine if they are valid.
899func (s *CustomizedScalingMetricSpecification) Validate() error {
900	invalidParams := request.ErrInvalidParams{Context: "CustomizedScalingMetricSpecification"}
901	if s.MetricName == nil {
902		invalidParams.Add(request.NewErrParamRequired("MetricName"))
903	}
904	if s.Namespace == nil {
905		invalidParams.Add(request.NewErrParamRequired("Namespace"))
906	}
907	if s.Statistic == nil {
908		invalidParams.Add(request.NewErrParamRequired("Statistic"))
909	}
910	if s.Dimensions != nil {
911		for i, v := range s.Dimensions {
912			if v == nil {
913				continue
914			}
915			if err := v.Validate(); err != nil {
916				invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Dimensions", i), err.(request.ErrInvalidParams))
917			}
918		}
919	}
920
921	if invalidParams.Len() > 0 {
922		return invalidParams
923	}
924	return nil
925}
926
927// SetDimensions sets the Dimensions field's value.
928func (s *CustomizedScalingMetricSpecification) SetDimensions(v []*MetricDimension) *CustomizedScalingMetricSpecification {
929	s.Dimensions = v
930	return s
931}
932
933// SetMetricName sets the MetricName field's value.
934func (s *CustomizedScalingMetricSpecification) SetMetricName(v string) *CustomizedScalingMetricSpecification {
935	s.MetricName = &v
936	return s
937}
938
939// SetNamespace sets the Namespace field's value.
940func (s *CustomizedScalingMetricSpecification) SetNamespace(v string) *CustomizedScalingMetricSpecification {
941	s.Namespace = &v
942	return s
943}
944
945// SetStatistic sets the Statistic field's value.
946func (s *CustomizedScalingMetricSpecification) SetStatistic(v string) *CustomizedScalingMetricSpecification {
947	s.Statistic = &v
948	return s
949}
950
951// SetUnit sets the Unit field's value.
952func (s *CustomizedScalingMetricSpecification) SetUnit(v string) *CustomizedScalingMetricSpecification {
953	s.Unit = &v
954	return s
955}
956
957// Represents a single value in the forecast data used for predictive scaling.
958type Datapoint struct {
959	_ struct{} `type:"structure"`
960
961	// The time stamp for the data point in UTC format.
962	Timestamp *time.Time `type:"timestamp"`
963
964	// The value of the data point.
965	Value *float64 `type:"double"`
966}
967
968// String returns the string representation
969func (s Datapoint) String() string {
970	return awsutil.Prettify(s)
971}
972
973// GoString returns the string representation
974func (s Datapoint) GoString() string {
975	return s.String()
976}
977
978// SetTimestamp sets the Timestamp field's value.
979func (s *Datapoint) SetTimestamp(v time.Time) *Datapoint {
980	s.Timestamp = &v
981	return s
982}
983
984// SetValue sets the Value field's value.
985func (s *Datapoint) SetValue(v float64) *Datapoint {
986	s.Value = &v
987	return s
988}
989
990type DeleteScalingPlanInput struct {
991	_ struct{} `type:"structure"`
992
993	// The name of the scaling plan.
994	//
995	// ScalingPlanName is a required field
996	ScalingPlanName *string `min:"1" type:"string" required:"true"`
997
998	// The version number of the scaling plan.
999	//
1000	// ScalingPlanVersion is a required field
1001	ScalingPlanVersion *int64 `type:"long" required:"true"`
1002}
1003
1004// String returns the string representation
1005func (s DeleteScalingPlanInput) String() string {
1006	return awsutil.Prettify(s)
1007}
1008
1009// GoString returns the string representation
1010func (s DeleteScalingPlanInput) GoString() string {
1011	return s.String()
1012}
1013
1014// Validate inspects the fields of the type to determine if they are valid.
1015func (s *DeleteScalingPlanInput) Validate() error {
1016	invalidParams := request.ErrInvalidParams{Context: "DeleteScalingPlanInput"}
1017	if s.ScalingPlanName == nil {
1018		invalidParams.Add(request.NewErrParamRequired("ScalingPlanName"))
1019	}
1020	if s.ScalingPlanName != nil && len(*s.ScalingPlanName) < 1 {
1021		invalidParams.Add(request.NewErrParamMinLen("ScalingPlanName", 1))
1022	}
1023	if s.ScalingPlanVersion == nil {
1024		invalidParams.Add(request.NewErrParamRequired("ScalingPlanVersion"))
1025	}
1026
1027	if invalidParams.Len() > 0 {
1028		return invalidParams
1029	}
1030	return nil
1031}
1032
1033// SetScalingPlanName sets the ScalingPlanName field's value.
1034func (s *DeleteScalingPlanInput) SetScalingPlanName(v string) *DeleteScalingPlanInput {
1035	s.ScalingPlanName = &v
1036	return s
1037}
1038
1039// SetScalingPlanVersion sets the ScalingPlanVersion field's value.
1040func (s *DeleteScalingPlanInput) SetScalingPlanVersion(v int64) *DeleteScalingPlanInput {
1041	s.ScalingPlanVersion = &v
1042	return s
1043}
1044
1045type DeleteScalingPlanOutput struct {
1046	_ struct{} `type:"structure"`
1047}
1048
1049// String returns the string representation
1050func (s DeleteScalingPlanOutput) String() string {
1051	return awsutil.Prettify(s)
1052}
1053
1054// GoString returns the string representation
1055func (s DeleteScalingPlanOutput) GoString() string {
1056	return s.String()
1057}
1058
1059type DescribeScalingPlanResourcesInput struct {
1060	_ struct{} `type:"structure"`
1061
1062	// The maximum number of scalable resources to return. The value must be between
1063	// 1 and 50. The default value is 50.
1064	MaxResults *int64 `type:"integer"`
1065
1066	// The token for the next set of results.
1067	NextToken *string `type:"string"`
1068
1069	// The name of the scaling plan.
1070	//
1071	// ScalingPlanName is a required field
1072	ScalingPlanName *string `min:"1" type:"string" required:"true"`
1073
1074	// The version number of the scaling plan.
1075	//
1076	// ScalingPlanVersion is a required field
1077	ScalingPlanVersion *int64 `type:"long" required:"true"`
1078}
1079
1080// String returns the string representation
1081func (s DescribeScalingPlanResourcesInput) String() string {
1082	return awsutil.Prettify(s)
1083}
1084
1085// GoString returns the string representation
1086func (s DescribeScalingPlanResourcesInput) GoString() string {
1087	return s.String()
1088}
1089
1090// Validate inspects the fields of the type to determine if they are valid.
1091func (s *DescribeScalingPlanResourcesInput) Validate() error {
1092	invalidParams := request.ErrInvalidParams{Context: "DescribeScalingPlanResourcesInput"}
1093	if s.ScalingPlanName == nil {
1094		invalidParams.Add(request.NewErrParamRequired("ScalingPlanName"))
1095	}
1096	if s.ScalingPlanName != nil && len(*s.ScalingPlanName) < 1 {
1097		invalidParams.Add(request.NewErrParamMinLen("ScalingPlanName", 1))
1098	}
1099	if s.ScalingPlanVersion == nil {
1100		invalidParams.Add(request.NewErrParamRequired("ScalingPlanVersion"))
1101	}
1102
1103	if invalidParams.Len() > 0 {
1104		return invalidParams
1105	}
1106	return nil
1107}
1108
1109// SetMaxResults sets the MaxResults field's value.
1110func (s *DescribeScalingPlanResourcesInput) SetMaxResults(v int64) *DescribeScalingPlanResourcesInput {
1111	s.MaxResults = &v
1112	return s
1113}
1114
1115// SetNextToken sets the NextToken field's value.
1116func (s *DescribeScalingPlanResourcesInput) SetNextToken(v string) *DescribeScalingPlanResourcesInput {
1117	s.NextToken = &v
1118	return s
1119}
1120
1121// SetScalingPlanName sets the ScalingPlanName field's value.
1122func (s *DescribeScalingPlanResourcesInput) SetScalingPlanName(v string) *DescribeScalingPlanResourcesInput {
1123	s.ScalingPlanName = &v
1124	return s
1125}
1126
1127// SetScalingPlanVersion sets the ScalingPlanVersion field's value.
1128func (s *DescribeScalingPlanResourcesInput) SetScalingPlanVersion(v int64) *DescribeScalingPlanResourcesInput {
1129	s.ScalingPlanVersion = &v
1130	return s
1131}
1132
1133type DescribeScalingPlanResourcesOutput struct {
1134	_ struct{} `type:"structure"`
1135
1136	// The token required to get the next set of results. This value is null if
1137	// there are no more results to return.
1138	NextToken *string `type:"string"`
1139
1140	// Information about the scalable resources.
1141	ScalingPlanResources []*ScalingPlanResource `type:"list"`
1142}
1143
1144// String returns the string representation
1145func (s DescribeScalingPlanResourcesOutput) String() string {
1146	return awsutil.Prettify(s)
1147}
1148
1149// GoString returns the string representation
1150func (s DescribeScalingPlanResourcesOutput) GoString() string {
1151	return s.String()
1152}
1153
1154// SetNextToken sets the NextToken field's value.
1155func (s *DescribeScalingPlanResourcesOutput) SetNextToken(v string) *DescribeScalingPlanResourcesOutput {
1156	s.NextToken = &v
1157	return s
1158}
1159
1160// SetScalingPlanResources sets the ScalingPlanResources field's value.
1161func (s *DescribeScalingPlanResourcesOutput) SetScalingPlanResources(v []*ScalingPlanResource) *DescribeScalingPlanResourcesOutput {
1162	s.ScalingPlanResources = v
1163	return s
1164}
1165
1166type DescribeScalingPlansInput struct {
1167	_ struct{} `type:"structure"`
1168
1169	// The sources for the applications (up to 10). If you specify scaling plan
1170	// names, you cannot specify application sources.
1171	ApplicationSources []*ApplicationSource `type:"list"`
1172
1173	// The maximum number of scalable resources to return. This value can be between
1174	// 1 and 50. The default value is 50.
1175	MaxResults *int64 `type:"integer"`
1176
1177	// The token for the next set of results.
1178	NextToken *string `type:"string"`
1179
1180	// The names of the scaling plans (up to 10). If you specify application sources,
1181	// you cannot specify scaling plan names.
1182	ScalingPlanNames []*string `type:"list"`
1183
1184	// The version number of the scaling plan. If you specify a scaling plan version,
1185	// you must also specify a scaling plan name.
1186	ScalingPlanVersion *int64 `type:"long"`
1187}
1188
1189// String returns the string representation
1190func (s DescribeScalingPlansInput) String() string {
1191	return awsutil.Prettify(s)
1192}
1193
1194// GoString returns the string representation
1195func (s DescribeScalingPlansInput) GoString() string {
1196	return s.String()
1197}
1198
1199// Validate inspects the fields of the type to determine if they are valid.
1200func (s *DescribeScalingPlansInput) Validate() error {
1201	invalidParams := request.ErrInvalidParams{Context: "DescribeScalingPlansInput"}
1202	if s.ApplicationSources != nil {
1203		for i, v := range s.ApplicationSources {
1204			if v == nil {
1205				continue
1206			}
1207			if err := v.Validate(); err != nil {
1208				invalidParams.AddNested(fmt.Sprintf("%s[%v]", "ApplicationSources", i), err.(request.ErrInvalidParams))
1209			}
1210		}
1211	}
1212
1213	if invalidParams.Len() > 0 {
1214		return invalidParams
1215	}
1216	return nil
1217}
1218
1219// SetApplicationSources sets the ApplicationSources field's value.
1220func (s *DescribeScalingPlansInput) SetApplicationSources(v []*ApplicationSource) *DescribeScalingPlansInput {
1221	s.ApplicationSources = v
1222	return s
1223}
1224
1225// SetMaxResults sets the MaxResults field's value.
1226func (s *DescribeScalingPlansInput) SetMaxResults(v int64) *DescribeScalingPlansInput {
1227	s.MaxResults = &v
1228	return s
1229}
1230
1231// SetNextToken sets the NextToken field's value.
1232func (s *DescribeScalingPlansInput) SetNextToken(v string) *DescribeScalingPlansInput {
1233	s.NextToken = &v
1234	return s
1235}
1236
1237// SetScalingPlanNames sets the ScalingPlanNames field's value.
1238func (s *DescribeScalingPlansInput) SetScalingPlanNames(v []*string) *DescribeScalingPlansInput {
1239	s.ScalingPlanNames = v
1240	return s
1241}
1242
1243// SetScalingPlanVersion sets the ScalingPlanVersion field's value.
1244func (s *DescribeScalingPlansInput) SetScalingPlanVersion(v int64) *DescribeScalingPlansInput {
1245	s.ScalingPlanVersion = &v
1246	return s
1247}
1248
1249type DescribeScalingPlansOutput struct {
1250	_ struct{} `type:"structure"`
1251
1252	// The token required to get the next set of results. This value is null if
1253	// there are no more results to return.
1254	NextToken *string `type:"string"`
1255
1256	// Information about the scaling plans.
1257	ScalingPlans []*ScalingPlan `type:"list"`
1258}
1259
1260// String returns the string representation
1261func (s DescribeScalingPlansOutput) String() string {
1262	return awsutil.Prettify(s)
1263}
1264
1265// GoString returns the string representation
1266func (s DescribeScalingPlansOutput) GoString() string {
1267	return s.String()
1268}
1269
1270// SetNextToken sets the NextToken field's value.
1271func (s *DescribeScalingPlansOutput) SetNextToken(v string) *DescribeScalingPlansOutput {
1272	s.NextToken = &v
1273	return s
1274}
1275
1276// SetScalingPlans sets the ScalingPlans field's value.
1277func (s *DescribeScalingPlansOutput) SetScalingPlans(v []*ScalingPlan) *DescribeScalingPlansOutput {
1278	s.ScalingPlans = v
1279	return s
1280}
1281
1282type GetScalingPlanResourceForecastDataInput struct {
1283	_ struct{} `type:"structure"`
1284
1285	// The exclusive end time of the time range for the forecast data to get. The
1286	// maximum time duration between the start and end time is seven days.
1287	//
1288	// Although this parameter can accept a date and time that is more than two
1289	// days in the future, the availability of forecast data has limits. AWS Auto
1290	// Scaling only issues forecasts for periods of two days in advance.
1291	//
1292	// EndTime is a required field
1293	EndTime *time.Time `type:"timestamp" required:"true"`
1294
1295	// The type of forecast data to get.
1296	//
1297	//    * LoadForecast: The load metric forecast.
1298	//
1299	//    * CapacityForecast: The capacity forecast.
1300	//
1301	//    * ScheduledActionMinCapacity: The minimum capacity for each scheduled
1302	//    scaling action. This data is calculated as the larger of two values: the
1303	//    capacity forecast or the minimum capacity in the scaling instruction.
1304	//
1305	//    * ScheduledActionMaxCapacity: The maximum capacity for each scheduled
1306	//    scaling action. The calculation used is determined by the predictive scaling
1307	//    maximum capacity behavior setting in the scaling instruction.
1308	//
1309	// ForecastDataType is a required field
1310	ForecastDataType *string `type:"string" required:"true" enum:"ForecastDataType"`
1311
1312	// The ID of the resource. This string consists of the resource type and unique
1313	// identifier.
1314	//
1315	//    * Auto Scaling group - The resource type is autoScalingGroup and the unique
1316	//    identifier is the name of the Auto Scaling group. Example: autoScalingGroup/my-asg.
1317	//
1318	//    * ECS service - The resource type is service and the unique identifier
1319	//    is the cluster name and service name. Example: service/default/sample-webapp.
1320	//
1321	//    * Spot Fleet request - The resource type is spot-fleet-request and the
1322	//    unique identifier is the Spot Fleet request ID. Example: spot-fleet-request/sfr-73fbd2ce-aa30-494c-8788-1cee4EXAMPLE.
1323	//
1324	//    * DynamoDB table - The resource type is table and the unique identifier
1325	//    is the resource ID. Example: table/my-table.
1326	//
1327	//    * DynamoDB global secondary index - The resource type is index and the
1328	//    unique identifier is the resource ID. Example: table/my-table/index/my-table-index.
1329	//
1330	//    * Aurora DB cluster - The resource type is cluster and the unique identifier
1331	//    is the cluster name. Example: cluster:my-db-cluster.
1332	//
1333	// ResourceId is a required field
1334	ResourceId *string `type:"string" required:"true"`
1335
1336	// The scalable dimension for the resource.
1337	//
1338	// ScalableDimension is a required field
1339	ScalableDimension *string `type:"string" required:"true" enum:"ScalableDimension"`
1340
1341	// The name of the scaling plan.
1342	//
1343	// ScalingPlanName is a required field
1344	ScalingPlanName *string `min:"1" type:"string" required:"true"`
1345
1346	// The version number of the scaling plan.
1347	//
1348	// ScalingPlanVersion is a required field
1349	ScalingPlanVersion *int64 `type:"long" required:"true"`
1350
1351	// The namespace of the AWS service.
1352	//
1353	// ServiceNamespace is a required field
1354	ServiceNamespace *string `type:"string" required:"true" enum:"ServiceNamespace"`
1355
1356	// The inclusive start time of the time range for the forecast data to get.
1357	// The date and time can be at most 56 days before the current date and time.
1358	//
1359	// StartTime is a required field
1360	StartTime *time.Time `type:"timestamp" required:"true"`
1361}
1362
1363// String returns the string representation
1364func (s GetScalingPlanResourceForecastDataInput) String() string {
1365	return awsutil.Prettify(s)
1366}
1367
1368// GoString returns the string representation
1369func (s GetScalingPlanResourceForecastDataInput) GoString() string {
1370	return s.String()
1371}
1372
1373// Validate inspects the fields of the type to determine if they are valid.
1374func (s *GetScalingPlanResourceForecastDataInput) Validate() error {
1375	invalidParams := request.ErrInvalidParams{Context: "GetScalingPlanResourceForecastDataInput"}
1376	if s.EndTime == nil {
1377		invalidParams.Add(request.NewErrParamRequired("EndTime"))
1378	}
1379	if s.ForecastDataType == nil {
1380		invalidParams.Add(request.NewErrParamRequired("ForecastDataType"))
1381	}
1382	if s.ResourceId == nil {
1383		invalidParams.Add(request.NewErrParamRequired("ResourceId"))
1384	}
1385	if s.ScalableDimension == nil {
1386		invalidParams.Add(request.NewErrParamRequired("ScalableDimension"))
1387	}
1388	if s.ScalingPlanName == nil {
1389		invalidParams.Add(request.NewErrParamRequired("ScalingPlanName"))
1390	}
1391	if s.ScalingPlanName != nil && len(*s.ScalingPlanName) < 1 {
1392		invalidParams.Add(request.NewErrParamMinLen("ScalingPlanName", 1))
1393	}
1394	if s.ScalingPlanVersion == nil {
1395		invalidParams.Add(request.NewErrParamRequired("ScalingPlanVersion"))
1396	}
1397	if s.ServiceNamespace == nil {
1398		invalidParams.Add(request.NewErrParamRequired("ServiceNamespace"))
1399	}
1400	if s.StartTime == nil {
1401		invalidParams.Add(request.NewErrParamRequired("StartTime"))
1402	}
1403
1404	if invalidParams.Len() > 0 {
1405		return invalidParams
1406	}
1407	return nil
1408}
1409
1410// SetEndTime sets the EndTime field's value.
1411func (s *GetScalingPlanResourceForecastDataInput) SetEndTime(v time.Time) *GetScalingPlanResourceForecastDataInput {
1412	s.EndTime = &v
1413	return s
1414}
1415
1416// SetForecastDataType sets the ForecastDataType field's value.
1417func (s *GetScalingPlanResourceForecastDataInput) SetForecastDataType(v string) *GetScalingPlanResourceForecastDataInput {
1418	s.ForecastDataType = &v
1419	return s
1420}
1421
1422// SetResourceId sets the ResourceId field's value.
1423func (s *GetScalingPlanResourceForecastDataInput) SetResourceId(v string) *GetScalingPlanResourceForecastDataInput {
1424	s.ResourceId = &v
1425	return s
1426}
1427
1428// SetScalableDimension sets the ScalableDimension field's value.
1429func (s *GetScalingPlanResourceForecastDataInput) SetScalableDimension(v string) *GetScalingPlanResourceForecastDataInput {
1430	s.ScalableDimension = &v
1431	return s
1432}
1433
1434// SetScalingPlanName sets the ScalingPlanName field's value.
1435func (s *GetScalingPlanResourceForecastDataInput) SetScalingPlanName(v string) *GetScalingPlanResourceForecastDataInput {
1436	s.ScalingPlanName = &v
1437	return s
1438}
1439
1440// SetScalingPlanVersion sets the ScalingPlanVersion field's value.
1441func (s *GetScalingPlanResourceForecastDataInput) SetScalingPlanVersion(v int64) *GetScalingPlanResourceForecastDataInput {
1442	s.ScalingPlanVersion = &v
1443	return s
1444}
1445
1446// SetServiceNamespace sets the ServiceNamespace field's value.
1447func (s *GetScalingPlanResourceForecastDataInput) SetServiceNamespace(v string) *GetScalingPlanResourceForecastDataInput {
1448	s.ServiceNamespace = &v
1449	return s
1450}
1451
1452// SetStartTime sets the StartTime field's value.
1453func (s *GetScalingPlanResourceForecastDataInput) SetStartTime(v time.Time) *GetScalingPlanResourceForecastDataInput {
1454	s.StartTime = &v
1455	return s
1456}
1457
1458type GetScalingPlanResourceForecastDataOutput struct {
1459	_ struct{} `type:"structure"`
1460
1461	// The data points to return.
1462	//
1463	// Datapoints is a required field
1464	Datapoints []*Datapoint `type:"list" required:"true"`
1465}
1466
1467// String returns the string representation
1468func (s GetScalingPlanResourceForecastDataOutput) String() string {
1469	return awsutil.Prettify(s)
1470}
1471
1472// GoString returns the string representation
1473func (s GetScalingPlanResourceForecastDataOutput) GoString() string {
1474	return s.String()
1475}
1476
1477// SetDatapoints sets the Datapoints field's value.
1478func (s *GetScalingPlanResourceForecastDataOutput) SetDatapoints(v []*Datapoint) *GetScalingPlanResourceForecastDataOutput {
1479	s.Datapoints = v
1480	return s
1481}
1482
1483// Represents a dimension for a customized metric.
1484type MetricDimension struct {
1485	_ struct{} `type:"structure"`
1486
1487	// The name of the dimension.
1488	//
1489	// Name is a required field
1490	Name *string `type:"string" required:"true"`
1491
1492	// The value of the dimension.
1493	//
1494	// Value is a required field
1495	Value *string `type:"string" required:"true"`
1496}
1497
1498// String returns the string representation
1499func (s MetricDimension) String() string {
1500	return awsutil.Prettify(s)
1501}
1502
1503// GoString returns the string representation
1504func (s MetricDimension) GoString() string {
1505	return s.String()
1506}
1507
1508// Validate inspects the fields of the type to determine if they are valid.
1509func (s *MetricDimension) Validate() error {
1510	invalidParams := request.ErrInvalidParams{Context: "MetricDimension"}
1511	if s.Name == nil {
1512		invalidParams.Add(request.NewErrParamRequired("Name"))
1513	}
1514	if s.Value == nil {
1515		invalidParams.Add(request.NewErrParamRequired("Value"))
1516	}
1517
1518	if invalidParams.Len() > 0 {
1519		return invalidParams
1520	}
1521	return nil
1522}
1523
1524// SetName sets the Name field's value.
1525func (s *MetricDimension) SetName(v string) *MetricDimension {
1526	s.Name = &v
1527	return s
1528}
1529
1530// SetValue sets the Value field's value.
1531func (s *MetricDimension) SetValue(v string) *MetricDimension {
1532	s.Value = &v
1533	return s
1534}
1535
1536// Represents a predefined metric that can be used for predictive scaling.
1537type PredefinedLoadMetricSpecification struct {
1538	_ struct{} `type:"structure"`
1539
1540	// The metric type.
1541	//
1542	// PredefinedLoadMetricType is a required field
1543	PredefinedLoadMetricType *string `type:"string" required:"true" enum:"LoadMetricType"`
1544
1545	// Identifies the resource associated with the metric type. You can't specify
1546	// a resource label unless the metric type is ALBRequestCountPerTarget and there
1547	// is a target group for an Application Load Balancer attached to the Auto Scaling
1548	// group.
1549	//
1550	// The format is app/<load-balancer-name>/<load-balancer-id>/targetgroup/<target-group-name>/<target-group-id>,
1551	// where:
1552	//
1553	//    * app/<load-balancer-name>/<load-balancer-id> is the final portion of
1554	//    the load balancer ARN.
1555	//
1556	//    * targetgroup/<target-group-name>/<target-group-id> is the final portion
1557	//    of the target group ARN.
1558	ResourceLabel *string `min:"1" type:"string"`
1559}
1560
1561// String returns the string representation
1562func (s PredefinedLoadMetricSpecification) String() string {
1563	return awsutil.Prettify(s)
1564}
1565
1566// GoString returns the string representation
1567func (s PredefinedLoadMetricSpecification) GoString() string {
1568	return s.String()
1569}
1570
1571// Validate inspects the fields of the type to determine if they are valid.
1572func (s *PredefinedLoadMetricSpecification) Validate() error {
1573	invalidParams := request.ErrInvalidParams{Context: "PredefinedLoadMetricSpecification"}
1574	if s.PredefinedLoadMetricType == nil {
1575		invalidParams.Add(request.NewErrParamRequired("PredefinedLoadMetricType"))
1576	}
1577	if s.ResourceLabel != nil && len(*s.ResourceLabel) < 1 {
1578		invalidParams.Add(request.NewErrParamMinLen("ResourceLabel", 1))
1579	}
1580
1581	if invalidParams.Len() > 0 {
1582		return invalidParams
1583	}
1584	return nil
1585}
1586
1587// SetPredefinedLoadMetricType sets the PredefinedLoadMetricType field's value.
1588func (s *PredefinedLoadMetricSpecification) SetPredefinedLoadMetricType(v string) *PredefinedLoadMetricSpecification {
1589	s.PredefinedLoadMetricType = &v
1590	return s
1591}
1592
1593// SetResourceLabel sets the ResourceLabel field's value.
1594func (s *PredefinedLoadMetricSpecification) SetResourceLabel(v string) *PredefinedLoadMetricSpecification {
1595	s.ResourceLabel = &v
1596	return s
1597}
1598
1599// Represents a predefined metric that can be used for dynamic scaling as part
1600// of a target tracking scaling policy.
1601type PredefinedScalingMetricSpecification struct {
1602	_ struct{} `type:"structure"`
1603
1604	// The metric type. The ALBRequestCountPerTarget metric type applies only to
1605	// Auto Scaling groups, Spot Fleet requests, and ECS services.
1606	//
1607	// PredefinedScalingMetricType is a required field
1608	PredefinedScalingMetricType *string `type:"string" required:"true" enum:"ScalingMetricType"`
1609
1610	// Identifies the resource associated with the metric type. You can't specify
1611	// a resource label unless the metric type is ALBRequestCountPerTarget and there
1612	// is a target group for an Application Load Balancer attached to the Auto Scaling
1613	// group, Spot Fleet request, or ECS service.
1614	//
1615	// The format is app/<load-balancer-name>/<load-balancer-id>/targetgroup/<target-group-name>/<target-group-id>,
1616	// where:
1617	//
1618	//    * app/<load-balancer-name>/<load-balancer-id> is the final portion of
1619	//    the load balancer ARN.
1620	//
1621	//    * targetgroup/<target-group-name>/<target-group-id> is the final portion
1622	//    of the target group ARN.
1623	ResourceLabel *string `min:"1" type:"string"`
1624}
1625
1626// String returns the string representation
1627func (s PredefinedScalingMetricSpecification) String() string {
1628	return awsutil.Prettify(s)
1629}
1630
1631// GoString returns the string representation
1632func (s PredefinedScalingMetricSpecification) GoString() string {
1633	return s.String()
1634}
1635
1636// Validate inspects the fields of the type to determine if they are valid.
1637func (s *PredefinedScalingMetricSpecification) Validate() error {
1638	invalidParams := request.ErrInvalidParams{Context: "PredefinedScalingMetricSpecification"}
1639	if s.PredefinedScalingMetricType == nil {
1640		invalidParams.Add(request.NewErrParamRequired("PredefinedScalingMetricType"))
1641	}
1642	if s.ResourceLabel != nil && len(*s.ResourceLabel) < 1 {
1643		invalidParams.Add(request.NewErrParamMinLen("ResourceLabel", 1))
1644	}
1645
1646	if invalidParams.Len() > 0 {
1647		return invalidParams
1648	}
1649	return nil
1650}
1651
1652// SetPredefinedScalingMetricType sets the PredefinedScalingMetricType field's value.
1653func (s *PredefinedScalingMetricSpecification) SetPredefinedScalingMetricType(v string) *PredefinedScalingMetricSpecification {
1654	s.PredefinedScalingMetricType = &v
1655	return s
1656}
1657
1658// SetResourceLabel sets the ResourceLabel field's value.
1659func (s *PredefinedScalingMetricSpecification) SetResourceLabel(v string) *PredefinedScalingMetricSpecification {
1660	s.ResourceLabel = &v
1661	return s
1662}
1663
1664// Describes a scaling instruction for a scalable resource.
1665//
1666// The scaling instruction is used in combination with a scaling plan, which
1667// is a set of instructions for configuring dynamic scaling and predictive scaling
1668// for the scalable resources in your application. Each scaling instruction
1669// applies to one resource.
1670//
1671// AWS Auto Scaling creates target tracking scaling policies based on the scaling
1672// instructions. Target tracking scaling policies adjust the capacity of your
1673// scalable resource as required to maintain resource utilization at the target
1674// value that you specified.
1675//
1676// AWS Auto Scaling also configures predictive scaling for your Amazon EC2 Auto
1677// Scaling groups using a subset of parameters, including the load metric, the
1678// scaling metric, the target value for the scaling metric, the predictive scaling
1679// mode (forecast and scale or forecast only), and the desired behavior when
1680// the forecast capacity exceeds the maximum capacity of the resource. With
1681// predictive scaling, AWS Auto Scaling generates forecasts with traffic predictions
1682// for the two days ahead and schedules scaling actions that proactively add
1683// and remove resource capacity to match the forecast.
1684//
1685// We recommend waiting a minimum of 24 hours after creating an Auto Scaling
1686// group to configure predictive scaling. At minimum, there must be 24 hours
1687// of historical data to generate a forecast.
1688//
1689// For more information, see Getting Started with AWS Auto Scaling (https://docs.aws.amazon.com/autoscaling/plans/userguide/auto-scaling-getting-started.html).
1690type ScalingInstruction struct {
1691	_ struct{} `type:"structure"`
1692
1693	// The customized load metric to use for predictive scaling. This parameter
1694	// or a PredefinedLoadMetricSpecification is required when configuring predictive
1695	// scaling, and cannot be used otherwise.
1696	CustomizedLoadMetricSpecification *CustomizedLoadMetricSpecification `type:"structure"`
1697
1698	// Controls whether dynamic scaling by AWS Auto Scaling is disabled. When dynamic
1699	// scaling is enabled, AWS Auto Scaling creates target tracking scaling policies
1700	// based on the specified target tracking configurations.
1701	//
1702	// The default is enabled (false).
1703	DisableDynamicScaling *bool `type:"boolean"`
1704
1705	// The maximum capacity of the resource. The exception to this upper limit is
1706	// if you specify a non-default setting for PredictiveScalingMaxCapacityBehavior.
1707	//
1708	// MaxCapacity is a required field
1709	MaxCapacity *int64 `type:"integer" required:"true"`
1710
1711	// The minimum capacity of the resource.
1712	//
1713	// MinCapacity is a required field
1714	MinCapacity *int64 `type:"integer" required:"true"`
1715
1716	// The predefined load metric to use for predictive scaling. This parameter
1717	// or a CustomizedLoadMetricSpecification is required when configuring predictive
1718	// scaling, and cannot be used otherwise.
1719	PredefinedLoadMetricSpecification *PredefinedLoadMetricSpecification `type:"structure"`
1720
1721	// Defines the behavior that should be applied if the forecast capacity approaches
1722	// or exceeds the maximum capacity specified for the resource. The default value
1723	// is SetForecastCapacityToMaxCapacity.
1724	//
1725	// The following are possible values:
1726	//
1727	//    * SetForecastCapacityToMaxCapacity - AWS Auto Scaling cannot scale resource
1728	//    capacity higher than the maximum capacity. The maximum capacity is enforced
1729	//    as a hard limit.
1730	//
1731	//    * SetMaxCapacityToForecastCapacity - AWS Auto Scaling may scale resource
1732	//    capacity higher than the maximum capacity to equal but not exceed forecast
1733	//    capacity.
1734	//
1735	//    * SetMaxCapacityAboveForecastCapacity - AWS Auto Scaling may scale resource
1736	//    capacity higher than the maximum capacity by a specified buffer value.
1737	//    The intention is to give the target tracking scaling policy extra capacity
1738	//    if unexpected traffic occurs.
1739	//
1740	// Only valid when configuring predictive scaling.
1741	PredictiveScalingMaxCapacityBehavior *string `type:"string" enum:"PredictiveScalingMaxCapacityBehavior"`
1742
1743	// The size of the capacity buffer to use when the forecast capacity is close
1744	// to or exceeds the maximum capacity. The value is specified as a percentage
1745	// relative to the forecast capacity. For example, if the buffer is 10, this
1746	// means a 10 percent buffer, such that if the forecast capacity is 50, and
1747	// the maximum capacity is 40, then the effective maximum capacity is 55.
1748	//
1749	// Only valid when configuring predictive scaling. Required if the PredictiveScalingMaxCapacityBehavior
1750	// is set to SetMaxCapacityAboveForecastCapacity, and cannot be used otherwise.
1751	//
1752	// The range is 1-100.
1753	PredictiveScalingMaxCapacityBuffer *int64 `type:"integer"`
1754
1755	// The predictive scaling mode. The default value is ForecastAndScale. Otherwise,
1756	// AWS Auto Scaling forecasts capacity but does not create any scheduled scaling
1757	// actions based on the capacity forecast.
1758	PredictiveScalingMode *string `type:"string" enum:"PredictiveScalingMode"`
1759
1760	// The ID of the resource. This string consists of the resource type and unique
1761	// identifier.
1762	//
1763	//    * Auto Scaling group - The resource type is autoScalingGroup and the unique
1764	//    identifier is the name of the Auto Scaling group. Example: autoScalingGroup/my-asg.
1765	//
1766	//    * ECS service - The resource type is service and the unique identifier
1767	//    is the cluster name and service name. Example: service/default/sample-webapp.
1768	//
1769	//    * Spot Fleet request - The resource type is spot-fleet-request and the
1770	//    unique identifier is the Spot Fleet request ID. Example: spot-fleet-request/sfr-73fbd2ce-aa30-494c-8788-1cee4EXAMPLE.
1771	//
1772	//    * DynamoDB table - The resource type is table and the unique identifier
1773	//    is the resource ID. Example: table/my-table.
1774	//
1775	//    * DynamoDB global secondary index - The resource type is index and the
1776	//    unique identifier is the resource ID. Example: table/my-table/index/my-table-index.
1777	//
1778	//    * Aurora DB cluster - The resource type is cluster and the unique identifier
1779	//    is the cluster name. Example: cluster:my-db-cluster.
1780	//
1781	// ResourceId is a required field
1782	ResourceId *string `min:"1" type:"string" required:"true"`
1783
1784	// The scalable dimension associated with the resource.
1785	//
1786	//    * autoscaling:autoScalingGroup:DesiredCapacity - The desired capacity
1787	//    of an Auto Scaling group.
1788	//
1789	//    * ecs:service:DesiredCount - The desired task count of an ECS service.
1790	//
1791	//    * ec2:spot-fleet-request:TargetCapacity - The target capacity of a Spot
1792	//    Fleet request.
1793	//
1794	//    * dynamodb:table:ReadCapacityUnits - The provisioned read capacity for
1795	//    a DynamoDB table.
1796	//
1797	//    * dynamodb:table:WriteCapacityUnits - The provisioned write capacity for
1798	//    a DynamoDB table.
1799	//
1800	//    * dynamodb:index:ReadCapacityUnits - The provisioned read capacity for
1801	//    a DynamoDB global secondary index.
1802	//
1803	//    * dynamodb:index:WriteCapacityUnits - The provisioned write capacity for
1804	//    a DynamoDB global secondary index.
1805	//
1806	//    * rds:cluster:ReadReplicaCount - The count of Aurora Replicas in an Aurora
1807	//    DB cluster. Available for Aurora MySQL-compatible edition and Aurora PostgreSQL-compatible
1808	//    edition.
1809	//
1810	// ScalableDimension is a required field
1811	ScalableDimension *string `type:"string" required:"true" enum:"ScalableDimension"`
1812
1813	// Controls whether a resource's externally created scaling policies are kept
1814	// or replaced.
1815	//
1816	// The default value is KeepExternalPolicies. If the parameter is set to ReplaceExternalPolicies,
1817	// any scaling policies that are external to AWS Auto Scaling are deleted and
1818	// new target tracking scaling policies created.
1819	//
1820	// Only valid when configuring dynamic scaling.
1821	//
1822	// Condition: The number of existing policies to be replaced must be less than
1823	// or equal to 50. If there are more than 50 policies to be replaced, AWS Auto
1824	// Scaling keeps all existing policies and does not create new ones.
1825	ScalingPolicyUpdateBehavior *string `type:"string" enum:"ScalingPolicyUpdateBehavior"`
1826
1827	// The amount of time, in seconds, to buffer the run time of scheduled scaling
1828	// actions when scaling out. For example, if the forecast says to add capacity
1829	// at 10:00 AM, and the buffer time is 5 minutes, then the run time of the corresponding
1830	// scheduled scaling action will be 9:55 AM. The intention is to give resources
1831	// time to be provisioned. For example, it can take a few minutes to launch
1832	// an EC2 instance. The actual amount of time required depends on several factors,
1833	// such as the size of the instance and whether there are startup scripts to
1834	// complete.
1835	//
1836	// The value must be less than the forecast interval duration of 3600 seconds
1837	// (60 minutes). The default is 300 seconds.
1838	//
1839	// Only valid when configuring predictive scaling.
1840	ScheduledActionBufferTime *int64 `type:"integer"`
1841
1842	// The namespace of the AWS service.
1843	//
1844	// ServiceNamespace is a required field
1845	ServiceNamespace *string `type:"string" required:"true" enum:"ServiceNamespace"`
1846
1847	// The structure that defines new target tracking configurations (up to 10).
1848	// Each of these structures includes a specific scaling metric and a target
1849	// value for the metric, along with various parameters to use with dynamic scaling.
1850	//
1851	// With predictive scaling and dynamic scaling, the resource scales based on
1852	// the target tracking configuration that provides the largest capacity for
1853	// both scale in and scale out.
1854	//
1855	// Condition: The scaling metric must be unique across target tracking configurations.
1856	//
1857	// TargetTrackingConfigurations is a required field
1858	TargetTrackingConfigurations []*TargetTrackingConfiguration `type:"list" required:"true"`
1859}
1860
1861// String returns the string representation
1862func (s ScalingInstruction) String() string {
1863	return awsutil.Prettify(s)
1864}
1865
1866// GoString returns the string representation
1867func (s ScalingInstruction) GoString() string {
1868	return s.String()
1869}
1870
1871// Validate inspects the fields of the type to determine if they are valid.
1872func (s *ScalingInstruction) Validate() error {
1873	invalidParams := request.ErrInvalidParams{Context: "ScalingInstruction"}
1874	if s.MaxCapacity == nil {
1875		invalidParams.Add(request.NewErrParamRequired("MaxCapacity"))
1876	}
1877	if s.MinCapacity == nil {
1878		invalidParams.Add(request.NewErrParamRequired("MinCapacity"))
1879	}
1880	if s.ResourceId == nil {
1881		invalidParams.Add(request.NewErrParamRequired("ResourceId"))
1882	}
1883	if s.ResourceId != nil && len(*s.ResourceId) < 1 {
1884		invalidParams.Add(request.NewErrParamMinLen("ResourceId", 1))
1885	}
1886	if s.ScalableDimension == nil {
1887		invalidParams.Add(request.NewErrParamRequired("ScalableDimension"))
1888	}
1889	if s.ServiceNamespace == nil {
1890		invalidParams.Add(request.NewErrParamRequired("ServiceNamespace"))
1891	}
1892	if s.TargetTrackingConfigurations == nil {
1893		invalidParams.Add(request.NewErrParamRequired("TargetTrackingConfigurations"))
1894	}
1895	if s.CustomizedLoadMetricSpecification != nil {
1896		if err := s.CustomizedLoadMetricSpecification.Validate(); err != nil {
1897			invalidParams.AddNested("CustomizedLoadMetricSpecification", err.(request.ErrInvalidParams))
1898		}
1899	}
1900	if s.PredefinedLoadMetricSpecification != nil {
1901		if err := s.PredefinedLoadMetricSpecification.Validate(); err != nil {
1902			invalidParams.AddNested("PredefinedLoadMetricSpecification", err.(request.ErrInvalidParams))
1903		}
1904	}
1905	if s.TargetTrackingConfigurations != nil {
1906		for i, v := range s.TargetTrackingConfigurations {
1907			if v == nil {
1908				continue
1909			}
1910			if err := v.Validate(); err != nil {
1911				invalidParams.AddNested(fmt.Sprintf("%s[%v]", "TargetTrackingConfigurations", i), err.(request.ErrInvalidParams))
1912			}
1913		}
1914	}
1915
1916	if invalidParams.Len() > 0 {
1917		return invalidParams
1918	}
1919	return nil
1920}
1921
1922// SetCustomizedLoadMetricSpecification sets the CustomizedLoadMetricSpecification field's value.
1923func (s *ScalingInstruction) SetCustomizedLoadMetricSpecification(v *CustomizedLoadMetricSpecification) *ScalingInstruction {
1924	s.CustomizedLoadMetricSpecification = v
1925	return s
1926}
1927
1928// SetDisableDynamicScaling sets the DisableDynamicScaling field's value.
1929func (s *ScalingInstruction) SetDisableDynamicScaling(v bool) *ScalingInstruction {
1930	s.DisableDynamicScaling = &v
1931	return s
1932}
1933
1934// SetMaxCapacity sets the MaxCapacity field's value.
1935func (s *ScalingInstruction) SetMaxCapacity(v int64) *ScalingInstruction {
1936	s.MaxCapacity = &v
1937	return s
1938}
1939
1940// SetMinCapacity sets the MinCapacity field's value.
1941func (s *ScalingInstruction) SetMinCapacity(v int64) *ScalingInstruction {
1942	s.MinCapacity = &v
1943	return s
1944}
1945
1946// SetPredefinedLoadMetricSpecification sets the PredefinedLoadMetricSpecification field's value.
1947func (s *ScalingInstruction) SetPredefinedLoadMetricSpecification(v *PredefinedLoadMetricSpecification) *ScalingInstruction {
1948	s.PredefinedLoadMetricSpecification = v
1949	return s
1950}
1951
1952// SetPredictiveScalingMaxCapacityBehavior sets the PredictiveScalingMaxCapacityBehavior field's value.
1953func (s *ScalingInstruction) SetPredictiveScalingMaxCapacityBehavior(v string) *ScalingInstruction {
1954	s.PredictiveScalingMaxCapacityBehavior = &v
1955	return s
1956}
1957
1958// SetPredictiveScalingMaxCapacityBuffer sets the PredictiveScalingMaxCapacityBuffer field's value.
1959func (s *ScalingInstruction) SetPredictiveScalingMaxCapacityBuffer(v int64) *ScalingInstruction {
1960	s.PredictiveScalingMaxCapacityBuffer = &v
1961	return s
1962}
1963
1964// SetPredictiveScalingMode sets the PredictiveScalingMode field's value.
1965func (s *ScalingInstruction) SetPredictiveScalingMode(v string) *ScalingInstruction {
1966	s.PredictiveScalingMode = &v
1967	return s
1968}
1969
1970// SetResourceId sets the ResourceId field's value.
1971func (s *ScalingInstruction) SetResourceId(v string) *ScalingInstruction {
1972	s.ResourceId = &v
1973	return s
1974}
1975
1976// SetScalableDimension sets the ScalableDimension field's value.
1977func (s *ScalingInstruction) SetScalableDimension(v string) *ScalingInstruction {
1978	s.ScalableDimension = &v
1979	return s
1980}
1981
1982// SetScalingPolicyUpdateBehavior sets the ScalingPolicyUpdateBehavior field's value.
1983func (s *ScalingInstruction) SetScalingPolicyUpdateBehavior(v string) *ScalingInstruction {
1984	s.ScalingPolicyUpdateBehavior = &v
1985	return s
1986}
1987
1988// SetScheduledActionBufferTime sets the ScheduledActionBufferTime field's value.
1989func (s *ScalingInstruction) SetScheduledActionBufferTime(v int64) *ScalingInstruction {
1990	s.ScheduledActionBufferTime = &v
1991	return s
1992}
1993
1994// SetServiceNamespace sets the ServiceNamespace field's value.
1995func (s *ScalingInstruction) SetServiceNamespace(v string) *ScalingInstruction {
1996	s.ServiceNamespace = &v
1997	return s
1998}
1999
2000// SetTargetTrackingConfigurations sets the TargetTrackingConfigurations field's value.
2001func (s *ScalingInstruction) SetTargetTrackingConfigurations(v []*TargetTrackingConfiguration) *ScalingInstruction {
2002	s.TargetTrackingConfigurations = v
2003	return s
2004}
2005
2006// Represents a scaling plan.
2007type ScalingPlan struct {
2008	_ struct{} `type:"structure"`
2009
2010	// The application source.
2011	//
2012	// ApplicationSource is a required field
2013	ApplicationSource *ApplicationSource `type:"structure" required:"true"`
2014
2015	// The Unix time stamp when the scaling plan was created.
2016	CreationTime *time.Time `type:"timestamp"`
2017
2018	// The scaling instructions.
2019	//
2020	// ScalingInstructions is a required field
2021	ScalingInstructions []*ScalingInstruction `type:"list" required:"true"`
2022
2023	// The name of the scaling plan.
2024	//
2025	// ScalingPlanName is a required field
2026	ScalingPlanName *string `min:"1" type:"string" required:"true"`
2027
2028	// The version number of the scaling plan.
2029	//
2030	// ScalingPlanVersion is a required field
2031	ScalingPlanVersion *int64 `type:"long" required:"true"`
2032
2033	// The status of the scaling plan.
2034	//
2035	//    * Active - The scaling plan is active.
2036	//
2037	//    * ActiveWithProblems - The scaling plan is active, but the scaling configuration
2038	//    for one or more resources could not be applied.
2039	//
2040	//    * CreationInProgress - The scaling plan is being created.
2041	//
2042	//    * CreationFailed - The scaling plan could not be created.
2043	//
2044	//    * DeletionInProgress - The scaling plan is being deleted.
2045	//
2046	//    * DeletionFailed - The scaling plan could not be deleted.
2047	//
2048	//    * UpdateInProgress - The scaling plan is being updated.
2049	//
2050	//    * UpdateFailed - The scaling plan could not be updated.
2051	//
2052	// StatusCode is a required field
2053	StatusCode *string `type:"string" required:"true" enum:"ScalingPlanStatusCode"`
2054
2055	// A simple message about the current status of the scaling plan.
2056	StatusMessage *string `type:"string"`
2057
2058	// The Unix time stamp when the scaling plan entered the current status.
2059	StatusStartTime *time.Time `type:"timestamp"`
2060}
2061
2062// String returns the string representation
2063func (s ScalingPlan) String() string {
2064	return awsutil.Prettify(s)
2065}
2066
2067// GoString returns the string representation
2068func (s ScalingPlan) GoString() string {
2069	return s.String()
2070}
2071
2072// SetApplicationSource sets the ApplicationSource field's value.
2073func (s *ScalingPlan) SetApplicationSource(v *ApplicationSource) *ScalingPlan {
2074	s.ApplicationSource = v
2075	return s
2076}
2077
2078// SetCreationTime sets the CreationTime field's value.
2079func (s *ScalingPlan) SetCreationTime(v time.Time) *ScalingPlan {
2080	s.CreationTime = &v
2081	return s
2082}
2083
2084// SetScalingInstructions sets the ScalingInstructions field's value.
2085func (s *ScalingPlan) SetScalingInstructions(v []*ScalingInstruction) *ScalingPlan {
2086	s.ScalingInstructions = v
2087	return s
2088}
2089
2090// SetScalingPlanName sets the ScalingPlanName field's value.
2091func (s *ScalingPlan) SetScalingPlanName(v string) *ScalingPlan {
2092	s.ScalingPlanName = &v
2093	return s
2094}
2095
2096// SetScalingPlanVersion sets the ScalingPlanVersion field's value.
2097func (s *ScalingPlan) SetScalingPlanVersion(v int64) *ScalingPlan {
2098	s.ScalingPlanVersion = &v
2099	return s
2100}
2101
2102// SetStatusCode sets the StatusCode field's value.
2103func (s *ScalingPlan) SetStatusCode(v string) *ScalingPlan {
2104	s.StatusCode = &v
2105	return s
2106}
2107
2108// SetStatusMessage sets the StatusMessage field's value.
2109func (s *ScalingPlan) SetStatusMessage(v string) *ScalingPlan {
2110	s.StatusMessage = &v
2111	return s
2112}
2113
2114// SetStatusStartTime sets the StatusStartTime field's value.
2115func (s *ScalingPlan) SetStatusStartTime(v time.Time) *ScalingPlan {
2116	s.StatusStartTime = &v
2117	return s
2118}
2119
2120// Represents a scalable resource.
2121type ScalingPlanResource struct {
2122	_ struct{} `type:"structure"`
2123
2124	// The ID of the resource. This string consists of the resource type and unique
2125	// identifier.
2126	//
2127	//    * Auto Scaling group - The resource type is autoScalingGroup and the unique
2128	//    identifier is the name of the Auto Scaling group. Example: autoScalingGroup/my-asg.
2129	//
2130	//    * ECS service - The resource type is service and the unique identifier
2131	//    is the cluster name and service name. Example: service/default/sample-webapp.
2132	//
2133	//    * Spot Fleet request - The resource type is spot-fleet-request and the
2134	//    unique identifier is the Spot Fleet request ID. Example: spot-fleet-request/sfr-73fbd2ce-aa30-494c-8788-1cee4EXAMPLE.
2135	//
2136	//    * DynamoDB table - The resource type is table and the unique identifier
2137	//    is the resource ID. Example: table/my-table.
2138	//
2139	//    * DynamoDB global secondary index - The resource type is index and the
2140	//    unique identifier is the resource ID. Example: table/my-table/index/my-table-index.
2141	//
2142	//    * Aurora DB cluster - The resource type is cluster and the unique identifier
2143	//    is the cluster name. Example: cluster:my-db-cluster.
2144	//
2145	// ResourceId is a required field
2146	ResourceId *string `min:"1" type:"string" required:"true"`
2147
2148	// The scalable dimension for the resource.
2149	//
2150	//    * autoscaling:autoScalingGroup:DesiredCapacity - The desired capacity
2151	//    of an Auto Scaling group.
2152	//
2153	//    * ecs:service:DesiredCount - The desired task count of an ECS service.
2154	//
2155	//    * ec2:spot-fleet-request:TargetCapacity - The target capacity of a Spot
2156	//    Fleet request.
2157	//
2158	//    * dynamodb:table:ReadCapacityUnits - The provisioned read capacity for
2159	//    a DynamoDB table.
2160	//
2161	//    * dynamodb:table:WriteCapacityUnits - The provisioned write capacity for
2162	//    a DynamoDB table.
2163	//
2164	//    * dynamodb:index:ReadCapacityUnits - The provisioned read capacity for
2165	//    a DynamoDB global secondary index.
2166	//
2167	//    * dynamodb:index:WriteCapacityUnits - The provisioned write capacity for
2168	//    a DynamoDB global secondary index.
2169	//
2170	//    * rds:cluster:ReadReplicaCount - The count of Aurora Replicas in an Aurora
2171	//    DB cluster. Available for Aurora MySQL-compatible edition and Aurora PostgreSQL-compatible
2172	//    edition.
2173	//
2174	// ScalableDimension is a required field
2175	ScalableDimension *string `type:"string" required:"true" enum:"ScalableDimension"`
2176
2177	// The name of the scaling plan.
2178	//
2179	// ScalingPlanName is a required field
2180	ScalingPlanName *string `min:"1" type:"string" required:"true"`
2181
2182	// The version number of the scaling plan.
2183	//
2184	// ScalingPlanVersion is a required field
2185	ScalingPlanVersion *int64 `type:"long" required:"true"`
2186
2187	// The scaling policies.
2188	ScalingPolicies []*ScalingPolicy `type:"list"`
2189
2190	// The scaling status of the resource.
2191	//
2192	//    * Active - The scaling configuration is active.
2193	//
2194	//    * Inactive - The scaling configuration is not active because the scaling
2195	//    plan is being created or the scaling configuration could not be applied.
2196	//    Check the status message for more information.
2197	//
2198	//    * PartiallyActive - The scaling configuration is partially active because
2199	//    the scaling plan is being created or deleted or the scaling configuration
2200	//    could not be fully applied. Check the status message for more information.
2201	//
2202	// ScalingStatusCode is a required field
2203	ScalingStatusCode *string `type:"string" required:"true" enum:"ScalingStatusCode"`
2204
2205	// A simple message about the current scaling status of the resource.
2206	ScalingStatusMessage *string `type:"string"`
2207
2208	// The namespace of the AWS service.
2209	//
2210	// ServiceNamespace is a required field
2211	ServiceNamespace *string `type:"string" required:"true" enum:"ServiceNamespace"`
2212}
2213
2214// String returns the string representation
2215func (s ScalingPlanResource) String() string {
2216	return awsutil.Prettify(s)
2217}
2218
2219// GoString returns the string representation
2220func (s ScalingPlanResource) GoString() string {
2221	return s.String()
2222}
2223
2224// SetResourceId sets the ResourceId field's value.
2225func (s *ScalingPlanResource) SetResourceId(v string) *ScalingPlanResource {
2226	s.ResourceId = &v
2227	return s
2228}
2229
2230// SetScalableDimension sets the ScalableDimension field's value.
2231func (s *ScalingPlanResource) SetScalableDimension(v string) *ScalingPlanResource {
2232	s.ScalableDimension = &v
2233	return s
2234}
2235
2236// SetScalingPlanName sets the ScalingPlanName field's value.
2237func (s *ScalingPlanResource) SetScalingPlanName(v string) *ScalingPlanResource {
2238	s.ScalingPlanName = &v
2239	return s
2240}
2241
2242// SetScalingPlanVersion sets the ScalingPlanVersion field's value.
2243func (s *ScalingPlanResource) SetScalingPlanVersion(v int64) *ScalingPlanResource {
2244	s.ScalingPlanVersion = &v
2245	return s
2246}
2247
2248// SetScalingPolicies sets the ScalingPolicies field's value.
2249func (s *ScalingPlanResource) SetScalingPolicies(v []*ScalingPolicy) *ScalingPlanResource {
2250	s.ScalingPolicies = v
2251	return s
2252}
2253
2254// SetScalingStatusCode sets the ScalingStatusCode field's value.
2255func (s *ScalingPlanResource) SetScalingStatusCode(v string) *ScalingPlanResource {
2256	s.ScalingStatusCode = &v
2257	return s
2258}
2259
2260// SetScalingStatusMessage sets the ScalingStatusMessage field's value.
2261func (s *ScalingPlanResource) SetScalingStatusMessage(v string) *ScalingPlanResource {
2262	s.ScalingStatusMessage = &v
2263	return s
2264}
2265
2266// SetServiceNamespace sets the ServiceNamespace field's value.
2267func (s *ScalingPlanResource) SetServiceNamespace(v string) *ScalingPlanResource {
2268	s.ServiceNamespace = &v
2269	return s
2270}
2271
2272// Represents a scaling policy.
2273type ScalingPolicy struct {
2274	_ struct{} `type:"structure"`
2275
2276	// The name of the scaling policy.
2277	//
2278	// PolicyName is a required field
2279	PolicyName *string `min:"1" type:"string" required:"true"`
2280
2281	// The type of scaling policy.
2282	//
2283	// PolicyType is a required field
2284	PolicyType *string `type:"string" required:"true" enum:"PolicyType"`
2285
2286	// The target tracking scaling policy. Includes support for predefined or customized
2287	// metrics.
2288	TargetTrackingConfiguration *TargetTrackingConfiguration `type:"structure"`
2289}
2290
2291// String returns the string representation
2292func (s ScalingPolicy) String() string {
2293	return awsutil.Prettify(s)
2294}
2295
2296// GoString returns the string representation
2297func (s ScalingPolicy) GoString() string {
2298	return s.String()
2299}
2300
2301// SetPolicyName sets the PolicyName field's value.
2302func (s *ScalingPolicy) SetPolicyName(v string) *ScalingPolicy {
2303	s.PolicyName = &v
2304	return s
2305}
2306
2307// SetPolicyType sets the PolicyType field's value.
2308func (s *ScalingPolicy) SetPolicyType(v string) *ScalingPolicy {
2309	s.PolicyType = &v
2310	return s
2311}
2312
2313// SetTargetTrackingConfiguration sets the TargetTrackingConfiguration field's value.
2314func (s *ScalingPolicy) SetTargetTrackingConfiguration(v *TargetTrackingConfiguration) *ScalingPolicy {
2315	s.TargetTrackingConfiguration = v
2316	return s
2317}
2318
2319// Represents a tag.
2320type TagFilter struct {
2321	_ struct{} `type:"structure"`
2322
2323	// The tag key.
2324	Key *string `min:"1" type:"string"`
2325
2326	// The tag values (0 to 20).
2327	Values []*string `type:"list"`
2328}
2329
2330// String returns the string representation
2331func (s TagFilter) String() string {
2332	return awsutil.Prettify(s)
2333}
2334
2335// GoString returns the string representation
2336func (s TagFilter) GoString() string {
2337	return s.String()
2338}
2339
2340// Validate inspects the fields of the type to determine if they are valid.
2341func (s *TagFilter) Validate() error {
2342	invalidParams := request.ErrInvalidParams{Context: "TagFilter"}
2343	if s.Key != nil && len(*s.Key) < 1 {
2344		invalidParams.Add(request.NewErrParamMinLen("Key", 1))
2345	}
2346
2347	if invalidParams.Len() > 0 {
2348		return invalidParams
2349	}
2350	return nil
2351}
2352
2353// SetKey sets the Key field's value.
2354func (s *TagFilter) SetKey(v string) *TagFilter {
2355	s.Key = &v
2356	return s
2357}
2358
2359// SetValues sets the Values field's value.
2360func (s *TagFilter) SetValues(v []*string) *TagFilter {
2361	s.Values = v
2362	return s
2363}
2364
2365// Describes a target tracking configuration to use with AWS Auto Scaling. Used
2366// with ScalingInstruction and ScalingPolicy.
2367type TargetTrackingConfiguration struct {
2368	_ struct{} `type:"structure"`
2369
2370	// A customized metric. You can specify either a predefined metric or a customized
2371	// metric.
2372	CustomizedScalingMetricSpecification *CustomizedScalingMetricSpecification `type:"structure"`
2373
2374	// Indicates whether scale in by the target tracking scaling policy is disabled.
2375	// If the value is true, scale in is disabled and the target tracking scaling
2376	// policy doesn't remove capacity from the scalable resource. Otherwise, scale
2377	// in is enabled and the target tracking scaling policy can remove capacity
2378	// from the scalable resource.
2379	//
2380	// The default value is false.
2381	DisableScaleIn *bool `type:"boolean"`
2382
2383	// The estimated time, in seconds, until a newly launched instance can contribute
2384	// to the CloudWatch metrics. This value is used only if the resource is an
2385	// Auto Scaling group.
2386	EstimatedInstanceWarmup *int64 `type:"integer"`
2387
2388	// A predefined metric. You can specify either a predefined metric or a customized
2389	// metric.
2390	PredefinedScalingMetricSpecification *PredefinedScalingMetricSpecification `type:"structure"`
2391
2392	// The amount of time, in seconds, after a scale in activity completes before
2393	// another scale in activity can start. This value is not used if the scalable
2394	// resource is an Auto Scaling group.
2395	//
2396	// The cooldown period is used to block subsequent scale in requests until it
2397	// has expired. The intention is to scale in conservatively to protect your
2398	// application's availability. However, if another alarm triggers a scale-out
2399	// policy during the cooldown period after a scale-in, AWS Auto Scaling scales
2400	// out your scalable target immediately.
2401	ScaleInCooldown *int64 `type:"integer"`
2402
2403	// The amount of time, in seconds, after a scale-out activity completes before
2404	// another scale-out activity can start. This value is not used if the scalable
2405	// resource is an Auto Scaling group.
2406	//
2407	// While the cooldown period is in effect, the capacity that has been added
2408	// by the previous scale-out event that initiated the cooldown is calculated
2409	// as part of the desired capacity for the next scale out. The intention is
2410	// to continuously (but not excessively) scale out.
2411	ScaleOutCooldown *int64 `type:"integer"`
2412
2413	// The target value for the metric. The range is 8.515920e-109 to 1.174271e+108
2414	// (Base 10) or 2e-360 to 2e360 (Base 2).
2415	//
2416	// TargetValue is a required field
2417	TargetValue *float64 `type:"double" required:"true"`
2418}
2419
2420// String returns the string representation
2421func (s TargetTrackingConfiguration) String() string {
2422	return awsutil.Prettify(s)
2423}
2424
2425// GoString returns the string representation
2426func (s TargetTrackingConfiguration) GoString() string {
2427	return s.String()
2428}
2429
2430// Validate inspects the fields of the type to determine if they are valid.
2431func (s *TargetTrackingConfiguration) Validate() error {
2432	invalidParams := request.ErrInvalidParams{Context: "TargetTrackingConfiguration"}
2433	if s.TargetValue == nil {
2434		invalidParams.Add(request.NewErrParamRequired("TargetValue"))
2435	}
2436	if s.CustomizedScalingMetricSpecification != nil {
2437		if err := s.CustomizedScalingMetricSpecification.Validate(); err != nil {
2438			invalidParams.AddNested("CustomizedScalingMetricSpecification", err.(request.ErrInvalidParams))
2439		}
2440	}
2441	if s.PredefinedScalingMetricSpecification != nil {
2442		if err := s.PredefinedScalingMetricSpecification.Validate(); err != nil {
2443			invalidParams.AddNested("PredefinedScalingMetricSpecification", err.(request.ErrInvalidParams))
2444		}
2445	}
2446
2447	if invalidParams.Len() > 0 {
2448		return invalidParams
2449	}
2450	return nil
2451}
2452
2453// SetCustomizedScalingMetricSpecification sets the CustomizedScalingMetricSpecification field's value.
2454func (s *TargetTrackingConfiguration) SetCustomizedScalingMetricSpecification(v *CustomizedScalingMetricSpecification) *TargetTrackingConfiguration {
2455	s.CustomizedScalingMetricSpecification = v
2456	return s
2457}
2458
2459// SetDisableScaleIn sets the DisableScaleIn field's value.
2460func (s *TargetTrackingConfiguration) SetDisableScaleIn(v bool) *TargetTrackingConfiguration {
2461	s.DisableScaleIn = &v
2462	return s
2463}
2464
2465// SetEstimatedInstanceWarmup sets the EstimatedInstanceWarmup field's value.
2466func (s *TargetTrackingConfiguration) SetEstimatedInstanceWarmup(v int64) *TargetTrackingConfiguration {
2467	s.EstimatedInstanceWarmup = &v
2468	return s
2469}
2470
2471// SetPredefinedScalingMetricSpecification sets the PredefinedScalingMetricSpecification field's value.
2472func (s *TargetTrackingConfiguration) SetPredefinedScalingMetricSpecification(v *PredefinedScalingMetricSpecification) *TargetTrackingConfiguration {
2473	s.PredefinedScalingMetricSpecification = v
2474	return s
2475}
2476
2477// SetScaleInCooldown sets the ScaleInCooldown field's value.
2478func (s *TargetTrackingConfiguration) SetScaleInCooldown(v int64) *TargetTrackingConfiguration {
2479	s.ScaleInCooldown = &v
2480	return s
2481}
2482
2483// SetScaleOutCooldown sets the ScaleOutCooldown field's value.
2484func (s *TargetTrackingConfiguration) SetScaleOutCooldown(v int64) *TargetTrackingConfiguration {
2485	s.ScaleOutCooldown = &v
2486	return s
2487}
2488
2489// SetTargetValue sets the TargetValue field's value.
2490func (s *TargetTrackingConfiguration) SetTargetValue(v float64) *TargetTrackingConfiguration {
2491	s.TargetValue = &v
2492	return s
2493}
2494
2495type UpdateScalingPlanInput struct {
2496	_ struct{} `type:"structure"`
2497
2498	// A CloudFormation stack or set of tags.
2499	ApplicationSource *ApplicationSource `type:"structure"`
2500
2501	// The scaling instructions.
2502	ScalingInstructions []*ScalingInstruction `type:"list"`
2503
2504	// The name of the scaling plan.
2505	//
2506	// ScalingPlanName is a required field
2507	ScalingPlanName *string `min:"1" type:"string" required:"true"`
2508
2509	// The version number of the scaling plan.
2510	//
2511	// ScalingPlanVersion is a required field
2512	ScalingPlanVersion *int64 `type:"long" required:"true"`
2513}
2514
2515// String returns the string representation
2516func (s UpdateScalingPlanInput) String() string {
2517	return awsutil.Prettify(s)
2518}
2519
2520// GoString returns the string representation
2521func (s UpdateScalingPlanInput) GoString() string {
2522	return s.String()
2523}
2524
2525// Validate inspects the fields of the type to determine if they are valid.
2526func (s *UpdateScalingPlanInput) Validate() error {
2527	invalidParams := request.ErrInvalidParams{Context: "UpdateScalingPlanInput"}
2528	if s.ScalingPlanName == nil {
2529		invalidParams.Add(request.NewErrParamRequired("ScalingPlanName"))
2530	}
2531	if s.ScalingPlanName != nil && len(*s.ScalingPlanName) < 1 {
2532		invalidParams.Add(request.NewErrParamMinLen("ScalingPlanName", 1))
2533	}
2534	if s.ScalingPlanVersion == nil {
2535		invalidParams.Add(request.NewErrParamRequired("ScalingPlanVersion"))
2536	}
2537	if s.ApplicationSource != nil {
2538		if err := s.ApplicationSource.Validate(); err != nil {
2539			invalidParams.AddNested("ApplicationSource", err.(request.ErrInvalidParams))
2540		}
2541	}
2542	if s.ScalingInstructions != nil {
2543		for i, v := range s.ScalingInstructions {
2544			if v == nil {
2545				continue
2546			}
2547			if err := v.Validate(); err != nil {
2548				invalidParams.AddNested(fmt.Sprintf("%s[%v]", "ScalingInstructions", i), err.(request.ErrInvalidParams))
2549			}
2550		}
2551	}
2552
2553	if invalidParams.Len() > 0 {
2554		return invalidParams
2555	}
2556	return nil
2557}
2558
2559// SetApplicationSource sets the ApplicationSource field's value.
2560func (s *UpdateScalingPlanInput) SetApplicationSource(v *ApplicationSource) *UpdateScalingPlanInput {
2561	s.ApplicationSource = v
2562	return s
2563}
2564
2565// SetScalingInstructions sets the ScalingInstructions field's value.
2566func (s *UpdateScalingPlanInput) SetScalingInstructions(v []*ScalingInstruction) *UpdateScalingPlanInput {
2567	s.ScalingInstructions = v
2568	return s
2569}
2570
2571// SetScalingPlanName sets the ScalingPlanName field's value.
2572func (s *UpdateScalingPlanInput) SetScalingPlanName(v string) *UpdateScalingPlanInput {
2573	s.ScalingPlanName = &v
2574	return s
2575}
2576
2577// SetScalingPlanVersion sets the ScalingPlanVersion field's value.
2578func (s *UpdateScalingPlanInput) SetScalingPlanVersion(v int64) *UpdateScalingPlanInput {
2579	s.ScalingPlanVersion = &v
2580	return s
2581}
2582
2583type UpdateScalingPlanOutput struct {
2584	_ struct{} `type:"structure"`
2585}
2586
2587// String returns the string representation
2588func (s UpdateScalingPlanOutput) String() string {
2589	return awsutil.Prettify(s)
2590}
2591
2592// GoString returns the string representation
2593func (s UpdateScalingPlanOutput) GoString() string {
2594	return s.String()
2595}
2596
2597const (
2598	// ForecastDataTypeCapacityForecast is a ForecastDataType enum value
2599	ForecastDataTypeCapacityForecast = "CapacityForecast"
2600
2601	// ForecastDataTypeLoadForecast is a ForecastDataType enum value
2602	ForecastDataTypeLoadForecast = "LoadForecast"
2603
2604	// ForecastDataTypeScheduledActionMinCapacity is a ForecastDataType enum value
2605	ForecastDataTypeScheduledActionMinCapacity = "ScheduledActionMinCapacity"
2606
2607	// ForecastDataTypeScheduledActionMaxCapacity is a ForecastDataType enum value
2608	ForecastDataTypeScheduledActionMaxCapacity = "ScheduledActionMaxCapacity"
2609)
2610
2611const (
2612	// LoadMetricTypeAsgtotalCpuutilization is a LoadMetricType enum value
2613	LoadMetricTypeAsgtotalCpuutilization = "ASGTotalCPUUtilization"
2614
2615	// LoadMetricTypeAsgtotalNetworkIn is a LoadMetricType enum value
2616	LoadMetricTypeAsgtotalNetworkIn = "ASGTotalNetworkIn"
2617
2618	// LoadMetricTypeAsgtotalNetworkOut is a LoadMetricType enum value
2619	LoadMetricTypeAsgtotalNetworkOut = "ASGTotalNetworkOut"
2620
2621	// LoadMetricTypeAlbtargetGroupRequestCount is a LoadMetricType enum value
2622	LoadMetricTypeAlbtargetGroupRequestCount = "ALBTargetGroupRequestCount"
2623)
2624
2625const (
2626	// MetricStatisticAverage is a MetricStatistic enum value
2627	MetricStatisticAverage = "Average"
2628
2629	// MetricStatisticMinimum is a MetricStatistic enum value
2630	MetricStatisticMinimum = "Minimum"
2631
2632	// MetricStatisticMaximum is a MetricStatistic enum value
2633	MetricStatisticMaximum = "Maximum"
2634
2635	// MetricStatisticSampleCount is a MetricStatistic enum value
2636	MetricStatisticSampleCount = "SampleCount"
2637
2638	// MetricStatisticSum is a MetricStatistic enum value
2639	MetricStatisticSum = "Sum"
2640)
2641
2642const (
2643	// PolicyTypeTargetTrackingScaling is a PolicyType enum value
2644	PolicyTypeTargetTrackingScaling = "TargetTrackingScaling"
2645)
2646
2647const (
2648	// PredictiveScalingMaxCapacityBehaviorSetForecastCapacityToMaxCapacity is a PredictiveScalingMaxCapacityBehavior enum value
2649	PredictiveScalingMaxCapacityBehaviorSetForecastCapacityToMaxCapacity = "SetForecastCapacityToMaxCapacity"
2650
2651	// PredictiveScalingMaxCapacityBehaviorSetMaxCapacityToForecastCapacity is a PredictiveScalingMaxCapacityBehavior enum value
2652	PredictiveScalingMaxCapacityBehaviorSetMaxCapacityToForecastCapacity = "SetMaxCapacityToForecastCapacity"
2653
2654	// PredictiveScalingMaxCapacityBehaviorSetMaxCapacityAboveForecastCapacity is a PredictiveScalingMaxCapacityBehavior enum value
2655	PredictiveScalingMaxCapacityBehaviorSetMaxCapacityAboveForecastCapacity = "SetMaxCapacityAboveForecastCapacity"
2656)
2657
2658const (
2659	// PredictiveScalingModeForecastAndScale is a PredictiveScalingMode enum value
2660	PredictiveScalingModeForecastAndScale = "ForecastAndScale"
2661
2662	// PredictiveScalingModeForecastOnly is a PredictiveScalingMode enum value
2663	PredictiveScalingModeForecastOnly = "ForecastOnly"
2664)
2665
2666const (
2667	// ScalableDimensionAutoscalingAutoScalingGroupDesiredCapacity is a ScalableDimension enum value
2668	ScalableDimensionAutoscalingAutoScalingGroupDesiredCapacity = "autoscaling:autoScalingGroup:DesiredCapacity"
2669
2670	// ScalableDimensionEcsServiceDesiredCount is a ScalableDimension enum value
2671	ScalableDimensionEcsServiceDesiredCount = "ecs:service:DesiredCount"
2672
2673	// ScalableDimensionEc2SpotFleetRequestTargetCapacity is a ScalableDimension enum value
2674	ScalableDimensionEc2SpotFleetRequestTargetCapacity = "ec2:spot-fleet-request:TargetCapacity"
2675
2676	// ScalableDimensionRdsClusterReadReplicaCount is a ScalableDimension enum value
2677	ScalableDimensionRdsClusterReadReplicaCount = "rds:cluster:ReadReplicaCount"
2678
2679	// ScalableDimensionDynamodbTableReadCapacityUnits is a ScalableDimension enum value
2680	ScalableDimensionDynamodbTableReadCapacityUnits = "dynamodb:table:ReadCapacityUnits"
2681
2682	// ScalableDimensionDynamodbTableWriteCapacityUnits is a ScalableDimension enum value
2683	ScalableDimensionDynamodbTableWriteCapacityUnits = "dynamodb:table:WriteCapacityUnits"
2684
2685	// ScalableDimensionDynamodbIndexReadCapacityUnits is a ScalableDimension enum value
2686	ScalableDimensionDynamodbIndexReadCapacityUnits = "dynamodb:index:ReadCapacityUnits"
2687
2688	// ScalableDimensionDynamodbIndexWriteCapacityUnits is a ScalableDimension enum value
2689	ScalableDimensionDynamodbIndexWriteCapacityUnits = "dynamodb:index:WriteCapacityUnits"
2690)
2691
2692const (
2693	// ScalingMetricTypeAsgaverageCpuutilization is a ScalingMetricType enum value
2694	ScalingMetricTypeAsgaverageCpuutilization = "ASGAverageCPUUtilization"
2695
2696	// ScalingMetricTypeAsgaverageNetworkIn is a ScalingMetricType enum value
2697	ScalingMetricTypeAsgaverageNetworkIn = "ASGAverageNetworkIn"
2698
2699	// ScalingMetricTypeAsgaverageNetworkOut is a ScalingMetricType enum value
2700	ScalingMetricTypeAsgaverageNetworkOut = "ASGAverageNetworkOut"
2701
2702	// ScalingMetricTypeDynamoDbreadCapacityUtilization is a ScalingMetricType enum value
2703	ScalingMetricTypeDynamoDbreadCapacityUtilization = "DynamoDBReadCapacityUtilization"
2704
2705	// ScalingMetricTypeDynamoDbwriteCapacityUtilization is a ScalingMetricType enum value
2706	ScalingMetricTypeDynamoDbwriteCapacityUtilization = "DynamoDBWriteCapacityUtilization"
2707
2708	// ScalingMetricTypeEcsserviceAverageCpuutilization is a ScalingMetricType enum value
2709	ScalingMetricTypeEcsserviceAverageCpuutilization = "ECSServiceAverageCPUUtilization"
2710
2711	// ScalingMetricTypeEcsserviceAverageMemoryUtilization is a ScalingMetricType enum value
2712	ScalingMetricTypeEcsserviceAverageMemoryUtilization = "ECSServiceAverageMemoryUtilization"
2713
2714	// ScalingMetricTypeAlbrequestCountPerTarget is a ScalingMetricType enum value
2715	ScalingMetricTypeAlbrequestCountPerTarget = "ALBRequestCountPerTarget"
2716
2717	// ScalingMetricTypeRdsreaderAverageCpuutilization is a ScalingMetricType enum value
2718	ScalingMetricTypeRdsreaderAverageCpuutilization = "RDSReaderAverageCPUUtilization"
2719
2720	// ScalingMetricTypeRdsreaderAverageDatabaseConnections is a ScalingMetricType enum value
2721	ScalingMetricTypeRdsreaderAverageDatabaseConnections = "RDSReaderAverageDatabaseConnections"
2722
2723	// ScalingMetricTypeEc2spotFleetRequestAverageCpuutilization is a ScalingMetricType enum value
2724	ScalingMetricTypeEc2spotFleetRequestAverageCpuutilization = "EC2SpotFleetRequestAverageCPUUtilization"
2725
2726	// ScalingMetricTypeEc2spotFleetRequestAverageNetworkIn is a ScalingMetricType enum value
2727	ScalingMetricTypeEc2spotFleetRequestAverageNetworkIn = "EC2SpotFleetRequestAverageNetworkIn"
2728
2729	// ScalingMetricTypeEc2spotFleetRequestAverageNetworkOut is a ScalingMetricType enum value
2730	ScalingMetricTypeEc2spotFleetRequestAverageNetworkOut = "EC2SpotFleetRequestAverageNetworkOut"
2731)
2732
2733const (
2734	// ScalingPlanStatusCodeActive is a ScalingPlanStatusCode enum value
2735	ScalingPlanStatusCodeActive = "Active"
2736
2737	// ScalingPlanStatusCodeActiveWithProblems is a ScalingPlanStatusCode enum value
2738	ScalingPlanStatusCodeActiveWithProblems = "ActiveWithProblems"
2739
2740	// ScalingPlanStatusCodeCreationInProgress is a ScalingPlanStatusCode enum value
2741	ScalingPlanStatusCodeCreationInProgress = "CreationInProgress"
2742
2743	// ScalingPlanStatusCodeCreationFailed is a ScalingPlanStatusCode enum value
2744	ScalingPlanStatusCodeCreationFailed = "CreationFailed"
2745
2746	// ScalingPlanStatusCodeDeletionInProgress is a ScalingPlanStatusCode enum value
2747	ScalingPlanStatusCodeDeletionInProgress = "DeletionInProgress"
2748
2749	// ScalingPlanStatusCodeDeletionFailed is a ScalingPlanStatusCode enum value
2750	ScalingPlanStatusCodeDeletionFailed = "DeletionFailed"
2751
2752	// ScalingPlanStatusCodeUpdateInProgress is a ScalingPlanStatusCode enum value
2753	ScalingPlanStatusCodeUpdateInProgress = "UpdateInProgress"
2754
2755	// ScalingPlanStatusCodeUpdateFailed is a ScalingPlanStatusCode enum value
2756	ScalingPlanStatusCodeUpdateFailed = "UpdateFailed"
2757)
2758
2759const (
2760	// ScalingPolicyUpdateBehaviorKeepExternalPolicies is a ScalingPolicyUpdateBehavior enum value
2761	ScalingPolicyUpdateBehaviorKeepExternalPolicies = "KeepExternalPolicies"
2762
2763	// ScalingPolicyUpdateBehaviorReplaceExternalPolicies is a ScalingPolicyUpdateBehavior enum value
2764	ScalingPolicyUpdateBehaviorReplaceExternalPolicies = "ReplaceExternalPolicies"
2765)
2766
2767const (
2768	// ScalingStatusCodeInactive is a ScalingStatusCode enum value
2769	ScalingStatusCodeInactive = "Inactive"
2770
2771	// ScalingStatusCodePartiallyActive is a ScalingStatusCode enum value
2772	ScalingStatusCodePartiallyActive = "PartiallyActive"
2773
2774	// ScalingStatusCodeActive is a ScalingStatusCode enum value
2775	ScalingStatusCodeActive = "Active"
2776)
2777
2778const (
2779	// ServiceNamespaceAutoscaling is a ServiceNamespace enum value
2780	ServiceNamespaceAutoscaling = "autoscaling"
2781
2782	// ServiceNamespaceEcs is a ServiceNamespace enum value
2783	ServiceNamespaceEcs = "ecs"
2784
2785	// ServiceNamespaceEc2 is a ServiceNamespace enum value
2786	ServiceNamespaceEc2 = "ec2"
2787
2788	// ServiceNamespaceRds is a ServiceNamespace enum value
2789	ServiceNamespaceRds = "rds"
2790
2791	// ServiceNamespaceDynamodb is a ServiceNamespace enum value
2792	ServiceNamespaceDynamodb = "dynamodb"
2793)
2794