Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

agent,common: Improve control of subgraph deployment health safety check #852

Merged
merged 1 commit into from
Feb 9, 2024

Conversation

fordN
Copy link
Contributor

@fordN fordN commented Jan 26, 2024

Effect

  • Allow indexers to control the subgraph deployment safety check:
    • Set indexingRule.safety = true to turn on the deployment health check. The agent will not allocate to the deployment if it has health = failed.
    • Set indexingRule.safety = false or null to turn off the deployment health check. The agent will still allocate to subgraph deployments with health = failed.

Changes

  • Move the deployment health check to earlier in the decision process, within reconcileDeploymentAllocationAction(). This gives the check access to the indexingRule so it can use the safety property, it also is useful to prevent action from being added to the queue in the first place. In the previous/current setup the action does not included in a transaction but it will remain in the queue and continue to be retried.

@fordN fordN force-pushed the ford/improve-control-of-subgraph-health-safety branch 2 times, most recently from ee0eb0e to b5cc50e Compare January 26, 2024 19:23
- Previously the safety check occurred later in the process. We should
identify early that a subgraph is failed and safety = true to not
add the action to the queue in the first place. The other benefit
of moving this check is so it has access to the corresponding rule
so the safety property can be used here for control.
@fordN fordN force-pushed the ford/improve-control-of-subgraph-health-safety branch from b5cc50e to 07ad76b Compare January 31, 2024 18:57
@fordN fordN self-assigned this Jan 31, 2024
@fordN fordN added indexer-agent enhancement New feature or request labels Jan 31, 2024
@fordN fordN requested a review from saihaj January 31, 2024 18:59
@fordN fordN merged commit e701da8 into main Feb 9, 2024
10 checks passed
@fordN fordN deleted the ford/improve-control-of-subgraph-health-safety branch February 9, 2024 18:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request indexer-agent
Projects
Status: 🚗 Merged
Development

Successfully merging this pull request may close these issues.

2 participants