Skip to content
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

Req Protocol: Free Msg Early if Resends Disabled #2106

Open
shikokuchuo opened this issue Feb 27, 2025 · 0 comments · May be fixed by #2107
Open

Req Protocol: Free Msg Early if Resends Disabled #2106

shikokuchuo opened this issue Feb 27, 2025 · 0 comments · May be fixed by #2107

Comments

@shikokuchuo
Copy link
Contributor

Originally posted in the 'Planning for NNG2.0' Discussion:

Also just to have this on the record. Hopefully can be a 1.x item.

req/rep when NNG_OPT_REQ_RESENDTIME is set to 0 for the req socket, i.e. no resends, free the msg set on the context i.e. req0_ctx->req_msg early when the send is complete without waiting for the reply.

Originally posted by @shikokuchuo in #1781 (comment)

This is for use in a typical RPC context where I do not use NNG-level retries, so it serves no purpose to hang onto the sent message. This helps to minimize total memory usage when many async requests are underway.

I have a solution which I will propose in a PR.

@shikokuchuo shikokuchuo linked a pull request Feb 27, 2025 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant