volcengine.kafka.Instance
Explore with Pulumi AI
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as volcengine from "@pulumi/volcengine";
import * as volcengine from "@volcengine/pulumi";
const fooZones = volcengine.ecs.Zones({});
const fooVpc = new volcengine.vpc.Vpc("fooVpc", {
    vpcName: "acc-test-vpc",
    cidrBlock: "172.16.0.0/16",
});
const fooSubnet = new volcengine.vpc.Subnet("fooSubnet", {
    subnetName: "acc-test-subnet",
    cidrBlock: "172.16.0.0/24",
    zoneId: fooZones.then(fooZones => fooZones.zones?.[0]?.id),
    vpcId: fooVpc.id,
});
const fooInstance = new volcengine.kafka.Instance("fooInstance", {
    instanceName: "acc-test-kafka",
    instanceDescription: "tf-test",
    version: "2.2.2",
    computeSpec: "kafka.20xrate.hw",
    subnetId: fooSubnet.id,
    userName: "tf-user",
    userPassword: "tf-pass!@q1",
    chargeType: "PostPaid",
    storageSpace: 300,
    partitionNumber: 350,
    projectName: "default",
    tags: [{
        key: "k1",
        value: "v1",
    }],
    parameters: [
        {
            parameterName: "MessageMaxByte",
            parameterValue: "12",
        },
        {
            parameterName: "LogRetentionHours",
            parameterValue: "70",
        },
        {
            parameterName: "MessageTimestampType",
            parameterValue: "CreateTime",
        },
        {
            parameterName: "OffsetRetentionMinutes",
            parameterValue: "10080",
        },
        {
            parameterName: "AutoDeleteGroup",
            parameterValue: "false",
        },
    ],
});
import pulumi
import pulumi_volcengine as volcengine
foo_zones = volcengine.ecs.zones()
foo_vpc = volcengine.vpc.Vpc("fooVpc",
    vpc_name="acc-test-vpc",
    cidr_block="172.16.0.0/16")
foo_subnet = volcengine.vpc.Subnet("fooSubnet",
    subnet_name="acc-test-subnet",
    cidr_block="172.16.0.0/24",
    zone_id=foo_zones.zones[0].id,
    vpc_id=foo_vpc.id)
foo_instance = volcengine.kafka.Instance("fooInstance",
    instance_name="acc-test-kafka",
    instance_description="tf-test",
    version="2.2.2",
    compute_spec="kafka.20xrate.hw",
    subnet_id=foo_subnet.id,
    user_name="tf-user",
    user_password="tf-pass!@q1",
    charge_type="PostPaid",
    storage_space=300,
    partition_number=350,
    project_name="default",
    tags=[volcengine.kafka.InstanceTagArgs(
        key="k1",
        value="v1",
    )],
    parameters=[
        volcengine.kafka.InstanceParameterArgs(
            parameter_name="MessageMaxByte",
            parameter_value="12",
        ),
        volcengine.kafka.InstanceParameterArgs(
            parameter_name="LogRetentionHours",
            parameter_value="70",
        ),
        volcengine.kafka.InstanceParameterArgs(
            parameter_name="MessageTimestampType",
            parameter_value="CreateTime",
        ),
        volcengine.kafka.InstanceParameterArgs(
            parameter_name="OffsetRetentionMinutes",
            parameter_value="10080",
        ),
        volcengine.kafka.InstanceParameterArgs(
            parameter_name="AutoDeleteGroup",
            parameter_value="false",
        ),
    ])
package main
import (
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
	"github.com/volcengine/pulumi-volcengine/sdk/go/volcengine/ecs"
	"github.com/volcengine/pulumi-volcengine/sdk/go/volcengine/kafka"
	"github.com/volcengine/pulumi-volcengine/sdk/go/volcengine/vpc"
)
func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		fooZones, err := ecs.Zones(ctx, nil, nil)
		if err != nil {
			return err
		}
		fooVpc, err := vpc.NewVpc(ctx, "fooVpc", &vpc.VpcArgs{
			VpcName:   pulumi.String("acc-test-vpc"),
			CidrBlock: pulumi.String("172.16.0.0/16"),
		})
		if err != nil {
			return err
		}
		fooSubnet, err := vpc.NewSubnet(ctx, "fooSubnet", &vpc.SubnetArgs{
			SubnetName: pulumi.String("acc-test-subnet"),
			CidrBlock:  pulumi.String("172.16.0.0/24"),
			ZoneId:     pulumi.String(fooZones.Zones[0].Id),
			VpcId:      fooVpc.ID(),
		})
		if err != nil {
			return err
		}
		_, err = kafka.NewInstance(ctx, "fooInstance", &kafka.InstanceArgs{
			InstanceName:        pulumi.String("acc-test-kafka"),
			InstanceDescription: pulumi.String("tf-test"),
			Version:             pulumi.String("2.2.2"),
			ComputeSpec:         pulumi.String("kafka.20xrate.hw"),
			SubnetId:            fooSubnet.ID(),
			UserName:            pulumi.String("tf-user"),
			UserPassword:        pulumi.String("tf-pass!@q1"),
			ChargeType:          pulumi.String("PostPaid"),
			StorageSpace:        pulumi.Int(300),
			PartitionNumber:     pulumi.Int(350),
			ProjectName:         pulumi.String("default"),
			Tags: kafka.InstanceTagArray{
				&kafka.InstanceTagArgs{
					Key:   pulumi.String("k1"),
					Value: pulumi.String("v1"),
				},
			},
			Parameters: kafka.InstanceParameterArray{
				&kafka.InstanceParameterArgs{
					ParameterName:  pulumi.String("MessageMaxByte"),
					ParameterValue: pulumi.String("12"),
				},
				&kafka.InstanceParameterArgs{
					ParameterName:  pulumi.String("LogRetentionHours"),
					ParameterValue: pulumi.String("70"),
				},
				&kafka.InstanceParameterArgs{
					ParameterName:  pulumi.String("MessageTimestampType"),
					ParameterValue: pulumi.String("CreateTime"),
				},
				&kafka.InstanceParameterArgs{
					ParameterName:  pulumi.String("OffsetRetentionMinutes"),
					ParameterValue: pulumi.String("10080"),
				},
				&kafka.InstanceParameterArgs{
					ParameterName:  pulumi.String("AutoDeleteGroup"),
					ParameterValue: pulumi.String("false"),
				},
			},
		})
		if err != nil {
			return err
		}
		return nil
	})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Volcengine = Pulumi.Volcengine;
return await Deployment.RunAsync(() => 
{
    var fooZones = Volcengine.Ecs.Zones.Invoke();
    var fooVpc = new Volcengine.Vpc.Vpc("fooVpc", new()
    {
        VpcName = "acc-test-vpc",
        CidrBlock = "172.16.0.0/16",
    });
    var fooSubnet = new Volcengine.Vpc.Subnet("fooSubnet", new()
    {
        SubnetName = "acc-test-subnet",
        CidrBlock = "172.16.0.0/24",
        ZoneId = fooZones.Apply(zonesResult => zonesResult.Zones[0]?.Id),
        VpcId = fooVpc.Id,
    });
    var fooInstance = new Volcengine.Kafka.Instance("fooInstance", new()
    {
        InstanceName = "acc-test-kafka",
        InstanceDescription = "tf-test",
        Version = "2.2.2",
        ComputeSpec = "kafka.20xrate.hw",
        SubnetId = fooSubnet.Id,
        UserName = "tf-user",
        UserPassword = "tf-pass!@q1",
        ChargeType = "PostPaid",
        StorageSpace = 300,
        PartitionNumber = 350,
        ProjectName = "default",
        Tags = new[]
        {
            new Volcengine.Kafka.Inputs.InstanceTagArgs
            {
                Key = "k1",
                Value = "v1",
            },
        },
        Parameters = new[]
        {
            new Volcengine.Kafka.Inputs.InstanceParameterArgs
            {
                ParameterName = "MessageMaxByte",
                ParameterValue = "12",
            },
            new Volcengine.Kafka.Inputs.InstanceParameterArgs
            {
                ParameterName = "LogRetentionHours",
                ParameterValue = "70",
            },
            new Volcengine.Kafka.Inputs.InstanceParameterArgs
            {
                ParameterName = "MessageTimestampType",
                ParameterValue = "CreateTime",
            },
            new Volcengine.Kafka.Inputs.InstanceParameterArgs
            {
                ParameterName = "OffsetRetentionMinutes",
                ParameterValue = "10080",
            },
            new Volcengine.Kafka.Inputs.InstanceParameterArgs
            {
                ParameterName = "AutoDeleteGroup",
                ParameterValue = "false",
            },
        },
    });
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.volcengine.ecs.EcsFunctions;
import com.pulumi.volcengine.ecs.inputs.ZonesArgs;
import com.pulumi.volcengine.vpc.Vpc;
import com.pulumi.volcengine.vpc.VpcArgs;
import com.pulumi.volcengine.vpc.Subnet;
import com.pulumi.volcengine.vpc.SubnetArgs;
import com.pulumi.volcengine.kafka.Instance;
import com.pulumi.volcengine.kafka.InstanceArgs;
import com.pulumi.volcengine.kafka.inputs.InstanceTagArgs;
import com.pulumi.volcengine.kafka.inputs.InstanceParameterArgs;
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) {
        final var fooZones = EcsFunctions.Zones();
        var fooVpc = new Vpc("fooVpc", VpcArgs.builder()        
            .vpcName("acc-test-vpc")
            .cidrBlock("172.16.0.0/16")
            .build());
        var fooSubnet = new Subnet("fooSubnet", SubnetArgs.builder()        
            .subnetName("acc-test-subnet")
            .cidrBlock("172.16.0.0/24")
            .zoneId(fooZones.applyValue(zonesResult -> zonesResult.zones()[0].id()))
            .vpcId(fooVpc.id())
            .build());
        var fooInstance = new Instance("fooInstance", InstanceArgs.builder()        
            .instanceName("acc-test-kafka")
            .instanceDescription("tf-test")
            .version("2.2.2")
            .computeSpec("kafka.20xrate.hw")
            .subnetId(fooSubnet.id())
            .userName("tf-user")
            .userPassword("tf-pass!@q1")
            .chargeType("PostPaid")
            .storageSpace(300)
            .partitionNumber(350)
            .projectName("default")
            .tags(InstanceTagArgs.builder()
                .key("k1")
                .value("v1")
                .build())
            .parameters(            
                InstanceParameterArgs.builder()
                    .parameterName("MessageMaxByte")
                    .parameterValue("12")
                    .build(),
                InstanceParameterArgs.builder()
                    .parameterName("LogRetentionHours")
                    .parameterValue("70")
                    .build(),
                InstanceParameterArgs.builder()
                    .parameterName("MessageTimestampType")
                    .parameterValue("CreateTime")
                    .build(),
                InstanceParameterArgs.builder()
                    .parameterName("OffsetRetentionMinutes")
                    .parameterValue("10080")
                    .build(),
                InstanceParameterArgs.builder()
                    .parameterName("AutoDeleteGroup")
                    .parameterValue("false")
                    .build())
            .build());
    }
}
resources:
  fooVpc:
    type: volcengine:vpc:Vpc
    properties:
      vpcName: acc-test-vpc
      cidrBlock: 172.16.0.0/16
  fooSubnet:
    type: volcengine:vpc:Subnet
    properties:
      subnetName: acc-test-subnet
      cidrBlock: 172.16.0.0/24
      zoneId: ${fooZones.zones[0].id}
      vpcId: ${fooVpc.id}
  fooInstance:
    type: volcengine:kafka:Instance
    properties:
      instanceName: acc-test-kafka
      instanceDescription: tf-test
      version: 2.2.2
      computeSpec: kafka.20xrate.hw
      subnetId: ${fooSubnet.id}
      userName: tf-user
      userPassword: tf-pass!@q1
      chargeType: PostPaid
      storageSpace: 300
      partitionNumber: 350
      projectName: default
      tags:
        - key: k1
          value: v1
      parameters:
        - parameterName: MessageMaxByte
          parameterValue: '12'
        - parameterName: LogRetentionHours
          parameterValue: '70'
        - parameterName: MessageTimestampType
          parameterValue: CreateTime
        - parameterName: OffsetRetentionMinutes
          parameterValue: '10080'
        - parameterName: AutoDeleteGroup
          parameterValue: 'false'
