/*
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License").
* You may not use this file except in compliance with the License.
* A copy of the License is located at
*
* http://aws.amazon.com/apache2.0
*
* or in the "license" file accompanying this file. This file is distributed
* on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
* express or implied. See the License for the specific language governing
* permissions and limitations under the License.
*/
/*
* Do not modify this file. This file is generated from the apprunner-2020-05-15.normal.json service model.
*/
using System;
using System.Collections.Generic;
using System.Xml.Serialization;
using System.Text;
using System.IO;
using System.Net;
using Amazon.Runtime;
using Amazon.Runtime.Internal;
namespace Amazon.AppRunner.Model
{
///
/// Container for the parameters to the CreateAutoScalingConfiguration operation.
/// Create an App Runner automatic scaling configuration resource. App Runner requires
/// this resource when you create or update App Runner services and you require non-default
/// auto scaling settings. You can share an auto scaling configuration across multiple
/// services.
///
///
///
/// Create multiple revisions of a configuration by calling this action multiple times
/// using the same AutoScalingConfigurationName
. The call returns incremental
/// AutoScalingConfigurationRevision
values. When you create a service and
/// configure an auto scaling configuration resource, the service uses the latest active
/// revision of the auto scaling configuration by default. You can optionally configure
/// the service to use a specific revision.
///
///
///
/// Configure a higher MinSize
to increase the spread of your App Runner
/// service over more Availability Zones in the Amazon Web Services Region. The tradeoff
/// is a higher minimal cost.
///
///
///
/// Configure a lower MaxSize
to control your cost. The tradeoff is lower
/// responsiveness during peak demand.
///
///
public partial class CreateAutoScalingConfigurationRequest : AmazonAppRunnerRequest
{
private string _autoScalingConfigurationName;
private int? _maxConcurrency;
private int? _maxSize;
private int? _minSize;
private List _tags = new List();
///
/// Gets and sets the property AutoScalingConfigurationName.
///
/// A name for the auto scaling configuration. When you use it for the first time in an
/// Amazon Web Services Region, App Runner creates revision number 1
of this
/// name. When you use the same name in subsequent calls, App Runner creates incremental
/// revisions of the configuration.
///
///
///
/// The name DefaultConfiguration
is reserved (it's the configuration that
/// App Runner uses if you don't provide a custome one). You can't use it to create a
/// new auto scaling configuration, and you can't create a revision of it.
///
///
///
/// When you want to use your own auto scaling configuration for your App Runner service,
/// create a configuration with a different name, and then provide it when you
/// create or update your service.
///
///
///
[AWSProperty(Required=true, Min=4, Max=32)]
public string AutoScalingConfigurationName
{
get { return this._autoScalingConfigurationName; }
set { this._autoScalingConfigurationName = value; }
}
// Check to see if AutoScalingConfigurationName property is set
internal bool IsSetAutoScalingConfigurationName()
{
return this._autoScalingConfigurationName != null;
}
///
/// Gets and sets the property MaxConcurrency.
///
/// The maximum number of concurrent requests that you want an instance to process. If
/// the number of concurrent requests exceeds this limit, App Runner scales up your service.
///
///
///
/// Default: 100
///
///
[AWSProperty(Min=1, Max=200)]
public int MaxConcurrency
{
get { return this._maxConcurrency.GetValueOrDefault(); }
set { this._maxConcurrency = value; }
}
// Check to see if MaxConcurrency property is set
internal bool IsSetMaxConcurrency()
{
return this._maxConcurrency.HasValue;
}
///
/// Gets and sets the property MaxSize.
///
/// The maximum number of instances that your service scales up to. At most MaxSize
/// instances actively serve traffic for your service.
///
///
///
/// Default: 25
///
///
[AWSProperty(Min=1)]
public int MaxSize
{
get { return this._maxSize.GetValueOrDefault(); }
set { this._maxSize = value; }
}
// Check to see if MaxSize property is set
internal bool IsSetMaxSize()
{
return this._maxSize.HasValue;
}
///
/// Gets and sets the property MinSize.
///
/// The minimum number of instances that App Runner provisions for your service. The service
/// always has at least MinSize
provisioned instances. Some of them actively
/// serve traffic. The rest of them (provisioned and inactive instances) are a cost-effective
/// compute capacity reserve and are ready to be quickly activated. You pay for memory
/// usage of all the provisioned instances. You pay for CPU usage of only the active subset.
///
///
///
/// App Runner temporarily doubles the number of provisioned instances during deployments,
/// to maintain the same capacity for both old and new code.
///
///
///
/// Default: 1
///
///
[AWSProperty(Min=1, Max=25)]
public int MinSize
{
get { return this._minSize.GetValueOrDefault(); }
set { this._minSize = value; }
}
// Check to see if MinSize property is set
internal bool IsSetMinSize()
{
return this._minSize.HasValue;
}
///
/// Gets and sets the property Tags.
///
/// A list of metadata items that you can associate with your auto scaling configuration
/// resource. A tag is a key-value pair.
///
///
public List Tags
{
get { return this._tags; }
set { this._tags = value; }
}
// Check to see if Tags property is set
internal bool IsSetTags()
{
return this._tags != null && this._tags.Count > 0;
}
}
}