Skip to content

sql,server: abstract at least 3 of the tenant rangefeed watchers #110969

@knz

Description

@knz

Requested by @yuzefovich in #110947.

Is your feature request related to a problem? Please describe.

The code in the following watchers is very similar:

  • tenant settings watcher
  • tenant info watcher
  • tenant capabilities watcher
  • settings watcher

It is very redundant and yet needs to do things in a precise order to avoid race conditions and deadlocks.
We need to reduce this complexity to increase maintainability.

Describe the solution you'd like

Abstract at least 2 (preferably at least 3) of the watchers into a common library used in multiple places.

Also merge the tenant capabilities and info watchers into just 1.

Epic: CRDB-26691

Jira issue: CRDB-31697

Metadata

Metadata

Assignees

No one assigned

    Labels

    A-multitenancyRelated to multi-tenancyC-enhancementSolution expected to add code/behavior + preserve backward-compat (pg compat issues are exception)T-multitenantIssues owned by the multi-tenant virtual team

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions