All Products
Search
Document Center

How to handle inactive response Topic

Last Updated: Apr 29, 2021

Overview

This article mainly describes how to deal with historical slow Topic or inactive slow Topic to reduce the amount of occupied resources.

Details

You must first determine whether the original Topic is active. you can consider deleting the inactive original Topic. the procedure is as follows.

Determine the active status of the entire Topic

Two key metrics are used to determine whether a backend Topic is active.

Total messages (creatotaldomainamount) on the current server The time when the message was last updated. For more information, visit astyimeanttamamp.
Generally, if the total number of messages is 0, this means that the original Topic is inactive.

Generally, if the last update time of a message is a valid timestamp long before, the latest Topic is inactive.

note: If the last update time of a message is 0 or a negative value, the system does not obtain the timestamp. do not mark this as inactive. just ignore it.

The above two key indicators can be obtained in the following two ways:

View latest Topic information in administration console

Batch query latest Topic information by using the subscriptioninstance function

  1. Log on to the Message Queue for Apache Kafka console.
  2. In the top menu bar, select a region.
  3. In the left-side navigation pane, click instance management. on the page that appears, click the name of the Kafka instance that you want to query.
  4. In the left-side navigation pane of the instance details page, click stop topic management.
  5. On the partition Topic management page, find the target partition Topic and click partition status in the actions column.
  6. determine whether this rule Topic is active. If an inactive external Topic exists, record the name of this Topic and delete it by referring to the following section.
  1. Call create tex popice limist to obtain all the latest Topic information. For more information about how to call this operation, see GetTopicList.
  2. You can call this operation to obtain the message sending and receiving status of each else's Topic. For more information about how to call this operation, see GetTopicStatus.
  3. Record the LastTimeStamp and TotalCount values of each specific Topic in the returned results.
  4. refer to the preceding content to determine whether each physical Topic is active. If an inactive external Topic exists, record the name of this Topic and delete it by referring to the following section.

delete inactive decom topic

To reduce the occupied resources, you can perform the following steps to delete the physical Topic that is determined as inactive:

warning:

  • Ask people to determine whether it is necessary to delete the inactive opt.
  • Do not call the interface to automatically delete the entire Topic to avoid irreparable losses to the business due to program defects.
  1. Log on to the Message Queue for Apache Kafka console.
  2. In the top menu bar, select a region.
  3. In the left-side navigation pane, click instance management. on the page that appears, click the name of the Kafka instance that you want to query.
  4. In the left-side navigation pane of the instance details page, click stop topic management.
  5. On the other Topic management page, find the target physical Topic, click the More button in the actions column, and choose delete from the shortcut menu.
  6. In the displayed confirm dialog box, click confirm.
    warning: Be sure to confirm the error before you delete this Topic.

Related Documents

applicable to

  • Message Queue for Apache Kafka