-
Notifications
You must be signed in to change notification settings - Fork 500
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
Support for std::sync::Arc
as indirection
#429
Comments
This would also be nice in conjunction with Tonic servers. If we had Config::new()
.arc(&[".my_service.FooRequest.my_big_field"])
.compile_protos(...) …then we could get away with fewer wasted clones in RPC handlers. I think that this might be nice, but am not strongly lobbying for it, |
Sounds like a good addition! We should probably also support |
This could also be helpful (I think) for cases where a large object is received in the request and needs to outlive it. Allowing that object to be an |
🤔Seems it's possible to implement the feature, I'll try this. |
will this be on the road map? |
|
Yeah I can here just to comment/upvote this. |
@jasongoodwin do you happen to have an implementation for this? I'm in a similar position, only the data I'm sending can get quite large. |
Honestly... why does It's actually blocking me for another reason: I tried implementing
But due to the requirement of The requirement of |
Hi, I wonder, would be possible to allow prost-types to be wrapped inside
std::sync::Arc
? The reason is that I want my messages to be sendable across both processes and threads. When sent across processes, my messages should be serialized/deserialized withprost
. When sent across threads, I would like to use reference counting.Thanks for the great crate.
The text was updated successfully, but these errors were encountered: