All Products
Search
Document Center

OnsTrendGroupOutputTps

Last Updated: Mar 28, 2019

OnsTrendGroupOutputTps

You can call this operation to query message consumption statistics corresponding to a specified group ID within a period of time.

Description

When the system generates consumption statistics online, you can call this operation to query the following statistics corresponding to specified group ID:

  • The statistical curve of total messages consumed

  • The TPS statistical curve of messages consumed

Note: If the message volume is small and messages are distributed unevenly, the data output in TPS mode may be confusing. We recommend that you query the total number of messages consumed.

Request parameters

Name Type Required Description
PreventCache Long Yes The parameter used for CSRF verification, which can be set to the current system time. Unit: ms
InstanceId String No The ID of the instance.
Topic String Yes The name of the topic you want to query.
GroupId String Yes The group ID you want to query.
BeginTime Long Yes The start time of the query period. Unit: ms.
EndTime Long Yes The end time of the query period. Unit: ms.
Period Long Yes The sampling period. Unit: minutes. Valid values: 1, 5, and 10.
Type Integer Yes The type of statistics you want to query. Valid values:
  • 0: Query statistical curve of total messages consumed.
  • 1: Query the TPS statistical curve of messages consumed.

Response parameters

Name Type Description
RequestId String A common parameter. Each request has a unique ID.
HelpUrl String A help link.
data Data The dataset.

Dataset definition

Name Type Description
Title String The name of the table.
Records List(StatsDataDo) The collection point information.

StatsDataDo definition

Name Type Description
X Long The horizontal axis, representing the timestamp (unit: ms).
Y Float The vertical axis, representing data (TPS or total).

Examples

For more information about sample codes, see API sample code and endpoints.