variables:
  fooZones:
    fn::invoke:
      Function: volcengine:ecs:Zones
      Arguments: {}
Create Instance Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new Instance(name: string, args: InstanceArgs, opts?: CustomResourceOptions);@overload
def Instance(resource_name: str,
             args: InstanceArgs,
             opts: Optional[ResourceOptions] = None)
@overload
def Instance(resource_name: str,
             opts: Optional[ResourceOptions] = None,
             subnet_id: Optional[str] = None,
             charge_type: Optional[str] = None,
             compute_spec: Optional[str] = None,
             version: Optional[str] = None,
             user_password: Optional[str] = None,
             user_name: Optional[str] = None,
             period: Optional[int] = None,
             partition_number: Optional[int] = None,
             auto_renew: Optional[bool] = None,
             project_name: Optional[str] = None,
             rebalance_time: Optional[str] = None,
             storage_space: Optional[int] = None,
             storage_type: Optional[str] = None,
             parameters: Optional[Sequence[InstanceParameterArgs]] = None,
             tags: Optional[Sequence[InstanceTagArgs]] = None,
             need_rebalance: Optional[bool] = None,
             instance_name: Optional[str] = None,
             instance_description: Optional[str] = None)func NewInstance(ctx *Context, name string, args InstanceArgs, opts ...ResourceOption) (*Instance, error)public Instance(string name, InstanceArgs args, CustomResourceOptions? opts = null)
public Instance(String name, InstanceArgs args)
public Instance(String name, InstanceArgs args, CustomResourceOptions options)
type: volcengine:kafka:Instance
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
Parameters
- name string
- The unique name of the resource.
- args InstanceArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resource.
- args InstanceArgs
- The arguments to resource properties.
- opts ResourceOptions
- Bag of options to control resource's behavior.
- ctx Context
- Context object for the current deployment.
- name string
- The unique name of the resource.
- args InstanceArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args InstanceArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args InstanceArgs
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
Constructor example
The following reference example uses placeholder values for all input properties.
var exampleinstanceResourceResourceFromKafkainstance = new Volcengine.Kafka.Instance("exampleinstanceResourceResourceFromKafkainstance", new()
{
    SubnetId = "string",
    ChargeType = "string",
    ComputeSpec = "string",
    Version = "string",
    UserPassword = "string",
    UserName = "string",
    Period = 0,
    PartitionNumber = 0,
    AutoRenew = false,
    ProjectName = "string",
    RebalanceTime = "string",
    StorageSpace = 0,
    StorageType = "string",
    Parameters = new[]
    {
        new Volcengine.Kafka.Inputs.InstanceParameterArgs
        {
            ParameterName = "string",
            ParameterValue = "string",
        },
    },
    Tags = new[]
    {
        new Volcengine.Kafka.Inputs.InstanceTagArgs
        {
            Key = "string",
            Value = "string",
        },
    },
    NeedRebalance = false,
    InstanceName = "string",
    InstanceDescription = "string",
});
example, err := kafka.NewInstance(ctx, "exampleinstanceResourceResourceFromKafkainstance", &kafka.InstanceArgs{
	SubnetId:        pulumi.String("string"),
	ChargeType:      pulumi.String("string"),
	ComputeSpec:     pulumi.String("string"),
	Version:         pulumi.String("string"),
	UserPassword:    pulumi.String("string"),
	UserName:        pulumi.String("string"),
	Period:          pulumi.Int(0),
	PartitionNumber: pulumi.Int(0),
	AutoRenew:       pulumi.Bool(false),
	ProjectName:     pulumi.String("string"),
	RebalanceTime:   pulumi.String("string"),
	StorageSpace:    pulumi.Int(0),
	StorageType:     pulumi.String("string"),
	Parameters: kafka.InstanceParameterArray{
		&kafka.InstanceParameterArgs{
			ParameterName:  pulumi.String("string"),
			ParameterValue: pulumi.String("string"),
		},
	},
	Tags: kafka.InstanceTagArray{
		&kafka.InstanceTagArgs{
			Key:   pulumi.String("string"),
			Value: pulumi.String("string"),
		},
	},
	NeedRebalance:       pulumi.Bool(false),
	InstanceName:        pulumi.String("string"),
	InstanceDescription: pulumi.String("string"),
})
var exampleinstanceResourceResourceFromKafkainstance = new Instance("exampleinstanceResourceResourceFromKafkainstance", InstanceArgs.builder()
    .subnetId("string")
    .chargeType("string")
    .computeSpec("string")
    .version("string")
    .userPassword("string")
    .userName("string")
    .period(0)
    .partitionNumber(0)
    .autoRenew(false)
    .projectName("string")
    .rebalanceTime("string")
    .storageSpace(0)
    .storageType("string")
    .parameters(InstanceParameterArgs.builder()
        .parameterName("string")
        .parameterValue("string")
        .build())
    .tags(InstanceTagArgs.builder()
        .key("string")
        .value("string")
        .build())
    .needRebalance(false)
    .instanceName("string")
    .instanceDescription("string")
    .build());
exampleinstance_resource_resource_from_kafkainstance = volcengine.kafka.Instance("exampleinstanceResourceResourceFromKafkainstance",
    subnet_id="string",
    charge_type="string",
    compute_spec="string",
    version="string",
    user_password="string",
    user_name="string",
    period=0,
    partition_number=0,
    auto_renew=False,
    project_name="string",
    rebalance_time="string",
    storage_space=0,
    storage_type="string",
    parameters=[{
        "parameter_name": "string",
        "parameter_value": "string",
    }],
    tags=[{
        "key": "string",
        "value": "string",
    }],
    need_rebalance=False,
    instance_name="string",
    instance_description="string")
const exampleinstanceResourceResourceFromKafkainstance = new volcengine.kafka.Instance("exampleinstanceResourceResourceFromKafkainstance", {
    subnetId: "string",
    chargeType: "string",
    computeSpec: "string",
    version: "string",
    userPassword: "string",
    userName: "string",
    period: 0,
    partitionNumber: 0,
    autoRenew: false,
    projectName: "string",
    rebalanceTime: "string",
    storageSpace: 0,
    storageType: "string",
    parameters: [{
        parameterName: "string",
        parameterValue: "string",
    }],
    tags: [{
        key: "string",
        value: "string",
    }],
    needRebalance: false,
    instanceName: "string",
    instanceDescription: "string",
});
type: volcengine:kafka:Instance
properties:
    autoRenew: false
    chargeType: string
    computeSpec: string
    instanceDescription: string
    instanceName: string
    needRebalance: false
    parameters:
        - parameterName: string
          parameterValue: string
    partitionNumber: 0
    period: 0
    projectName: string
    rebalanceTime: string
    storageSpace: 0
    storageType: string
    subnetId: string
    tags:
        - key: string
          value: string
    userName: string
    userPassword: string
    version: string
