agent-substrate / agent-substrate/substrate

Improve retry logic in atenet when resuming actors

Ouverte
#1,562 0 commentaires 0 réactions 0 personnes assignées Voir sur GitHub
area/api area/api-machinery area/network kind/design
Langage dominant
Go
Étoiles
1.8k
Forks
316
Merge moyen
2 j 43 min
PR mergées (30 j)
287

Description

The atenet is deciding when to retry a `ResumeActor` call just by looking at the gRPC status. It always retries `Aborted`, and retries `ResourceExhausted`, `FailedPrecondition` and and `Unavailable` if request parking is enabled.

The main issue with this approach is that the gRPC status codes are not granular enough to distinguish errors that should be retried from errors that shouldn't. For example, today we keep retrying `ResumeActor` calls on actors in `CRASHED` state.

I think we need a better contract so that downstream consumers of the API (e.g. atenet) can accurately decide whether to safely retry or not. One option we could consider is attaching the `RetryInfo`[1] proto in the status details.

FYI @bowei @LiorLieberman

[1]: https://pkg.go.dev/google.golang.org/genproto/googleapis/rpc/errdetails#RetryInfo

Guide de contribution

Ouvrir le guide de contribution

Évaluation

Cette issue n'a pas encore été évaluée.

Recevez les nouvelles issues par e-mail

Un résumé court des issues GitHub adaptées aux débutants.