cache

package
v0.1.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 18, 2025 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewBranchCache

func NewBranchCache() *sturdyc.Client[[]models.Branch]

NewBranchCache creates a sturdyc cache client for branch lists with early refreshes enabled.

func NewOrganizationCache

func NewOrganizationCache() *sturdyc.Client[[]models.Organization]

newOrganizationCache creates a sturdyc cache client for organization lists with early refreshes enabled.

func NewRepositoryCache

func NewRepositoryCache() *sturdyc.Client[[]models.Repository]

newRepositoryCache creates a sturdyc cache client for repository lists with early refreshes enabled. Maximum number of entries in the cache. Exceeding this number triggers eviction.

Types

type Manager

type Manager struct {
	// contains filtered or unexported fields
}

Manager provides centralized cache management for all cache instances.

func NewManager

func NewManager(
	repositoryCache *sturdyc.Client[[]models.Repository],
	organizationCache *sturdyc.Client[[]models.Organization],
	branchCache *sturdyc.Client[[]models.Branch],
) *Manager

NewManager creates a new cache manager with all cache instances.

func (*Manager) GetSupportedEndpoints

func (m *Manager) GetSupportedEndpoints() []string

GetSupportedEndpoints returns a list of supported cache endpoints.

func (*Manager) InvalidateCache

func (m *Manager) InvalidateCache(endpoint string) error

InvalidateCache invalidates the specified cache type.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL