Skip to content

typelayer: the process image zone depends on which tenant binds first #726

Description

@EricAndrechek

Found while moving the type layer to chtypes 1.0 in draft PR #712 (branch chtypes-v2).

Problem. A process has one chtypes image zone. It is fixed for the life of the process, and it decides how zone-less DateTime columns and the functions over them are computed. WaveHouse takes it from the first tenant that is actually served: the tenant's zone name is recognised, an artifact is installed for its ClickHouse line, and its first open succeeds. When tenants' servers run in different time zones, which tenant that is depends on which tenant's discovery finishes first. That is a race between discovery loops, so it can change from one restart to the next.

Effect.

Evidence.

  • Inferred from internal/typelayer/zone.go (openLine/openFirst) and internal/app discovery wiring on the PR branch.
  • The image-zone subprocess tests in internal/typelayer/zone_test.go pin the first-served rule. They cover a Tokyo tenant first, a missing artifact first, an unrecognised zone first, a failed first open, and concurrent first binds. The concurrent case shows exactly one commit, but not which tenant wins.
  • Not reproduced end to end against two ClickHouse servers in different zones.

Who meets it. Only processes whose tenants' servers report different time zones. A deployment whose tenants share one zone always gets that zone.

Related: #717 (zone-name spelling).

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions