canonical / canonical/microcloud-cluster-manager

cache config

Open
#31 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Go
Stars
21
Forks
5
Avg merge
13h 56m
Merged PRs (30d)
30

Description

We need to implement a cache for configs, since relevant data will need to be used per request e.g. oidc settings. We wouldn’t want to make a DB call every time to get those configs. This means we need to implement it in a distributed manner as well i.e. if configs gets updated, all members in the cluster will need to update their local cache and the cache will need to be locked with a Mutex (not RWMutex). Furthermore, we also need to consider the possibility of cache update failing on a member, we would need to revert the changes to configs for all members.

This should be done for both manager and member specific configs.

Contributor guide

Open the contributing guide

Research direction

Start by locating the code paths that read and update manager-specific and member-specific configs, then trace how config changes are propagated across cluster members. Define the cache, Mutex locking, update-failure handling, and rollback behavior before implementing. Done means repeated requests avoid unnecessary database calls and every member stays consistent after successful or failed updates.

Written by the indexing model from the issue text.

Assessment

Tech stack
go
Domain
backend, databases, distributed-systems
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.