Instance Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.
Inputs
In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.
The Instance resource accepts the following input properties:
- ChargeType string
- The charge type of instance, the value can be PrePaidorPostPaid.
- ComputeSpec string
- The compute spec of instance.
- SubnetId string
- The subnet id of instance.
- UserName string
- The user name of instance. When importing resources, this attribute will not be imported. If this attribute is set, please use lifecycle and ignore_changes ignore changes in fields.
- UserPassword string
- The user password of instance. When importing resources, this attribute will not be imported. If this attribute is set, please use lifecycle and ignore_changes ignore changes in fields.
- Version string
- The version of instance, the value can be 2.2.2or2.8.2.
- AutoRenew bool
- The auto renew flag of instance. Only effective when instance_charge_type is PrePaid. Default is false.
- InstanceDescription string
- The description of instance.
- InstanceName string
- The name of instance.
- NeedRebalance bool
- Whether enable rebalance. Only effected in modify when compute_spec field is changed.
- Parameters
List<InstanceParameter> 
- Parameter of the instance.
- PartitionNumber int
- The partition number of instance.
- Period int
- The period of instance. Only effective when instance_charge_type is PrePaid. Unit is Month.
- ProjectName string
- The project name of instance.
- RebalanceTime string
- The rebalance time.
- StorageSpace int
- The storage space of instance.
- StorageType string
- The storage type of instance. The value can be ESSD_FlexPL or ESSD_PL0.
- 
List<InstanceTag> 
- The tags of instance.
- ChargeType string
- The charge type of instance, the value can be PrePaidorPostPaid.
- ComputeSpec string
- The compute spec of instance.
- SubnetId string
- The subnet id of instance.
- UserName string
- The user name of instance. When importing resources, this attribute will not be imported. If this attribute is set, please use lifecycle and ignore_changes ignore changes in fields.
- UserPassword string
- The user password of instance. When importing resources, this attribute will not be imported. If this attribute is set, please use lifecycle and ignore_changes ignore changes in fields.
- Version string
- The version of instance, the value can be 2.2.2or2.8.2.
- AutoRenew bool
- The auto renew flag of instance. Only effective when instance_charge_type is PrePaid. Default is false.
- InstanceDescription string
- The description of instance.
- InstanceName string
- The name of instance.
- NeedRebalance bool
- Whether enable rebalance. Only effected in modify when compute_spec field is changed.
- Parameters
[]InstanceParameter Args 
- Parameter of the instance.
- PartitionNumber int
- The partition number of instance.
- Period int
- The period of instance. Only effective when instance_charge_type is PrePaid. Unit is Month.
- ProjectName string
- The project name of instance.
- RebalanceTime string
- The rebalance time.
- StorageSpace int
- The storage space of instance.
- StorageType string
- The storage type of instance. The value can be ESSD_FlexPL or ESSD_PL0.
- 
[]InstanceTag Args 
- The tags of instance.
- chargeType String
- The charge type of instance, the value can be PrePaidorPostPaid.
- computeSpec String
- The compute spec of instance.
- subnetId String
- The subnet id of instance.
- userName String
- The user name of instance. When importing resources, this attribute will not be imported. If this attribute is set, please use lifecycle and ignore_changes ignore changes in fields.
- userPassword String
- The user password of instance. When importing resources, this attribute will not be imported. If this attribute is set, please use lifecycle and ignore_changes ignore changes in fields.
- version String
- The version of instance, the value can be 2.2.2or2.8.2.
- autoRenew Boolean
- The auto renew flag of instance. Only effective when instance_charge_type is PrePaid. Default is false.
- instanceDescription String
- The description of instance.
- instanceName String
- The name of instance.
- needRebalance Boolean
- Whether enable rebalance. Only effected in modify when compute_spec field is changed.
- parameters
List<InstanceParameter> 
- Parameter of the instance.
- partitionNumber Integer
- The partition number of instance.
- period Integer
- The period of instance. Only effective when instance_charge_type is PrePaid. Unit is Month.
- projectName String
- The project name of instance.
- rebalanceTime String
- The rebalance time.
- storageSpace Integer
- The storage space of instance.
- storageType String
- The storage type of instance. The value can be ESSD_FlexPL or ESSD_PL0.
- 
List<InstanceTag> 
- The tags of instance.
- chargeType string
- The charge type of instance, the value can be PrePaidorPostPaid.
- computeSpec string
- The compute spec of instance.
- subnetId string
- The subnet id of instance.
- userName string
- The user name of instance. When importing resources, this attribute will not be imported. If this attribute is set, please use lifecycle and ignore_changes ignore changes in fields.
- userPassword string
- The user password of instance. When importing resources, this attribute will not be imported. If this attribute is set, please use lifecycle and ignore_changes ignore changes in fields.
- version string
- The version of instance, the value can be 2.2.2or2.8.2.
- autoRenew boolean
- The auto renew flag of instance. Only effective when instance_charge_type is PrePaid. Default is false.
- instanceDescription string
- The description of instance.
- instanceName string
- The name of instance.
- needRebalance boolean
- Whether enable rebalance. Only effected in modify when compute_spec field is changed.
- parameters
InstanceParameter[] 
- Parameter of the instance.
- partitionNumber number
- The partition number of instance.
- period number
- The period of instance. Only effective when instance_charge_type is PrePaid. Unit is Month.
- projectName string
- The project name of instance.
- rebalanceTime string
- The rebalance time.
- storageSpace number
- The storage space of instance.
- storageType string
- The storage type of instance. The value can be ESSD_FlexPL or ESSD_PL0.
- 
InstanceTag[] 
- The tags of instance.
- charge_type str
- The charge type of instance, the value can be PrePaidorPostPaid.
- compute_spec str
- The compute spec of instance.
- subnet_id str
- The subnet id of instance.
- user_name str
- The user name of instance. When importing resources, this attribute will not be imported. If this attribute is set, please use lifecycle and ignore_changes ignore changes in fields.
- user_password str
- The user password of instance. When importing resources, this attribute will not be imported. If this attribute is set, please use lifecycle and ignore_changes ignore changes in fields.
- version str
- The version of instance, the value can be 2.2.2or2.8.2.
- auto_renew bool
- The auto renew flag of instance. Only effective when instance_charge_type is PrePaid. Default is false.
- instance_description str
- The description of instance.
- instance_name str
- The name of instance.
- need_rebalance bool
- Whether enable rebalance. Only effected in modify when compute_spec field is changed.
- parameters
Sequence[InstanceParameter Args] 
- Parameter of the instance.
- partition_number int
- The partition number of instance.
- period int
- The period of instance. Only effective when instance_charge_type is PrePaid. Unit is Month.
- project_name str
- The project name of instance.
- rebalance_time str
- The rebalance time.
- storage_space int
- The storage space of instance.
- storage_type str
- The storage type of instance. The value can be ESSD_FlexPL or ESSD_PL0.
- 
Sequence[InstanceTag Args] 
- The tags of instance.
- chargeType String
- The charge type of instance, the value can be PrePaidorPostPaid.
- computeSpec String
- The compute spec of instance.
- subnetId String
- The subnet id of instance.
- userName String
- The user name of instance. When importing resources, this attribute will not be imported. If this attribute is set, please use lifecycle and ignore_changes ignore changes in fields.
- userPassword String
- The user password of instance. When importing resources, this attribute will not be imported. If this attribute is set, please use lifecycle and ignore_changes ignore changes in fields.
- version String
- The version of instance, the value can be 2.2.2or2.8.2.
- autoRenew Boolean
- The auto renew flag of instance. Only effective when instance_charge_type is PrePaid. Default is false.
- instanceDescription String
- The description of instance.
- instanceName String
- The name of instance.
- needRebalance Boolean
- Whether enable rebalance. Only effected in modify when compute_spec field is changed.
- parameters List<Property Map>
- Parameter of the instance.
- partitionNumber Number
- The partition number of instance.
- period Number
- The period of instance. Only effective when instance_charge_type is PrePaid. Unit is Month.
- projectName String
- The project name of instance.
- rebalanceTime String
- The rebalance time.
- storageSpace Number
- The storage space of instance.
- storageType String
- The storage type of instance. The value can be ESSD_FlexPL or ESSD_PL0.
- List<Property Map>
- The tags of instance.
Outputs
All input properties are implicitly available as output properties. Additionally, the Instance resource produces the following output properties:
- Id string
- The provider-assigned unique ID for this managed resource.
- Id string
- The provider-assigned unique ID for this managed resource.
- id String
- The provider-assigned unique ID for this managed resource.
- id string
- The provider-assigned unique ID for this managed resource.
- id str
- The provider-assigned unique ID for this managed resource.
- id String
- The provider-assigned unique ID for this managed resource.
Look up Existing Instance Resource
Get an existing Instance resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.
public static get(name: string, id: Input<ID>, state?: InstanceState, opts?: CustomResourceOptions): Instance@staticmethod
def get(resource_name: str,
        id: str,
        opts: Optional[ResourceOptions] = None,
        auto_renew: Optional[bool] = None,
        charge_type: Optional[str] = None,
        compute_spec: Optional[str] = None,
        instance_description: Optional[str] = None,
        instance_name: Optional[str] = None,
        need_rebalance: Optional[bool] = None,
        parameters: Optional[Sequence[InstanceParameterArgs]] = None,
        partition_number: Optional[int] = None,
        period: Optional[int] = None,
        project_name: Optional[str] = None,
        rebalance_time: Optional[str] = None,
        storage_space: Optional[int] = None,
        storage_type: Optional[str] = None,
        subnet_id: Optional[str] = None,
        tags: Optional[Sequence[InstanceTagArgs]] = None,
        user_name: Optional[str] = None,
        user_password: Optional[str] = None,
        version: Optional[str] = None) -> Instancefunc GetInstance(ctx *Context, name string, id IDInput, state *InstanceState, opts ...ResourceOption) (*Instance, error)public static Instance Get(string name, Input<string> id, InstanceState? state, CustomResourceOptions? opts = null)public static Instance get(String name, Output<String> id, InstanceState state, CustomResourceOptions options)resources:  _:    type: volcengine:kafka:Instance    get:      id: ${id}- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- resource_name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- AutoRenew bool
