Provides a resource to manage tls shard
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as volcengine from "@volcengine/pulumi";
const foo = new volcengine.tls.Shard("foo", {
number: 2,
shardId: 1,
topicId: "176b62c7-c482-4a6e-b983-4697fda9294a",
});
import pulumi
import pulumi_volcengine as volcengine
foo = volcengine.tls.Shard("foo",
number=2,
shard_id=1,
topic_id="176b62c7-c482-4a6e-b983-4697fda9294a")
package main
import (
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
"github.com/volcengine/pulumi-volcengine/sdk/go/volcengine/tls"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := tls.NewShard(ctx, "foo", &tls.ShardArgs{
Number: pulumi.Int(2),
ShardId: pulumi.Int(1),
TopicId: pulumi.String("176b62c7-c482-4a6e-b983-4697fda9294a"),
})
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 foo = new Volcengine.Tls.Shard("foo", new()
{
Number = 2,
ShardId = 1,
TopicId = "176b62c7-c482-4a6e-b983-4697fda9294a",
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.volcengine.tls.Shard;
import com.pulumi.volcengine.tls.ShardArgs;
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 foo = new Shard("foo", ShardArgs.builder()
.number(2)
.shardId(1)
.topicId("176b62c7-c482-4a6e-b983-4697fda9294a")
.build());
}
}
resources:
foo:
type: volcengine:tls:Shard
properties:
number: 2
shardId: 1
topicId: 176b62c7-c482-4a6e-b983-4697fda9294a
Create Shard Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new Shard(name: string, args: ShardArgs, opts?: CustomResourceOptions);@overload
def Shard(resource_name: str,
args: ShardArgs,
opts: Optional[ResourceOptions] = None)
@overload
def Shard(resource_name: str,
opts: Optional[ResourceOptions] = None,
number: Optional[int] = None,
shard_id: Optional[int] = None,
topic_id: Optional[str] = None)func NewShard(ctx *Context, name string, args ShardArgs, opts ...ResourceOption) (*Shard, error)public Shard(string name, ShardArgs args, CustomResourceOptions? opts = null)type: volcengine:tls:Shard
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 ShardArgs
- 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 ShardArgs
- 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 ShardArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args ShardArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args ShardArgs
- 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 shardResource = new Volcengine.Tls.Shard("shardResource", new()
{
Number = 0,
ShardId = 0,
TopicId = "string",
});
example, err := tls.NewShard(ctx, "shardResource", &tls.ShardArgs{
Number: pulumi.Int(0),
ShardId: pulumi.Int(0),
TopicId: pulumi.String("string"),
})
var shardResource = new Shard("shardResource", ShardArgs.builder()
.number(0)
.shardId(0)
.topicId("string")
.build());
shard_resource = volcengine.tls.Shard("shardResource",
number=0,
shard_id=0,
topic_id="string")
const shardResource = new volcengine.tls.Shard("shardResource", {
number: 0,
shardId: 0,
topicId: "string",
});
type: volcengine:tls:Shard
properties:
number: 0
shardId: 0
topicId: string
Shard 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 Shard resource accepts the following input properties:
Outputs
All input properties are implicitly available as output properties. Additionally, the Shard resource produces the following output properties:
- Id string
- The provider-assigned unique ID for this managed resource.
-
List<Shard
Shard> - The collection of shards after split.
- Id string
- The provider-assigned unique ID for this managed resource.
-
[]Shard
Shard - The collection of shards after split.
- id String
- The provider-assigned unique ID for this managed resource.
-
List<Shard
Shard> - The collection of shards after split.
- id string
- The provider-assigned unique ID for this managed resource.
-
Shard
Shard[] - The collection of shards after split.
- id str
- The provider-assigned unique ID for this managed resource.
-
Sequence[Shard
Shard] - The collection of shards after split.
- id String
- The provider-assigned unique ID for this managed resource.
- List<Property Map>
- The collection of shards after split.
Look up Existing Shard Resource
Get an existing Shard 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?: ShardState, opts?: CustomResourceOptions): Shard@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
number: Optional[int] = None,
shard_id: Optional[int] = None,
shards: Optional[Sequence[ShardShardArgs]] = None,
topic_id: Optional[str] = None) -> Shardfunc GetShard(ctx *Context, name string, id IDInput, state *ShardState, opts ...ResourceOption) (*Shard, error)public static Shard Get(string name, Input<string> id, ShardState? state, CustomResourceOptions? opts = null)public static Shard get(String name, Output<String> id, ShardState state, CustomResourceOptions options)resources: _: type: volcengine:tls:Shard 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.
- Number int
- The number of splits. Must be a non-zero even number, such as 2, 4, 8, or 16.
- Shard
Id int - The ID of the shard to split.
- Shards
List<Shard
Shard> - The collection of shards after split.
- Topic
Id string - The ID of the topic.
- Number int
- The number of splits. Must be a non-zero even number, such as 2, 4, 8, or 16.
- Shard
Id int - The ID of the shard to split.
- Shards
[]Shard
Shard Args - The collection of shards after split.
- Topic
Id string - The ID of the topic.
- number Integer
- The number of splits. Must be a non-zero even number, such as 2, 4, 8, or 16.
- shard
Id Integer - The ID of the shard to split.
- shards
List<Shard
Shard> - The collection of shards after split.
- topic
Id String - The ID of the topic.
- number number
- The number of splits. Must be a non-zero even number, such as 2, 4, 8, or 16.
- shard
Id number - The ID of the shard to split.
- shards
Shard
Shard[] - The collection of shards after split.
- topic
Id string - The ID of the topic.
- number int
- The number of splits. Must be a non-zero even number, such as 2, 4, 8, or 16.
- shard_
id int - The ID of the shard to split.
- shards
Sequence[Shard
Shard Args] - The collection of shards after split.
- topic_
id str - The ID of the topic.
- number Number
- The number of splits. Must be a non-zero even number, such as 2, 4, 8, or 16.
- shard
Id Number - The ID of the shard to split.
- shards List<Property Map>
- The collection of shards after split.
- topic
Id String - The ID of the topic.
Supporting Types
ShardShard, ShardShardArgs
- Exclusive
End stringKey - The exclusive end key of the shard.
- Inclusive
Begin stringKey - The inclusive begin key of the shard.
- Modify
Time string - The modification time of the shard.
- int
- The ID of the shard to split.
- Status string
- The status of the shard.
- Stop
Write stringTime - The stop write time of the shard.
- Topic
Id string - The ID of the topic.
- Exclusive
End stringKey - The exclusive end key of the shard.
- Inclusive
Begin stringKey - The inclusive begin key of the shard.
- Modify
Time string - The modification time of the shard.
- int
- The ID of the shard to split.
- Status string
- The status of the shard.
- Stop
Write stringTime - The stop write time of the shard.
- Topic
Id string - The ID of the topic.
- exclusive
End StringKey - The exclusive end key of the shard.
- inclusive
Begin StringKey - The inclusive begin key of the shard.
- modify
Time String - The modification time of the shard.
- Integer
- The ID of the shard to split.
- status String
- The status of the shard.
- stop
Write StringTime - The stop write time of the shard.
- topic
Id String - The ID of the topic.
- exclusive
End stringKey - The exclusive end key of the shard.
- inclusive
Begin stringKey - The inclusive begin key of the shard.
- modify
Time string - The modification time of the shard.
- number
- The ID of the shard to split.
- status string
- The status of the shard.
- stop
Write stringTime - The stop write time of the shard.
- topic
Id string - The ID of the topic.
- exclusive_
end_ strkey - The exclusive end key of the shard.
- inclusive_
begin_ strkey - The inclusive begin key of the shard.
- modify_
time str - The modification time of the shard.
- int
- The ID of the shard to split.
- status str
- The status of the shard.
- stop_
write_ strtime - The stop write time of the shard.
- topic_
id str - The ID of the topic.
- exclusive
End StringKey - The exclusive end key of the shard.
- inclusive
Begin StringKey - The inclusive begin key of the shard.
- modify
Time String - The modification time of the shard.
- Number
- The ID of the shard to split.
- status String
- The status of the shard.
- stop
Write StringTime - The stop write time of the shard.
- topic
Id String - The ID of the topic.
Import
The TlsShard is not support import.
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.
