Skip to content

Instance

This class encapsulates and extends the ROS resource type DATASOURCE::MONGODB::Instance.

Initializers

import com.aliyun.ros.cdk.mongodb.datasource.Instance;
Instance.Builder.create(Construct scope, java.lang.String id, java.lang.Boolean enableResourcePropertyConstraint)
    .instanceId(java.lang.String)
    .instanceId(IResolvable)
//  .refreshOptions(java.lang.String)
//  .refreshOptions(IResolvable)
    .build();
Name Type Description
scope com.aliyun.ros.cdk.core.Construct No description.
id java.lang.String No description.
enableResourcePropertyConstraint java.lang.Boolean No description.
instanceId java.lang.String OR com.aliyun.ros.cdk.core.IResolvable Property instanceId: The ID of the mongos.
refreshOptions java.lang.String OR com.aliyun.ros.cdk.core.IResolvable Property refreshOptions: The refresh strategy for the datasource resource when the stack is updated.

scopeRequired

  • Type: com.aliyun.ros.cdk.core.Construct

idRequired

  • Type: java.lang.String

enableResourcePropertyConstraintOptional

  • Type: java.lang.Boolean

instanceIdRequired

  • Type: java.lang.String OR com.aliyun.ros.cdk.core.IResolvable

Property instanceId: The ID of the mongos.


refreshOptionsOptional

  • Type: java.lang.String OR com.aliyun.ros.cdk.core.IResolvable

Property refreshOptions: The refresh strategy for the datasource resource when the stack is updated.

Valid values:

  • Never: Never refresh the datasource resource when the stack is updated.
  • Always: Always refresh the datasource resource when the stack is updated. Default is Never.

Methods

Name Description
toString Returns a string representation of this construct.
synthesize Allows this construct to emit artifacts into the cloud assembly during synthesis.
addCondition No description.
addCount No description.
addDependency No description.
addResourceDesc No description.
applyRemovalPolicy No description.
getAtt No description.
setMetadata No description.

toString

public java.lang.String toString()

Returns a string representation of this construct.

synthesize

public void synthesize(ISynthesisSession session)

Allows this construct to emit artifacts into the cloud assembly during synthesis.

This method is usually implemented by framework-level constructs such as Stack and Asset as they participate in synthesizing the cloud assembly.

sessionRequired

  • Type: com.aliyun.ros.cdk.core.ISynthesisSession

The synthesis session.


addCondition

public void addCondition(RosCondition condition)

conditionRequired

  • Type: com.aliyun.ros.cdk.core.RosCondition

addCount

public void addCount(java.lang.Number OR IResolvable count)

countRequired

  • Type: java.lang.Number OR com.aliyun.ros.cdk.core.IResolvable

addDependency

public void addDependency(Resource resource)

resourceRequired

  • Type: com.aliyun.ros.cdk.core.Resource

addResourceDesc

public void addResourceDesc(java.lang.String desc)

descRequired

  • Type: java.lang.String

applyRemovalPolicy

public void applyRemovalPolicy(RemovalPolicy policy)

policyRequired

  • Type: com.aliyun.ros.cdk.core.RemovalPolicy

getAtt

public IResolvable getAtt(java.lang.String name)

nameRequired

  • Type: java.lang.String

setMetadata

public void setMetadata(java.lang.String key, java.lang.Object value)

keyRequired

  • Type: java.lang.String

valueRequired

  • Type: java.lang.Object

Static Functions

Name Description
isConstruct Return whether the given object is a Construct.

isConstruct

import com.aliyun.ros.cdk.mongodb.datasource.Instance;
Instance.isConstruct(java.lang.Object x)

Return whether the given object is a Construct.

xRequired

  • Type: java.lang.Object

Properties

Name Type Description
node com.aliyun.ros.cdk.core.ConstructNode The construct tree node associated with this construct.
ref java.lang.String No description.
stack com.aliyun.ros.cdk.core.Stack The stack in which this resource is defined.
resource com.aliyun.ros.cdk.core.RosResource No description.
attrAccountDescription com.aliyun.ros.cdk.core.IResolvable Attribute AccountDescription: The description of the account.
attrAccountName com.aliyun.ros.cdk.core.IResolvable Attribute AccountName: The name of the account.
attrAutoRenew com.aliyun.ros.cdk.core.IResolvable Attribute AutoRenew: Indicates whether auto-renewal is enabled for the instance.
attrAutoRenewDuration com.aliyun.ros.cdk.core.IResolvable Attribute AutoRenewDuration: Auto Renew Duration.
attrBackupInterval com.aliyun.ros.cdk.core.IResolvable Attribute BackupInterval: The frequency at which high-frequency backup is created.
attrBackupRetentionPeriod com.aliyun.ros.cdk.core.IResolvable Attribute BackupRetentionPeriod: The retention period of the backup data.
attrCreateTime com.aliyun.ros.cdk.core.IResolvable Attribute CreateTime: The Database create time.
attrDbInstanceClass com.aliyun.ros.cdk.core.IResolvable Attribute DBInstanceClass: The instance type of the instance.
attrDbInstanceDescription com.aliyun.ros.cdk.core.IResolvable Attribute DBInstanceDescription: The name of the instance.
attrDbInstanceReleaseProtection com.aliyun.ros.cdk.core.IResolvable Attribute DBInstanceReleaseProtection: Indicates whether release protection is enabled for the instance.
attrDbInstanceStorage com.aliyun.ros.cdk.core.IResolvable Attribute DbInstanceStorage: The storage capacity of the instance.
attrDbInstanceType com.aliyun.ros.cdk.core.IResolvable Attribute DBInstanceType: The architecture of the instance.
attrEnableBackupLog com.aliyun.ros.cdk.core.IResolvable Attribute EnableBackupLog: Indicates whether the log backup feature is enabled.
attrEngine com.aliyun.ros.cdk.core.IResolvable Attribute Engine: The database engine of the instance.
attrEngineVersion com.aliyun.ros.cdk.core.IResolvable Attribute EngineVersion: The database engine version of the instance.
attrExpireTime com.aliyun.ros.cdk.core.IResolvable Attribute ExpireTime: The time when the subscription instance expires.
attrHiddenZoneId com.aliyun.ros.cdk.core.IResolvable Attribute HiddenZoneId: The zone where the hidden node resides for multi-zone deployment.
attrInstanceId com.aliyun.ros.cdk.core.IResolvable Attribute InstanceId: The ID of the mongos.
attrKindCode com.aliyun.ros.cdk.core.IResolvable Attribute KindCode: The kind code of the instance.
attrLastDowngradeTime com.aliyun.ros.cdk.core.IResolvable Attribute LastDowngradeTime: The date when the last downgrade operation was performed on the instance.
attrLockMode com.aliyun.ros.cdk.core.IResolvable Attribute LockMode: The lock status of the instance.
attrLogBackupRetentionPeriod com.aliyun.ros.cdk.core.IResolvable Attribute LogBackupRetentionPeriod: The number of days for which log backups are retained.
attrMaintainEndTime com.aliyun.ros.cdk.core.IResolvable Attribute MaintainEndTime: The end time of the maintenance window.
attrMaintainStartTime com.aliyun.ros.cdk.core.IResolvable Attribute MaintainStartTime: The start time of the maintenance window.
attrMongosList com.aliyun.ros.cdk.core.IResolvable Attribute MongosList: The information of the mongos nodes.
attrNetworkAddresses com.aliyun.ros.cdk.core.IResolvable Attribute NetworkAddresses: The endpoints of ApsaraDB for MongoDB instances.
attrNetworkType com.aliyun.ros.cdk.core.IResolvable Attribute NetworkType: The network type of the instance.
attrParameters com.aliyun.ros.cdk.core.IResolvable Attribute Parameters: The settings of the parameters that have taken effect.
attrPaymentType com.aliyun.ros.cdk.core.IResolvable Attribute PaymentType: The billing method of the Database.
attrPreferredBackupPeriod com.aliyun.ros.cdk.core.IResolvable Attribute PreferredBackupPeriod: The day of a week on which to back up data.
attrPreferredBackupTime com.aliyun.ros.cdk.core.IResolvable Attribute PreferredBackupTime: The time range during which the backup was created.
attrProtocolType com.aliyun.ros.cdk.core.IResolvable Attribute ProtocolType: The access protocol type of the instance.
attrReadonlyReplicas com.aliyun.ros.cdk.core.IResolvable Attribute ReadonlyReplicas: The number of read-only nodes in the shard node.
attrReplicaSetsConnections com.aliyun.ros.cdk.core.IResolvable Attribute ReplicaSetsConnections: ReplicaSets Connections.
attrReplicationFactor com.aliyun.ros.cdk.core.IResolvable Attribute ReplicationFactor: The number of nodes in the instance.
attrResourceGroupId com.aliyun.ros.cdk.core.IResolvable Attribute ResourceGroupId: The ID of the resource group to which the instance belongs.
attrSecondaryZoneId com.aliyun.ros.cdk.core.IResolvable Attribute SecondaryZoneId: The zone where the secondary node resides for multi-zone deployment.
attrSecurityGroupId com.aliyun.ros.cdk.core.IResolvable Attribute SecurityGroupId: The ID of the ECS security group.
attrSecurityIpList com.aliyun.ros.cdk.core.IResolvable Attribute SecurityIpList: The name of the IP whitelist.
attrSecurityIps com.aliyun.ros.cdk.core.IResolvable Attribute SecurityIps: The IP addresses in the default whitelist.
attrShardList com.aliyun.ros.cdk.core.IResolvable Attribute ShardList: The information of the shard nodes.
attrSnapshotBackupType com.aliyun.ros.cdk.core.IResolvable Attribute SnapshotBackupType: The snapshot backup type.
attrSslExpiredTime com.aliyun.ros.cdk.core.IResolvable Attribute SslExpiredTime: The time when the SSL certificate expires.
attrSslStatus com.aliyun.ros.cdk.core.IResolvable Attribute SslStatus: The status of the SSL feature.
attrStorageEngine com.aliyun.ros.cdk.core.IResolvable Attribute StorageEngine: The Storage Engine Of The Instance Type.
attrTags com.aliyun.ros.cdk.core.IResolvable Attribute Tags: The details of the instance tags.
attrTdeStatus com.aliyun.ros.cdk.core.IResolvable Attribute TdeStatus: The TDE status.
attrVpcAuthMode com.aliyun.ros.cdk.core.IResolvable Attribute VpcAuthMode: Indicates whether password-free access within the VPC is enabled.
attrVpcId com.aliyun.ros.cdk.core.IResolvable Attribute VpcId: The VPC ID of the instance.
attrVSwitchId com.aliyun.ros.cdk.core.IResolvable Attribute VSwitchId: The vSwitch ID of the instance.
attrZoneId com.aliyun.ros.cdk.core.IResolvable Attribute ZoneId: The ID of the zone in which the instance resides.

