InstanceType
- class aws_cdk.aws_ec2.InstanceType(instance_type_identifier)
Bases:
object
Instance type for EC2 instances.
This class takes a literal string, good if you already know the identifier of the type you want.
- ExampleMetadata:
infused
Example:
# vpc: ec2.Vpc cluster = docdb.DatabaseCluster(self, "Database", master_user=docdb.Login( username="myuser" ), instance_type=ec2.InstanceType.of(ec2.InstanceClass.MEMORY5, ec2.InstanceSize.LARGE), vpc_subnets=ec2.SubnetSelection( subnet_type=ec2.SubnetType.PUBLIC ), vpc=vpc, ca_certificate=docdb.CaCertificate.RDS_CA_RSA4096_G1 )
- Parameters:
instance_type_identifier (
str
) –
Methods
- is_burstable()
Return whether this instance type is a burstable instance type.
- Return type:
bool
- same_instance_class_as(other)
- Parameters:
other (
InstanceType
) –- Return type:
bool
- to_string()
Return the instance type as a dotted string.
- Return type:
str
Attributes
- architecture
The instance’s CPU architecture.
Static Methods
- classmethod of(instance_class, instance_size)
Instance type for EC2 instances.
This class takes a combination of a class and size.
Be aware that not all combinations of class and size are available, and not all classes are available in all regions.
- Parameters:
instance_class (
InstanceClass
) –instance_size (
InstanceSize
) –
- Return type: