Retrieves the server-side time that corresponds to a cursor.
Request syntax
aliyunlog log get_cursor_time --project_name=<value> --logstore_name=<value> --shard_id=<value> --cursor=<value> [--access-id=<value>] [--access-key=<value>] [--sts-token=<value>] [--region-endpoint=<value>] [--client-name=<value>] [--jmes-filter=<value>] [--format-output=<value>] [--decode-output=<value>]
Request parameters
The following table describes the command-specific parameters.
|
Parameter |
Numeric type |
Required |
Example |
Description |
|
--project_name |
String |
Yes |
aliyun-test-project |
The name of the project. |
|
--logstore_name |
String |
Yes |
logstroe-a |
The name of the Logstore. |
|
--shard_id |
String |
Yes |
0 |
The ID of the shard. |
|
--cursor |
String |
Yes |
MTYxNDc1MDAyNzM3MzIwNTcxNA== |
The cursor from which to get the timestamp. |
For more information about global parameters, see Global parameters.
Examples
-
Request example
Query the server-side time from a cursor by using the default account.
aliyunlog log get_cursor_time --project_name="aliyun-test-project" --logstore_name="logstore-a" --shard_id=0 --cursor="MTYxNDc1MDAyNzM3MzIwNTcxNA==" -
Response example
{"cursor_time": 1620037252}
Error codes
For more information about error codes, see Error codes.