文档首页 > > SDK参考> 使用SDK> 使用SDK(Java)>

查询通道详情

查询通道详情

分享
更新时间:2021/01/30 GMT+08:00

参考初始化DIS客户端的操作初始化一个DIS客户端实例,实例名称为dic。

使用DIS SDK查询指定通道信息。

1
2
3
4
String streamName = "myStream";
DescribeStreamRequest describeStreamRequest = new DescribeStreamRequest();
describeStreamRequest.setStreamName(streamName);
System.out.println("descStream: " + JsonUtils.objToJson(dic.describeStream(describeStreamRequest)));

查询通道的返回信息如下。

1
descStream: DescribeStreamResult [streamId=JnYbsMfWNn81e8n2mOC, streamName=myStream, createTime=1540977519187, lastModifiedTime=1540977519983, retentionPeriod=24, status=RUNNING, streamType=ADVANCED, dataType=BLOB, writablePartitionCount=2, readablePartitionCount=2, partitions=[PartitionResult{partitionId='shardId-0000000000', hashRange='[0 : 4611686018427387902]', status='ACTIVE', parentPartitionIds='null', sequenceNumberRange='[0 : 13286444]'}, PartitionResult{partitionId='shardId-0000000001', hashRange='[4611686018427387903 : 9223372036854775807]', status='ACTIVE', parentPartitionIds='null', sequenceNumberRange='[0 : 13288589]'}], hasMorePartitions=false, updatePartitionCounts=null]
分享:

    相关文档

    相关产品