grpc-ecosystem / go-grpc-middleware

Golang gRPC Middlewares: interceptor chaining, auth, logging, retries and more.
Apache License 2.0
6.33k stars 697 forks source link

AttemptMetadataKey = "x-retry-attempt" in retry StreamClientInterceptor #731

Open Boklazhenko opened 1 week ago

Boklazhenko commented 1 week ago

Hi, Is it possible add AttemptMetadataKey = "x-retry-attempt" https://github.com/grpc-ecosystem/go-grpc-middleware/blob/main/interceptors/retry/retry.go#L22

in StreamClientInterceptor ?

exactly the same way it works in UnaryClientInterceptor

thank you

johanbrandhorst commented 1 week ago

Seems like it might be possible to just add it to the context of the streaming call. Would you like to contribute this fix?

Boklazhenko commented 1 week ago

yes, i can try that later

Boklazhenko commented 4 days ago

https://github.com/grpc-ecosystem/go-grpc-middleware/pull/733 MR

I have lint error,

Снимок экрана 2024-11-27 в 18 08 14

something about copyright, readme, but I didn't touch it