Skip to content

Guidance on cloning async_nats::Client #622

Answered by stevelr
jaskij asked this question in Q&A
Discussion options

You must be logged in to vote

Clients are lightweight objects and you can clone as many as you need, and let rust drop them whenever you don't need them.

Clients and Subscriptions share the same tcp connection created by the call to connect().

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by jaskij
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants