[midPoint-git] [Evolveum/midpoint] 2a2c7e: Improve the repository cache
mederly
noreply at github.com
Tue Jan 28 10:00:04 CET 2025
Branch: refs/heads/master
Home: https://github.com/Evolveum/midpoint
Commit: 2a2c7e846f6ae4107a97b2ecaaf68a16c1507703
https://github.com/Evolveum/midpoint/commit/2a2c7e846f6ae4107a97b2ecaaf68a16c1507703
Author: Pavol Mederly <mederly at evolveum.com>
Date: 2025-01-28 (Tue, 28 Jan 2025)
Changed paths:
M infra/schema/src/main/java/com/evolveum/midpoint/schema/GetOperationOptions.java
M infra/schema/src/main/java/com/evolveum/midpoint/schema/SearchResultList.java
M infra/schema/src/main/java/com/evolveum/midpoint/schema/SearchResultMetadata.java
M infra/schema/src/main/java/com/evolveum/midpoint/schema/constants/ObjectTypes.java
M repo/repo-cache/src/main/java/com/evolveum/midpoint/repo/cache/global/AbstractGlobalCache.java
M repo/repo-cache/src/main/java/com/evolveum/midpoint/repo/cache/global/GlobalCacheObjectValue.java
M repo/repo-cache/src/main/java/com/evolveum/midpoint/repo/cache/global/GlobalCacheQueryValue.java
M repo/repo-cache/src/main/java/com/evolveum/midpoint/repo/cache/global/GlobalQueryCache.java
M repo/repo-cache/src/main/java/com/evolveum/midpoint/repo/cache/handlers/BaseOpHandler.java
M repo/repo-cache/src/main/java/com/evolveum/midpoint/repo/cache/handlers/CacheAccessInfo.java
M repo/repo-cache/src/main/java/com/evolveum/midpoint/repo/cache/handlers/CacheSetAccessInfo.java
M repo/repo-cache/src/main/java/com/evolveum/midpoint/repo/cache/handlers/CacheSetAccessInfoFactory.java
M repo/repo-cache/src/main/java/com/evolveum/midpoint/repo/cache/handlers/CacheUpdater.java
A repo/repo-cache/src/main/java/com/evolveum/midpoint/repo/cache/handlers/CacheUseMode.java
M repo/repo-cache/src/main/java/com/evolveum/midpoint/repo/cache/handlers/CachedOpExecution.java
M repo/repo-cache/src/main/java/com/evolveum/midpoint/repo/cache/handlers/CachedOpHandler.java
M repo/repo-cache/src/main/java/com/evolveum/midpoint/repo/cache/handlers/CachingResultHandler.java
M repo/repo-cache/src/main/java/com/evolveum/midpoint/repo/cache/handlers/GetObjectOpExecution.java
M repo/repo-cache/src/main/java/com/evolveum/midpoint/repo/cache/handlers/GetObjectOpHandler.java
M repo/repo-cache/src/main/java/com/evolveum/midpoint/repo/cache/handlers/GetVersionOpExecution.java
M repo/repo-cache/src/main/java/com/evolveum/midpoint/repo/cache/handlers/GetVersionOpHandler.java
R repo/repo-cache/src/main/java/com/evolveum/midpoint/repo/cache/handlers/PassReason.java
A repo/repo-cache/src/main/java/com/evolveum/midpoint/repo/cache/handlers/RecordingResultHandler.java
R repo/repo-cache/src/main/java/com/evolveum/midpoint/repo/cache/handlers/ReportingResultHandler.java
M repo/repo-cache/src/main/java/com/evolveum/midpoint/repo/cache/handlers/SearchOpExecution.java
M repo/repo-cache/src/main/java/com/evolveum/midpoint/repo/cache/handlers/SearchOpHandler.java
M repo/repo-cache/src/main/java/com/evolveum/midpoint/repo/cache/invalidation/ChangeDescription.java
M repo/repo-cache/src/main/java/com/evolveum/midpoint/repo/cache/invalidation/Invalidator.java
A repo/repo-cache/src/main/java/com/evolveum/midpoint/repo/cache/local/LocalCacheObjectValue.java
A repo/repo-cache/src/main/java/com/evolveum/midpoint/repo/cache/local/LocalCacheQueryValue.java
M repo/repo-cache/src/main/java/com/evolveum/midpoint/repo/cache/local/LocalObjectCache.java
M repo/repo-cache/src/main/java/com/evolveum/midpoint/repo/cache/local/LocalQueryCache.java
M repo/repo-cache/src/main/java/com/evolveum/midpoint/repo/cache/local/QueryKey.java
A repo/repo-cache/src/main/java/com/evolveum/midpoint/repo/cache/local/SingleTypeQueryKey.java
A repo/repo-cache/src/main/java/com/evolveum/midpoint/repo/cache/values/CachedObjectValue.java
A repo/repo-cache/src/main/java/com/evolveum/midpoint/repo/cache/values/CachedQueryValue.java
M repo/repo-cache/src/test/java/com/evolveum/midpoint/repo/cache/TestRepositoryCache.java
Log Message:
-----------
Improve the repository cache
This commit aims to improve repo cache functionality and performance:
1. Allowing to return data that were requested with "exclude" retrieval
option (if they are present in the cache). This is needed e.g. when
serving queries from AssignmentTargetSearch (full exclusion).
2. Allowing to return data that were requested with "include" retrieval
option (if they are present in the cache, and do not contain any
incomplete items). This implements MID-6003.
3. Splitting query cache into per-type caches, aiming to more efficient
invalidation: we no longer need to iterate through all queries, but only
to ones for relevant types (supertypes + given type + subtypes).
The exclude/include items handling (plus existing zero-staleness option
handling) was implemented by replacing PassReason with CacheUseMode,
facilitating separate "can use cached data" and "can update cache"
conditions.
Work in progress.
Commit: 2af7a8e90a56a53d86284a51e589a0fffa5b777c
https://github.com/Evolveum/midpoint/commit/2af7a8e90a56a53d86284a51e589a0fffa5b777c
Author: Pavol Mederly <mederly at evolveum.com>
Date: 2025-01-28 (Tue, 28 Jan 2025)
Changed paths:
M repo/repo-cache/src/main/java/com/evolveum/midpoint/repo/cache/handlers/CacheUpdater.java
M repo/repo-cache/src/main/java/com/evolveum/midpoint/repo/cache/handlers/CacheUseMode.java
M repo/repo-cache/src/main/java/com/evolveum/midpoint/repo/cache/handlers/CachingResultHandler.java
M repo/repo-cache/src/main/java/com/evolveum/midpoint/repo/cache/handlers/GetObjectOpHandler.java
M repo/repo-cache/src/main/java/com/evolveum/midpoint/repo/cache/handlers/GetVersionOpHandler.java
M repo/repo-cache/src/main/java/com/evolveum/midpoint/repo/cache/handlers/SearchOpHandler.java
M repo/repo-cache/src/test/java/com/evolveum/midpoint/repo/cache/TestRepositoryCache.java
Log Message:
-----------
Support "exclude" search options in repo cache
Previous repo cache improvements did not completely support
the "retrieve=exclude" option when searching for objects:
they stored OIDs instead of full objects in the search result,
but did not discriminate between "cannot update objects cache"
and "cannot update query cache" situations, which is crucial
for supporting this scenario.
This commit fixes that, evaluating the ability to update object,
version, and query caches separately. The "don't retrieve" option
in AssignmentTargetSearchExpressionEvaluator now plays well with
the repo cache.
Compare: https://github.com/Evolveum/midpoint/compare/c14bddeb8259...2af7a8e90a56
To unsubscribe from these emails, change your notification settings at https://github.com/Evolveum/midpoint/settings/notifications
More information about the midPoint-svn
mailing list