graphprotocol / graphprotocol/indexer

[FEATURE] readiness endpoint

Open
#1,029 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
TypeScript
Stars
262
Forks
148
PR merge metrics
No merged PRs in 30d

Description

When restarting the indexer it takes some time to load all the resources and to check all SG's. during this loading period the loadbalancer is sending traffic to the pod and those queries fail increasing the error rate.

I'd like to propose to create a /ready readiness endpoint which starts to respond with 200 http code only after everything was loaded and checked. This will allow the loadbalancer to know when to start sending traffic to the backend.

We could configure a delay for the traffic to be sent to the backends but that's a static configuration and sometimes it takes less / more time than usual so better is to have an endpoint that we could configure the loadbalancer to query to know when to send traffic

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Locate the indexer's startup path, resource-loading and SG-checking logic, plus any existing health endpoints. Verify that readiness remains unavailable during loading and returns HTTP 200 only after all resources and SG checks complete.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript
Domain
backend, devops
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.