全部產品
Search
文件中心

Simple Log Service:get_cursor_time

更新時間:Jun 30, 2024

調用CLI命令根據遊標(Cursor)擷取服務端時間。

請求文法

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>]

請求參數

該命令的必選和特有參數描述如下。

參數名稱

數實值型別

是否必選

樣本值

描述

--project_name

String

aliyun-test-project

Project名稱。

--logstore_name

String

logstroe-a

Logstore名稱。

--shard_id

String

0

Shard ID。

--cursor

String

MTYxNDc1MDAyNzM3MzIwNTcxNA==

擷取時間戳記的遊標。

關於該命令的全域參數,請參見全域參數

樣本

  • 請求樣本

    使用預設帳號根據遊標查詢服務端時間。命令樣本如下:

    aliyunlog log get_cursor_time --project_name="aliyun-test-project" --logstore_name="logstore-a" --shard_id=0 --cursor="MTYxNDc1MDAyNzM3MzIwNTcxNA=="
  • 返回樣本

    {"cursor_time": 1620037252}

錯誤碼

如果返回報錯資訊,請參見具體介面的錯誤碼處理。更多資訊,請參見GetCursorTime錯誤碼處理

API參考

GetCursorTime