You are viewing a plain text version of this content. The canonical link for it is here.
Posted to oak-issues@jackrabbit.apache.org by "Rishabh Daim (Jira)" <ji...@apache.org> on 2026/10/06 05:05:00 UTC

[jira] [Updated] (OAK-12436) Support per-cache Caffeine maintenance mode

     [ https://issues.apache.org/jira/browse/OAK-12436?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Rishabh Daim updated OAK-12436:
-------------------------------
    Description: 
h3. Summary
Add per-cache SYNC/ASYNC Caffeine maintenance selection to the shared CacheBuilder API. ASYNC remains the default.

h3. Scope and order
This is the first PR, based on the latest trunk. Bundle policy is selected explicitly by each cache or by the bundle's own override. OAK-12438 separately migrates Segment Tar's FT_OAK-12290 integration. OAK-12425 adds DocumentNodeStore per-CacheType wiring and entry-owned metadata. OAK-12426, including OAK-12437, benchmarks the completed production paths.

h3. Acceptance Criteria
# CacheBuilder supports independent SYNC and ASYNC selection per instance, validates null input, and preserves the ASYNC default.
# Explicit cache selection takes precedence over the deprecated legacy shared toggle while its existing Segment consumer is migrated by OAK-12438.
# Refresh loaders remain asynchronous and zero-capacity caches retain inline eviction.
# Exported API package version and binary compatibility are handled, with deprecated toggle symbols retained.
# Tests exercise defaults, independent policies, legacy precedence, refresh and zero capacity; targeted validation uses java17.
# Complete all implementation and stack dependencies before the final change-reviewer pass, then fix verified findings and push in dependency order.


  was:
h3. Summary
Let each Caffeine cache choose synchronous or asynchronous maintenance, and let a bundle override the choice for only the caches it owns.

h3. Context
Caffeine maintenance is currently selected through shared CacheBuilder state. This makes the Segment Tar feature toggle capable of affecting caches built by other bundles. Keep ASYNC as the default, provide a per-cache setting, and make bundle overrides local to their owning bundle. The Segment Tar OAK-12290 toggle must affect Segment Tar caches only. oak-store-document must be able to select its mode independently.

h3. Acceptance Criteria
# CacheBuilder exposes a per-cache SYNC or ASYNC maintenance choice and defaults to ASYNC.
# A bundle can override the mode for caches it owns without changing the mode of caches built by another bundle.
# The Segment Tar OAK-12290 feature toggle changes Segment Tar cache maintenance only.
# oak-store-document can choose its cache mode independently of Segment Tar.
# Refresh reloads remain asynchronous and zero-capacity cache maintenance remains synchronous.
# Tests cover default mode, explicit modes, override scope, and callback execution behavior.
# Existing public API and feature-toggle compatibility are reviewed and documented.


        Summary: Support per-cache Caffeine maintenance mode  (was: Support per-cache Caffeine maintenance mode with bundle-scoped overrides)

> Support per-cache Caffeine maintenance mode
> -------------------------------------------
>
>                 Key: OAK-12436
>                 URL: https://issues.apache.org/jira/browse/OAK-12436
>             Project: Jackrabbit Oak
>          Issue Type: Task
>            Reporter: Rishabh Daim
>            Priority: Major
>
> h3. Summary
> Add per-cache SYNC/ASYNC Caffeine maintenance selection to the shared CacheBuilder API. ASYNC remains the default.
> h3. Scope and order
> This is the first PR, based on the latest trunk. Bundle policy is selected explicitly by each cache or by the bundle's own override. OAK-12438 separately migrates Segment Tar's FT_OAK-12290 integration. OAK-12425 adds DocumentNodeStore per-CacheType wiring and entry-owned metadata. OAK-12426, including OAK-12437, benchmarks the completed production paths.
> h3. Acceptance Criteria
> # CacheBuilder supports independent SYNC and ASYNC selection per instance, validates null input, and preserves the ASYNC default.
> # Explicit cache selection takes precedence over the deprecated legacy shared toggle while its existing Segment consumer is migrated by OAK-12438.
> # Refresh loaders remain asynchronous and zero-capacity caches retain inline eviction.
> # Exported API package version and binary compatibility are handled, with deprecated toggle symbols retained.
> # Tests exercise defaults, independent policies, legacy precedence, refresh and zero capacity; targeted validation uses java17.
> # Complete all implementation and stack dependencies before the final change-reviewer pass, then fix verified findings and push in dependency order.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)