You can call the DescribeTunnel operation to obtain the information of channels in a specified tunnel. A channel corresponds to a shard for the Stream operation of Tablestore.
Request parameters
Parameter | Description |
---|---|
TableName | The name of the table for which you want to query the tunnel information. |
TunnelName | The tunnel name. |
Response parameters
Parameter | Description |
---|---|
TunnelRPO | The last time when the tunnel consumes incremental data. The time equals the point in time when the slowest channel in the tunnel consumes data. Default value: January 1, 1970 (UTC). |
List<TunnelInfo> | The list of the tunnel, including the following information:
|
List<ChannelInfo> | The list of channels in the tunnel, including the following information:
|
ResponseInfo | Some other fields returned, including the RequestId field in the request.
RequestId uniquely identifies the request. |
Examples
req := &tunnel.DescribeTunnelRequest{
TableName: "testTable",
TunnelName: "testTunnel",
}
resp, err := tunnelClient.DescribeTunnel(req)
if err != nil {
log.Fatal("describe test tunnel failed", err)
}
log.Println("tunnel id is", resp.Tunnel.TunnelId)