Data Center
Provides a Cassandra dataCenter resource supports replica set dataCenters only. The Cassandra provides stable, reliable, and automatic scalable database services. It offers a full range of database solutions, such as disaster recovery, backup, recovery, monitoring, and alarms. You can see detail product introduction here.
NOTE: Available in 1.88.0+. NOTE: Create a cassandra dataCenter need a clusterId,so need create a cassandra cluster first. NOTE: The following regions support create Vpc network Cassandra cluster. The official website mark more regions. Or you can call DescribeRegions. NOTE: Create Cassandra dataCenter or change dataCenter type and storage would cost 30 minutes. Please make full preparation.
Example Usage
Create a cassandra dataCenter
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.alicloud.cassandra.Cluster;
import com.pulumi.alicloud.cassandra.ClusterArgs;
import com.pulumi.alicloud.cassandra.DataCenter;
import com.pulumi.alicloud.cassandra.DataCenterArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
var defaultCluster = new Cluster("defaultCluster", ClusterArgs.builder()
.clusterName("cassandra-cluster-name-tf")
.dataCenterName("dc-1")
.autoRenew("false")
.instanceType("cassandra.c.large")
.majorVersion("3.11")
.nodeCount("2")
.payType("PayAsYouGo")
.vswitchId("vsw-xxxx1")
.diskSize("160")
.diskType("cloud_ssd")
.maintainStartTime("18:00Z")
.maintainEndTime("20:00Z")
.ipWhite("127.0.0.1")
.build());
var defaultDataCenter = new DataCenter("defaultDataCenter", DataCenterArgs.builder()
.clusterId(defaultCluster.id())
.dataCenterName("dc-2")
.autoRenew("false")
.instanceType("cassandra.c.large")
.nodeCount("2")
.payType("PayAsYouGo")
.vswitchId("vsw-xxxx2")
.diskSize("160")
.diskType("cloud_ssd")
.build());
}
}
Import
If you need full function, please import Cassandra cluster first. Cassandra dataCenter can be imported using the dcId:clusterId, e.g.
$ pulumi import alicloud:cassandra/dataCenter:DataCenter dc_2 cn-shenxxxx-x:cds-wz933ryoaurxxxxx
Properties
Instance specification. See Instance specifications. Or you can call describeInstanceType api.