interface IBuildFleet
Language | Type name |
---|---|
.NET | Amazon.CDK.AWS.GameLift.Alpha.IBuildFleet |
Go | github.com/aws/aws-cdk-go/awscdkgameliftalpha/v2#IBuildFleet |
Java | software.amazon.awscdk.services.gamelift.alpha.IBuildFleet |
Python | aws_cdk.aws_gamelift_alpha.IBuildFleet |
TypeScript (source) | @aws-cdk/aws-gamelift-alpha ยป IBuildFleet |
Implemented by
Build
Obtainable from
Build
.fromBuildFleetArn()
, Build
.fromBuildFleetId()
Represents a GameLift Fleet used to run a custom game build.
Properties
Name | Type | Description |
---|---|---|
env | Resource | The environment this resource belongs to. |
fleet | string | The ARN of the fleet. |
fleet | string | The Identifier of the fleet. |
grant | IPrincipal | The principal to grant permissions to. |
node | Node | The tree node. |
resource | string | The ARN(s) to put into the destination field for a game session queue. |
stack | Stack | The stack in which this resource is defined. |
env
Type:
Resource
The environment this resource belongs to.
For resources that are created and managed by the CDK (generally, those created by creating new class instances like Role, Bucket, etc.), this is always the same as the environment of the stack they belong to; however, for imported resources (those obtained from static methods like fromRoleArn, fromBucketName, etc.), that might be different than the stack they were imported into.
fleetArn
Type:
string
The ARN of the fleet.
fleetId
Type:
string
The Identifier of the fleet.
grantPrincipal
Type:
IPrincipal
The principal to grant permissions to.
node
Type:
Node
The tree node.
resourceArnForDestination
Type:
string
The ARN(s) to put into the destination field for a game session queue.
This property is for cdk modules to consume only. You should not need to use this property. Instead, use dedicated identifier on each components.
stack
Type:
Stack
The stack in which this resource is defined.
Methods
Name | Description |
---|---|
apply | Apply the given removal policy to this resource. |
grant(grantee, ...actions) | Grant the grantee identity permissions to perform actions . |
metric(metricName, props?) | Return the given named metric for this fleet. |
metric | Instances with ACTIVE status, which means they are running active server processes. |
metric | Target number of active instances that GameLift is working to maintain in the fleet. |
metric | Active instances that are currently hosting zero (0) game sessions. |
metric | Number of spot instances that have been interrupted. |
metric | Maximum number of instances that are allowed for the fleet. |
metric | Minimum number of instances allowed for the fleet. |
metric | Percentage of all active instances that are idle (calculated as IdleInstances / ActiveInstances). |
RemovalPolicy(policy)
applypublic applyRemovalPolicy(policy: RemovalPolicy): void
Parameters
- policy
Removal
Policy
Apply the given removal policy to this resource.
The Removal Policy controls what happens to this resource when it stops being managed by CloudFormation, either because you've removed it from the CDK application or because you've made a change that requires the resource to be replaced.
The resource can be deleted (RemovalPolicy.DESTROY
), or left in your AWS
account for data recovery and cleanup later (RemovalPolicy.RETAIN
).
grant(grantee, ...actions)
public grant(grantee: IGrantable, ...actions: string[]): Grant
Parameters
- grantee
IGrantable
- actions
string
Returns
Grant the grantee
identity permissions to perform actions
.
metric(metricName, props?)
public metric(metricName: string, props?: MetricOptions): Metric
Parameters
- metricName
string
- props
Metric
Options
Returns
Return the given named metric for this fleet.
ActiveInstances(props?)
metricpublic metricActiveInstances(props?: MetricOptions): Metric
Parameters
- props
Metric
Options
Returns
Instances with ACTIVE
status, which means they are running active server processes.
The count includes idle instances and those that are hosting one or more game sessions. This metric measures current total instance capacity.
This metric can be used with automatic scaling.
DesiredInstances(props?)
metricpublic metricDesiredInstances(props?: MetricOptions): Metric
Parameters
- props
Metric
Options
Returns
Target number of active instances that GameLift is working to maintain in the fleet.
With automatic scaling, this value is determined based on the scaling policies currently in force. Without automatic scaling, this value is set manually. This metric is not available when viewing data for fleet metric groups.
IdleInstances(props?)
metricpublic metricIdleInstances(props?: MetricOptions): Metric
Parameters
- props
Metric
Options
Returns
Active instances that are currently hosting zero (0) game sessions.
This metric measures capacity that is available but unused. This metric can be used with automatic scaling.
InstanceInterruptions(props?)
metricpublic metricInstanceInterruptions(props?: MetricOptions): Metric
Parameters
- props
Metric
Options
Returns
Number of spot instances that have been interrupted.
MaxInstances(props?)
metricpublic metricMaxInstances(props?: MetricOptions): Metric
Parameters
- props
Metric
Options
Returns
Maximum number of instances that are allowed for the fleet.
A fleet's instance maximum determines the capacity ceiling during manual or automatic scaling up. This metric is not available when viewing data for fleet metric groups.
MinInstances(props?)
metricpublic metricMinInstances(props?: MetricOptions): Metric
Parameters
- props
Metric
Options
Returns
Minimum number of instances allowed for the fleet.
A fleet's instance minimum determines the capacity floor during manual or automatic scaling down. This metric is not available when viewing data for fleet metric groups.
PercentIdleInstances(props?)
metricpublic metricPercentIdleInstances(props?: MetricOptions): Metric
Parameters
- props
Metric
Options
Returns
Percentage of all active instances that are idle (calculated as IdleInstances / ActiveInstances).
This metric can be used for automatic scaling.