- The auto renew flag of instance. Only effective when instance_charge_type is PrePaid. Default is false.
- ChargeType string
- The charge type of instance, the value can be PrePaidorPostPaid.
- ComputeSpec string
- The compute spec of instance.
- InstanceDescription string
- The description of instance.
- InstanceName string
- The name of instance.
- NeedRebalance bool
- Whether enable rebalance. Only effected in modify when compute_spec field is changed.
- Parameters
List<InstanceParameter> 
- Parameter of the instance.
- PartitionNumber int
- The partition number of instance.
- Period int
- The period of instance. Only effective when instance_charge_type is PrePaid. Unit is Month.
- ProjectName string
- The project name of instance.
- RebalanceTime string
- The rebalance time.
- StorageSpace int
- The storage space of instance.
- StorageType string
- The storage type of instance. The value can be ESSD_FlexPL or ESSD_PL0.
- SubnetId string
- The subnet id of instance.
- 
List<InstanceTag> 
- The tags of instance.
- UserName string
- The user name of instance. When importing resources, this attribute will not be imported. If this attribute is set, please use lifecycle and ignore_changes ignore changes in fields.
- UserPassword string
- The user password of instance. When importing resources, this attribute will not be imported. If this attribute is set, please use lifecycle and ignore_changes ignore changes in fields.
- Version string
- The version of instance, the value can be 2.2.2or2.8.2.
- AutoRenew bool
- The auto renew flag of instance. Only effective when instance_charge_type is PrePaid. Default is false.
- ChargeType string
- The charge type of instance, the value can be PrePaidorPostPaid.
- ComputeSpec string
- The compute spec of instance.
- InstanceDescription string
- The description of instance.
- InstanceName string
- The name of instance.
- NeedRebalance bool
- Whether enable rebalance. Only effected in modify when compute_spec field is changed.
- Parameters
[]InstanceParameter Args 
- Parameter of the instance.
- PartitionNumber int
- The partition number of instance.
- Period int
- The period of instance. Only effective when instance_charge_type is PrePaid. Unit is Month.
- ProjectName string
- The project name of instance.
- RebalanceTime string
- The rebalance time.
- StorageSpace int
- The storage space of instance.
- StorageType string
- The storage type of instance. The value can be ESSD_FlexPL or ESSD_PL0.
- SubnetId string
- The subnet id of instance.
- 
[]InstanceTag Args 
- The tags of instance.
- UserName string
- The user name of instance. When importing resources, this attribute will not be imported. If this attribute is set, please use lifecycle and ignore_changes ignore changes in fields.
- UserPassword string
- The user password of instance. When importing resources, this attribute will not be imported. If this attribute is set, please use lifecycle and ignore_changes ignore changes in fields.
- Version string
- The version of instance, the value can be 2.2.2or2.8.2.
- autoRenew Boolean
- The auto renew flag of instance. Only effective when instance_charge_type is PrePaid. Default is false.
- chargeType String
- The charge type of instance, the value can be PrePaidorPostPaid.
- computeSpec String
- The compute spec of instance.
- instanceDescription String
- The description of instance.
- instanceName String
- The name of instance.
- needRebalance Boolean
- Whether enable rebalance. Only effected in modify when compute_spec field is changed.
- parameters
List<InstanceParameter> 
- Parameter of the instance.
- partitionNumber Integer
- The partition number of instance.
- period Integer
- The period of instance. Only effective when instance_charge_type is PrePaid. Unit is Month.
- projectName String
- The project name of instance.
- rebalanceTime String
- The rebalance time.
- storageSpace Integer
- The storage space of instance.
- storageType String
- The storage type of instance. The value can be ESSD_FlexPL or ESSD_PL0.
- subnetId String
- The subnet id of instance.
- 
List<InstanceTag> 
- The tags of instance.
- userName String
- The user name of instance. When importing resources, this attribute will not be imported. If this attribute is set, please use lifecycle and ignore_changes ignore changes in fields.
- userPassword String
- The user password of instance. When importing resources, this attribute will not be imported. If this attribute is set, please use lifecycle and ignore_changes ignore changes in fields.
- version String
- The version of instance, the value can be 2.2.2or2.8.2.
- autoRenew boolean
- The auto renew flag of instance. Only effective when instance_charge_type is PrePaid. Default is false.
- chargeType string
- The charge type of instance, the value can be PrePaidorPostPaid.
- computeSpec string
- The compute spec of instance.
- instanceDescription string
- The description of instance.
- instanceName string
- The name of instance.
- needRebalance boolean
- Whether enable rebalance. Only effected in modify when compute_spec field is changed.
- parameters
InstanceParameter[] 
- Parameter of the instance.
- partitionNumber number
- The partition number of instance.
- period number
- The period of instance. Only effective when instance_charge_type is PrePaid. Unit is Month.
- projectName string
- The project name of instance.
- rebalanceTime string
- The rebalance time.
- storageSpace number
- The storage space of instance.
- storageType string
- The storage type of instance. The value can be ESSD_FlexPL or ESSD_PL0.
- subnetId string
- The subnet id of instance.
- 
InstanceTag[] 
- The tags of instance.
- userName string
- The user name of instance. When importing resources, this attribute will not be imported. If this attribute is set, please use lifecycle and ignore_changes ignore changes in fields.
- userPassword string
- The user password of instance. When importing resources, this attribute will not be imported. If this attribute is set, please use lifecycle and ignore_changes ignore changes in fields.
- version string
- The version of instance, the value can be 2.2.2or2.8.2.
- auto_renew bool
- The auto renew flag of instance. Only effective when instance_charge_type is PrePaid. Default is false.
- charge_type str
- The charge type of instance, the value can be PrePaidorPostPaid.
- compute_spec str
- The compute spec of instance.
- instance_description str
- The description of instance.
- instance_name str
- The name of instance.
- need_rebalance bool
- Whether enable rebalance. Only effected in modify when compute_spec field is changed.
- parameters
Sequence[InstanceParameter Args] 
- Parameter of the instance.
- partition_number int
- The partition number of instance.
- period int
- The period of instance. Only effective when instance_charge_type is PrePaid. Unit is Month.
- project_name str
- The project name of instance.
- rebalance_time str
- The rebalance time.
- storage_space int
- The storage space of instance.
- storage_type str
- The storage type of instance. The value can be ESSD_FlexPL or ESSD_PL0.
- subnet_id str
- The subnet id of instance.
- 
Sequence[InstanceTag Args] 
- The tags of instance.
- user_name str
- The user name of instance. When importing resources, this attribute will not be imported. If this attribute is set, please use lifecycle and ignore_changes ignore changes in fields.
- user_password str
- The user password of instance. When importing resources, this attribute will not be imported. If this attribute is set, please use lifecycle and ignore_changes ignore changes in fields.
- version str
- The version of instance, the value can be 2.2.2or2.8.2.
- autoRenew Boolean
- The auto renew flag of instance. Only effective when instance_charge_type is PrePaid. Default is false.
- chargeType String
- The charge type of instance, the value can be PrePaidorPostPaid.
- computeSpec String
- The compute spec of instance.
- instanceDescription String
- The description of instance.
- instanceName String
- The name of instance.
- needRebalance Boolean
- Whether enable rebalance. Only effected in modify when compute_spec field is changed.
- parameters List<Property Map>
- Parameter of the instance.
- partitionNumber Number
- The partition number of instance.
- period Number
- The period of instance. Only effective when instance_charge_type is PrePaid. Unit is Month.
- projectName String
- The project name of instance.
- rebalanceTime String
- The rebalance time.
- storageSpace Number
- The storage space of instance.
- storageType String
- The storage type of instance. The value can be ESSD_FlexPL or ESSD_PL0.
- subnetId String
- The subnet id of instance.
- List<Property Map>
- The tags of instance.
- userName String
- The user name of instance. When importing resources, this attribute will not be imported. If this attribute is set, please use lifecycle and ignore_changes ignore changes in fields.
- userPassword String
- The user password of instance. When importing resources, this attribute will not be imported. If this attribute is set, please use lifecycle and ignore_changes ignore changes in fields.
- version String
- The version of instance, the value can be 2.2.2or2.8.2.
Supporting Types
InstanceParameter, InstanceParameterArgs    
- ParameterName string
- Parameter name.
- ParameterValue string
- Parameter value.
- ParameterName string
- Parameter name.
- ParameterValue string
- Parameter value.
- parameterName String
- Parameter name.
- parameterValue String
- Parameter value.
- parameterName string
- Parameter name.
- parameterValue string
- Parameter value.
- parameter_name str
- Parameter name.
- parameter_value str
- Parameter value.
- parameterName String
- Parameter name.
- parameterValue String
- Parameter value.
InstanceTag, InstanceTagArgs    
Import
KafkaInstance can be imported using the id, e.g.
$ pulumi import volcengine:kafka/instance:Instance default kafka-insbjwbbwb
To learn more about importing existing cloud resources, see Importing resources.
Package Details
- Repository
- volcengine volcengine/pulumi-volcengine
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the volcengineTerraform Provider.