10.2. Configure tracing at cache level


Once the tracing is configured at server level, it will be automatically enabled by default for all caches. A cache configuration level of tracing allows on the other hand to enable or disable it at cache level and at runtime.

Tracing categories

Several categories are potentially traced:

  • Container. That are all the main cache operations, such as replace, put, clear, getForReplace, remove operations and size. With the exception of all the getting operation.
  • Cluster. Operations that are replicated to another node in the same cluster.
  • X-Site. Operations that are replicated to another external site.
  • Persistence. All the operations involving persistence via a cache store and/or cache loader.

Each of category can be enabled/disabled at start time or runtime listing them in the categories list attribute. By default only the container category is enabled.

There is also the Security category, to trace security audit events. This category is configured globally, not only at cache level, since their events can have different scopes (cache, container or server), not only cache scope.

Enable/disable tracing for a given cache

XML

<replicated-cache>
    <tracing enabled="true" categories="container cluster x-site persistence" />
</replicated-cache>

JSON

{
  "distributed-cache": {
    "tracing": {
      "enabled" : true,
      "categories": [
        "container",
        "cluster",
        "x-site",
        "persistence"
      ]
    }
  }
}

YAML

distributedCache:
  tracing:
    enabled: true
    categories:
      - "container"
      - "cluster"
      - "x-site"
      - "persistence"

Enable/disable tracing at runtime

The cache-level tracing attribute enable is a mutable attribute, it means it can be changed at runtime without the need to restart the Infinispan cluster.

To change a mutable attribute both HotRod and REST APIs can be used.

HotRod

remoteCacheManager.administration()
   .updateConfigurationAttribute(CACHE_A, "tracing.enabled", "false");

REST

restClient.cache(CACHE_A)
   .updateConfigurationAttribute("tracing.enabled", "false");

Red Hat logoGithubredditYoutubeTwitter

詳細情報

試用、購入および販売

コミュニティー

会社概要

Red Hat は、企業がコアとなるデータセンターからネットワークエッジに至るまで、各種プラットフォームや環境全体で作業を簡素化できるように、強化されたソリューションを提供しています。

多様性を受け入れるオープンソースの強化

Red Hat では、コード、ドキュメント、Web プロパティーにおける配慮に欠ける用語の置き換えに取り組んでいます。このような変更は、段階的に実施される予定です。詳細情報: Red Hat ブログ.

Red Hat ドキュメントについて

Legal Notice

Theme

© 2026 Red Hat
トップに戻る