Viewing and deleting assembly count limit enforcement keys

How to view and delete assembly count limit enforcement keys.

About this task

When defined, an assembly count limit restricts the number of requests in progress for subsequent actions. When the count limit is exceeded, an error is generated. The enforcement keys can be persisted on the RAID volume or stored in memory.

Enforcement keys for count limit schemes that are named in the API collection, API gateway, or API plan can be viewed and deleted. Keys for rate limit definitions of type Count persist until the gateway is restarted and cannot be viewed or deleted.

You can use the Assembly count limit enforcement metrics status provider to view the keys for count limit schemes that are named in the API collection, API gateway, or API plan. When the storage contains a large volume of keys, the results can take several minutes to display.

The Assembly count limit enforcement metrics status provider shows the following information.
  • The configuration name where the count limit is defined.
  • The configuration level where the count limit is defined. Assembly schemes can be defined at the API collection, API gateway, or API plan level.
  • The name of the count limit scheme.
  • The maximum count to allow.
  • The hard limit that rejects requests when the threshold is exceeded.
  • Whether to use the cache first.
  • Whether the count limit is a client limit. A client limit returns 429 when exceeded. A non-client limit returns 503.
  • The name of the API that the limit applies to.
  • The application ID that the limit applies to.
  • The client ID that the limit applies to.
  • The dynamic value for the limit.
  • The current value of the counter for the limit.

You can delete keys from an application domain or the default domain:

  • From an application domain.
    • Delete individual key.
    • Delete all keys.
  • From the default domain.
    • Delete individual key for a specific domain.
    • Delete all keys for a specific domain.
    • Delete all keys for all domains.

To delete keys that match a specific pattern in a specified batch size, use one of the following methods.

  • The delete assembly-countlimit command with a batch size in the range of 1000 - 50000.
  • The CountLimitAssemblyDeleteKeyBatch REST action with a batch size in the range of 1000 - 50000. The default batch size is 10000.

Procedure

  1. Switch to the domain.
  2. In the search field, enter enforcement.
  3. From the search results, click Assembly count limit enforcement metrics.
  4. Delete keys according to your needs.