alicloud.dts.getConsumerChannels
This data source provides the Dts Consumer Channels of the current Alibaba Cloud user.
NOTE: Available in v1.146.0+.
Example Usage
Basic Usage
using System.Collections.Generic;
using Pulumi;
using AliCloud = Pulumi.AliCloud;
return await Deployment.RunAsync(() =>
{
var ids = AliCloud.Dts.GetConsumerChannels.Invoke();
return new Dictionary<string, object?>
{
["dtsConsumerChannelId1"] = ids.Apply(getConsumerChannelsResult => getConsumerChannelsResult.Channels[0]?.Id),
};
});
package main
import (
"github.com/pulumi/pulumi-alicloud/sdk/v3/go/alicloud/dts"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
ids, err := dts.GetConsumerChannels(ctx, nil, nil)
if err != nil {
return err
}
ctx.Export("dtsConsumerChannelId1", ids.Channels[0].Id)
return nil
})
}
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.alicloud.dts.DtsFunctions;
import com.pulumi.alicloud.dts.inputs.GetConsumerChannelsArgs;
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 ids = DtsFunctions.getConsumerChannels();
ctx.export("dtsConsumerChannelId1", ids.applyValue(getConsumerChannelsResult -> getConsumerChannelsResult.channels()[0].id()));
}
}
import pulumi
import pulumi_alicloud as alicloud
ids = alicloud.dts.get_consumer_channels()
pulumi.export("dtsConsumerChannelId1", ids.channels[0].id)
import * as pulumi from "@pulumi/pulumi";
import * as alicloud from "@pulumi/alicloud";
const ids = alicloud.dts.getConsumerChannels({});
export const dtsConsumerChannelId1 = ids.then(ids => ids.channels?.[0]?.id);
variables:
ids:
fn::invoke:
Function: alicloud:dts:getConsumerChannels
Arguments: {}
outputs:
dtsConsumerChannelId1: ${ids.channels[0].id}
Using getConsumerChannels
Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.
function getConsumerChannels(args: GetConsumerChannelsArgs, opts?: InvokeOptions): Promise<GetConsumerChannelsResult>
function getConsumerChannelsOutput(args: GetConsumerChannelsOutputArgs, opts?: InvokeOptions): Output<GetConsumerChannelsResult>
def get_consumer_channels(dts_instance_id: Optional[str] = None,
ids: Optional[Sequence[str]] = None,
output_file: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetConsumerChannelsResult
def get_consumer_channels_output(dts_instance_id: Optional[pulumi.Input[str]] = None,
ids: Optional[pulumi.Input[Sequence[pulumi.Input[str]]]] = None,
output_file: Optional[pulumi.Input[str]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetConsumerChannelsResult]
func GetConsumerChannels(ctx *Context, args *GetConsumerChannelsArgs, opts ...InvokeOption) (*GetConsumerChannelsResult, error)
func GetConsumerChannelsOutput(ctx *Context, args *GetConsumerChannelsOutputArgs, opts ...InvokeOption) GetConsumerChannelsResultOutput
> Note: This function is named GetConsumerChannels
in the Go SDK.
public static class GetConsumerChannels
{
public static Task<GetConsumerChannelsResult> InvokeAsync(GetConsumerChannelsArgs args, InvokeOptions? opts = null)
public static Output<GetConsumerChannelsResult> Invoke(GetConsumerChannelsInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetConsumerChannelsResult> getConsumerChannels(GetConsumerChannelsArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
fn::invoke:
function: alicloud:dts/getConsumerChannels:getConsumerChannels
arguments:
# arguments dictionary
The following arguments are supported:
- Dts
Instance stringId Subscription instance ID.
- Ids List<string>
A list of Consumer Channel IDs.
- Output
File string
- Dts
Instance stringId Subscription instance ID.
- Ids []string
A list of Consumer Channel IDs.
- Output
File string
- dts
Instance StringId Subscription instance ID.
- ids List<String>
A list of Consumer Channel IDs.
- output
File String
- dts
Instance stringId Subscription instance ID.
- ids string[]
A list of Consumer Channel IDs.
- output
File string
- dts_
instance_ strid Subscription instance ID.
- ids Sequence[str]
A list of Consumer Channel IDs.
- output_
file str
- dts
Instance StringId Subscription instance ID.
- ids List<String>
A list of Consumer Channel IDs.
- output
File String
getConsumerChannels Result
The following output properties are available:
- Channels
List<Pulumi.
Ali Cloud. Dts. Outputs. Get Consumer Channels Channel> - Dts
Instance stringId - Id string
The provider-assigned unique ID for this managed resource.
- Ids List<string>
- Output
File string
- Channels
[]Get
Consumer Channels Channel - Dts
Instance stringId - Id string
The provider-assigned unique ID for this managed resource.
- Ids []string
- Output
File string
- channels
List<Get
Consumer Channels Channel> - dts
Instance StringId - id String
The provider-assigned unique ID for this managed resource.
- ids List<String>
- output
File String
- channels
Get
Consumer Channels Channel[] - dts
Instance stringId - id string
The provider-assigned unique ID for this managed resource.
- ids string[]
- output
File string
- channels
Sequence[Get
Consumer Channels Channel] - dts_
instance_ strid - id str
The provider-assigned unique ID for this managed resource.
- ids Sequence[str]
- output_
file str
- channels List<Property Map>
- dts
Instance StringId - id String
The provider-assigned unique ID for this managed resource.
- ids List<String>
- output
File String
Supporting Types
GetConsumerChannelsChannel
- Consumer
Group stringId The ID of the consumer group.
- Consumer
Group stringName The name of the consumer group.
- Consumer
Group stringUser Name The username of the consumer group.
- Consumption
Checkpoint string The time point when the client consumed the last message in the subscription channel.
- Id string
The ID of the Consumer Channel.
- Message
Delay int The message delay time, for the current time data subscription channel in the earliest time of unconsumed messages of the difference, in Unix timestamp format, which is measured in seconds.
- Unconsumed
Data int The total number of unconsumed messages.
- Consumer
Group stringId The ID of the consumer group.
- Consumer
Group stringName The name of the consumer group.
- Consumer
Group stringUser Name The username of the consumer group.
- Consumption
Checkpoint string The time point when the client consumed the last message in the subscription channel.
- Id string
The ID of the Consumer Channel.
- Message
Delay int The message delay time, for the current time data subscription channel in the earliest time of unconsumed messages of the difference, in Unix timestamp format, which is measured in seconds.
- Unconsumed
Data int The total number of unconsumed messages.
- consumer
Group StringId The ID of the consumer group.
- consumer
Group StringName The name of the consumer group.
- consumer
Group StringUser Name The username of the consumer group.
- consumption
Checkpoint String The time point when the client consumed the last message in the subscription channel.
- id String
The ID of the Consumer Channel.
- message
Delay Integer The message delay time, for the current time data subscription channel in the earliest time of unconsumed messages of the difference, in Unix timestamp format, which is measured in seconds.
- unconsumed
Data Integer The total number of unconsumed messages.
- consumer
Group stringId The ID of the consumer group.
- consumer
Group stringName The name of the consumer group.
- consumer
Group stringUser Name The username of the consumer group.
- consumption
Checkpoint string The time point when the client consumed the last message in the subscription channel.
- id string
The ID of the Consumer Channel.
- message
Delay number The message delay time, for the current time data subscription channel in the earliest time of unconsumed messages of the difference, in Unix timestamp format, which is measured in seconds.
- unconsumed
Data number The total number of unconsumed messages.
- consumer_
group_ strid The ID of the consumer group.
- consumer_
group_ strname The name of the consumer group.
- consumer_
group_ struser_ name The username of the consumer group.
- consumption_
checkpoint str The time point when the client consumed the last message in the subscription channel.
- id str
The ID of the Consumer Channel.
- message_
delay int The message delay time, for the current time data subscription channel in the earliest time of unconsumed messages of the difference, in Unix timestamp format, which is measured in seconds.
- unconsumed_
data int The total number of unconsumed messages.
- consumer
Group StringId The ID of the consumer group.
- consumer
Group StringName The name of the consumer group.
- consumer
Group StringUser Name The username of the consumer group.
- consumption
Checkpoint String The time point when the client consumed the last message in the subscription channel.
- id String
The ID of the Consumer Channel.
- message
Delay Number The message delay time, for the current time data subscription channel in the earliest time of unconsumed messages of the difference, in Unix timestamp format, which is measured in seconds.
- unconsumed
Data Number The total number of unconsumed messages.
Package Details
- Repository
- Alibaba Cloud pulumi/pulumi-alicloud
- License
- Apache-2.0
- Notes
This Pulumi package is based on the
alicloud
Terraform Provider.