Search Results for

    Show / Hide Table of Contents
    View Source

    Interface IRepositoryCacheVersionAccessor

    Provides access to repository cache version information with request-level caching.

    Namespace: Umbraco.Cms.Core.Cache
    Assembly: Umbraco.Core.dll
    Syntax
    public interface IRepositoryCacheVersionAccessor
    Remarks

    This accessor retrieves cache version information from the database and caches it at the request level to minimize database queries. Cache versions are used to determine if cached repository data is still valid in distributed environments.

    Methods

    View Source

    CachesSynced()

    Notifies the accessor that caches have been synchronized.

    Declaration
    void CachesSynced()
    Remarks

    This method is called after cache synchronization to temporarily bypass version checking, preventing recursive sync attempts while repositories reload data from the database.

    View Source

    GetAsync(string)

    Retrieves the cache version for the specified cache key.

    Declaration
    Task<RepositoryCacheVersion?> GetAsync(string cacheKey)
    Parameters
    Type Name Description
    string cacheKey

    The unique identifier for the cache entry.

    Returns
    Type Description
    Task<RepositoryCacheVersion>

    The cache version if found, or null if the version doesn't exist or the request is a client-side request.

    View Source

    VersionChanged(string)

    Notifies of a version change on a given cache key.

    Declaration
    void VersionChanged(string cacheKey)
    Parameters
    Type Name Description
    string cacheKey

    Key of the changed version.

    • Edit this page
    • View Source
    In this article
    Back to top Copyright © 2016-present Umbraco
    Generated by DocFX