nodeRequired

public ConstructNode getNode();
  • Type: com.aliyun.ros.cdk.core.ConstructNode

The construct tree node associated with this construct.


refRequired

public java.lang.String getRef();
  • Type: java.lang.String

stackRequired

public Stack getStack();
  • Type: com.aliyun.ros.cdk.core.Stack

The stack in which this resource is defined.


resourceOptional

public RosResource getResource();
  • Type: com.aliyun.ros.cdk.core.RosResource

attrAccountDescriptionRequired

public IResolvable getAttrAccountDescription();
  • Type: com.aliyun.ros.cdk.core.IResolvable

Attribute AccountDescription: The description of the account.


attrAccountNameRequired

public IResolvable getAttrAccountName();
  • Type: com.aliyun.ros.cdk.core.IResolvable

Attribute AccountName: The name of the account.

Value: *root * .


attrAutoRenewRequired

public IResolvable getAttrAutoRenew();
  • Type: com.aliyun.ros.cdk.core.IResolvable

Attribute AutoRenew: Indicates whether auto-renewal is enabled for the instance.

Valid values: true: Auto-renewal is enabled for the instance. false: Auto-renewal is disabled for the instance.


attrAutoRenewDurationRequired

public IResolvable getAttrAutoRenewDuration();
  • Type: com.aliyun.ros.cdk.core.IResolvable

Attribute AutoRenewDuration: Auto Renew Duration.


attrBackupIntervalRequired

public IResolvable getAttrBackupInterval();
  • Type: com.aliyun.ros.cdk.core.IResolvable

Attribute BackupInterval: The frequency at which high-frequency backup is created.

Valid values: -1: High-frequency backup is disabled. 15: every 15 minutes. 30: every 30 minutes. 60: every hour. 120: every 2 hours. 180: every 3 hours. 240: every 4 hours. 360: every 6 hours. 480: every 8 hours. 720: every 12 hours.


attrBackupRetentionPeriodRequired

public IResolvable getAttrBackupRetentionPeriod();
  • Type: com.aliyun.ros.cdk.core.IResolvable

Attribute BackupRetentionPeriod: The retention period of the backup data.

Unit: day.


attrCreateTimeRequired

public IResolvable getAttrCreateTime();
  • Type: com.aliyun.ros.cdk.core.IResolvable

Attribute CreateTime: The Database create time.


attrDbInstanceClassRequired

public IResolvable getAttrDbInstanceClass();
  • Type: com.aliyun.ros.cdk.core.IResolvable

Attribute DBInstanceClass: The instance type of the instance.


attrDbInstanceDescriptionRequired

public IResolvable getAttrDbInstanceDescription();
  • Type: com.aliyun.ros.cdk.core.IResolvable

Attribute DBInstanceDescription: The name of the instance.


attrDbInstanceReleaseProtectionRequired

public IResolvable getAttrDbInstanceReleaseProtection();
  • Type: com.aliyun.ros.cdk.core.IResolvable

Attribute DBInstanceReleaseProtection: Indicates whether release protection is enabled for the instance.

Valid values: true false


attrDbInstanceStorageRequired

public IResolvable getAttrDbInstanceStorage();
  • Type: com.aliyun.ros.cdk.core.IResolvable

Attribute DbInstanceStorage: The storage capacity of the instance.


attrDbInstanceTypeRequired

public IResolvable getAttrDbInstanceType();
  • Type: com.aliyun.ros.cdk.core.IResolvable

Attribute DBInstanceType: The architecture of the instance.

Valid values: replicate: replica set instance sharding: sharded cluster instance


attrEnableBackupLogRequired

public IResolvable getAttrEnableBackupLog();
  • Type: com.aliyun.ros.cdk.core.IResolvable

Attribute EnableBackupLog: Indicates whether the log backup feature is enabled.

Valid values: 0 (default): The log backup feature is disabled. 1: The log backup feature is enabled.


attrEngineRequired

public IResolvable getAttrEngine();
  • Type: com.aliyun.ros.cdk.core.IResolvable

Attribute Engine: The database engine of the instance.

Default value: mongodb.


attrEngineVersionRequired

public IResolvable getAttrEngineVersion();
  • Type: com.aliyun.ros.cdk.core.IResolvable

Attribute EngineVersion: The database engine version of the instance.

6.0 5.0 4.4 4.2 4.0


attrExpireTimeRequired

public IResolvable getAttrExpireTime();
  • Type: com.aliyun.ros.cdk.core.IResolvable

Attribute ExpireTime: The time when the subscription instance expires.

The time follows the ISO 8601 standard in the yyyy-MM-ddTHH:mmZ format. The time is displayed in UTC.


attrHiddenZoneIdRequired

public IResolvable getAttrHiddenZoneId();
  • Type: com.aliyun.ros.cdk.core.IResolvable

Attribute HiddenZoneId: The zone where the hidden node resides for multi-zone deployment.


attrInstanceIdRequired

public IResolvable getAttrInstanceId();
  • Type: com.aliyun.ros.cdk.core.IResolvable

Attribute InstanceId: The ID of the mongos.


attrKindCodeRequired

public IResolvable getAttrKindCode();
  • Type: com.aliyun.ros.cdk.core.IResolvable

Attribute KindCode: The kind code of the instance.

Valid values: 0: physical machine 1: Elastic Compute Service (ECS) instance 2: Docker cluster 18: Kubernetes cluster


