Skip to content

Latest commit

 

History

History
37 lines (24 loc) · 1.41 KB

ehcache.mdx

File metadata and controls

37 lines (24 loc) · 1.41 KB
title Ehcache Integration
description Learn how to trace Ehcache cache operations with Sentry.

Sentry can trace cache operations performed by Ehcache, a widely-used Java caching library. Cache spans appear in Sentry's Caches dashboard.

<PlatformSection supported={["java.spring-boot"]}>

Spring Boot

If you're using Ehcache as your Spring Boot cache provider, cache tracing is built into the Sentry Spring Boot starter. Enable it in your configuration:

sentry.enable-cache-tracing=true
sentry.traces-sample-rate=1.0
sentry:
  enable-cache-tracing: true
  traces-sample-rate: 1.0

All @Cacheable, @CachePut, and @CacheEvict operations will automatically produce Sentry spans — no additional dependencies or code changes required.

See enableCacheTracing for more details on this option.

<PlatformSection notSupported={["java.spring-boot"]}>

Plain Java

Ehcache 3 implements the JCache (JSR-107) API natively. Use it together with the Sentry JCache integration to trace cache operations.