agent-substrate / agent-substrate/substrate

Improve retry logic in atenet when resuming actors

Đang mở
#1,562 0 bình luận 0 reaction 0 người được giao Xem trên GitHub
area/api area/api-machinery area/network kind/design
Ngôn ngữ chính
Go
Star
1.8k
Fork
316
Merge trung bình
2 ngày 43 phút
Pull request đã merge (30 ngày)
287

Mô tả

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

Hướng dẫn đóng góp

Mở hướng dẫn đóng góp

Đánh giá

Issue này chưa được đánh giá.

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.