attrLastDowngradeTimeRequired

public IResolvable getAttrLastDowngradeTime();
  • Type: com.aliyun.ros.cdk.core.IResolvable

Attribute LastDowngradeTime: The date when the last downgrade operation was performed on the instance.


attrLockModeRequired

public IResolvable getAttrLockMode();
  • Type: com.aliyun.ros.cdk.core.IResolvable

Attribute LockMode: The lock status of the instance.

Valid values: Unlock: The instance is not locked. ManualLock: The instance is manually locked. LockByExpiration: The instance is automatically locked due to instance expiration. LockByRestoration: The instance is automatically locked before the instance is rolled back. LockByDiskQuota: The instance is automatically locked after the storage space is exhausted. Released: The instance is released.


attrLogBackupRetentionPeriodRequired

public IResolvable getAttrLogBackupRetentionPeriod();
  • Type: com.aliyun.ros.cdk.core.IResolvable

Attribute LogBackupRetentionPeriod: The number of days for which log backups are retained.

Valid values: 7 to 730.


attrMaintainEndTimeRequired

public IResolvable getAttrMaintainEndTime();
  • Type: com.aliyun.ros.cdk.core.IResolvable

Attribute MaintainEndTime: The end time of the maintenance window.

The time follows the ISO 8601 standard in the HH:mmZ format. The time is displayed in UTC.


attrMaintainStartTimeRequired

public IResolvable getAttrMaintainStartTime();
  • Type: com.aliyun.ros.cdk.core.IResolvable

Attribute MaintainStartTime: The start time of the maintenance window.

The time follows the ISO 8601 standard in the HH:mmZ format. The time is displayed in UTC.


attrMongosListRequired

public IResolvable getAttrMongosList();
  • Type: com.aliyun.ros.cdk.core.IResolvable

Attribute MongosList: The information of the mongos nodes.


attrNetworkAddressesRequired

public IResolvable getAttrNetworkAddresses();
  • Type: com.aliyun.ros.cdk.core.IResolvable

Attribute NetworkAddresses: The endpoints of ApsaraDB for MongoDB instances.


attrNetworkTypeRequired

public IResolvable getAttrNetworkType();
  • Type: com.aliyun.ros.cdk.core.IResolvable

Attribute NetworkType: The network type of the instance.

Valid values: Classic: classic network VPC: VPC


attrParametersRequired

public IResolvable getAttrParameters();
  • Type: com.aliyun.ros.cdk.core.IResolvable

Attribute Parameters: The settings of the parameters that have taken effect.


attrPaymentTypeRequired

public IResolvable getAttrPaymentType();
  • Type: com.aliyun.ros.cdk.core.IResolvable

Attribute PaymentType: The billing method of the Database.

Valid values: PrePaid: subscription PostPaid: pay-as-you-go.


attrPreferredBackupPeriodRequired

public IResolvable getAttrPreferredBackupPeriod();
  • Type: com.aliyun.ros.cdk.core.IResolvable

Attribute PreferredBackupPeriod: The day of a week on which to back up data.

Valid values: Monday Tuesday Wednesday Thursday Friday Saturday Sunday


attrPreferredBackupTimeRequired

public IResolvable getAttrPreferredBackupTime();
  • Type: com.aliyun.ros.cdk.core.IResolvable

Attribute PreferredBackupTime: The time range during which the backup was created.

The time follows the ISO 8601 standard in the HH:mmZ-HH:mmZ format. The time is displayed in UTC.


attrProtocolTypeRequired

public IResolvable getAttrProtocolType();
  • Type: com.aliyun.ros.cdk.core.IResolvable

Attribute ProtocolType: The access protocol type of the instance.

Valid values: mongodb dynamodb


attrReadonlyReplicasRequired

public IResolvable getAttrReadonlyReplicas();
  • Type: com.aliyun.ros.cdk.core.IResolvable

Attribute ReadonlyReplicas: The number of read-only nodes in the shard node.

Valid values: 0 to 5. The value must be an integer.


attrReplicaSetsConnectionsRequired

public IResolvable getAttrReplicaSetsConnections();
  • Type: com.aliyun.ros.cdk.core.IResolvable

Attribute ReplicaSetsConnections: ReplicaSets Connections.


attrReplicationFactorRequired

public IResolvable getAttrReplicationFactor();
  • Type: com.aliyun.ros.cdk.core.IResolvable

Attribute ReplicationFactor: The number of nodes in the instance.


attrResourceGroupIdRequired

public IResolvable getAttrResourceGroupId();
  • Type: com.aliyun.ros.cdk.core.IResolvable

Attribute ResourceGroupId: The ID of the resource group to which the instance belongs.


attrSecondaryZoneIdRequired

public IResolvable getAttrSecondaryZoneId();
  • Type: com.aliyun.ros.cdk.core.IResolvable

Attribute SecondaryZoneId: The zone where the secondary node resides for multi-zone deployment.


attrSecurityGroupIdRequired

public IResolvable getAttrSecurityGroupId();
  • Type: com.aliyun.ros.cdk.core.IResolvable

Attribute SecurityGroupId: The ID of the ECS security group.


attrSecurityIpListRequired

public IResolvable getAttrSecurityIpList();
  • Type: com.aliyun.ros.cdk.core.IResolvable

Attribute SecurityIpList: The name of the IP whitelist.


attrSecurityIpsRequired

public IResolvable getAttrSecurityIps();
  • Type: com.aliyun.ros.cdk.core.IResolvable

Attribute SecurityIps: The IP addresses in the default whitelist.


attrShardListRequired

public IResolvable getAttrShardList();
  • Type: com.aliyun.ros.cdk.core.IResolvable

Attribute ShardList: The information of the shard nodes.


attrSnapshotBackupTypeRequired

public IResolvable getAttrSnapshotBackupType();
  • Type: com.aliyun.ros.cdk.core.IResolvable

Attribute SnapshotBackupType: The snapshot backup type.

Valid values: Flash: single-digit second backup Standard (default): standard backup


attrSslExpiredTimeRequired

public IResolvable getAttrSslExpiredTime();
  • Type: com.aliyun.ros.cdk.core.IResolvable

Attribute SslExpiredTime: The time when the SSL certificate expires.

The time follows the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time is displayed in Coordinated Universal Time (UTC).


attrSslStatusRequired

public IResolvable getAttrSslStatus();
  • Type: com.aliyun.ros.cdk.core.IResolvable

Attribute SslStatus: The status of the SSL feature.

Valid values: Open: The SSL feature is enabled. Closed: The SSL feature is disabled.


attrStorageEngineRequired

public IResolvable getAttrStorageEngine();
  • Type: com.aliyun.ros.cdk.core.IResolvable

Attribute StorageEngine: The Storage Engine Of The Instance Type.


attrTagsRequired

public IResolvable getAttrTags();
  • Type: com.aliyun.ros.cdk.core.IResolvable

Attribute Tags: The details of the instance tags.


attrTdeStatusRequired

public IResolvable getAttrTdeStatus();
  • Type: com.aliyun.ros.cdk.core.IResolvable

Attribute TdeStatus: The TDE status.

Valid values: enabled disabled


attrVpcAuthModeRequired

public IResolvable getAttrVpcAuthMode();
  • Type: com.aliyun.ros.cdk.core.IResolvable

Attribute VpcAuthMode: Indicates whether password-free access within the VPC is enabled.

Valid values: Open: Password-free access within the VPC is enabled. Close: Password-free access within the VPC is disabled, and you must use a password for access. NotSupport: Password-free access within the VPC is not supported.


attrVpcIdRequired

public IResolvable getAttrVpcId();
  • Type: com.aliyun.ros.cdk.core.IResolvable

Attribute VpcId: The VPC ID of the instance.


attrVSwitchIdRequired

public IResolvable getAttrVSwitchId();
  • Type: com.aliyun.ros.cdk.core.IResolvable

Attribute VSwitchId: The vSwitch ID of the instance.


attrZoneIdRequired

public IResolvable getAttrZoneId();
  • Type: com.aliyun.ros.cdk.core.IResolvable

Attribute ZoneId: The ID of the zone in which the instance resides.