Skip to content

refactor: dry chain context #108

@mfw78

Description

@mfw78

Background

It's frustrating in that there appears to be some reasonable code duplication in the ChainContext class that is responsible for the sycnchronisation / warm up, and subsequent chain monitoring. This makes it difficult to read, reason, and regression test (maybe I just coin RRR 😆).

Details

It's desirable that the code in ChainContext be DRY'ed, with a corresponding complexity reduction. The resultant code should also be thoroughly tested.

Acceptance criteria

  • Loops in ChainContext for synchronisation are simplified.
  • Promote block watcher to run from the start of any sync.
  • /health API endpoint returns 5XX when chain isn't in sync (remove startupProbe, and use only livelinessProbe.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions