Replies: 2 comments
-
Making the client Send is planned but for now I'd suggest using |
Beta Was this translation helpful? Give feedback.
0 replies
-
awc is mostly meant to be used inside actix-web. it's short for actix-web-client. So why pay for thread safety when we don't need it. That said making awc send In general if you need |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
After trying to use
awc
in an application withtonic
, I've encountered an issue, where enything the client does is notSend
. I've tracked it down to the fact that thedefault_headers
here usesRc
instead ofArc
.I understand the choice to share these between different clients, but the inability to use the
Client
inSend
contexts is really stopping me from using it.Why not use
Arc
? If there is only a single thread using the client, the overhead is minimal (Atomic operations in non-contended environments have low, non-zero overhead). And it adds the option to use client in Multi-threaded contexts (eg. My gRPC application performing http requests).Beta Was this translation helpful? Give feedback.
All reactions