-
-
Notifications
You must be signed in to change notification settings - Fork 49
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
Help with echo server #117
Comments
I believe I've solved the problem. My misunderstanding is that I was assuming |
@marten-seemann would you be interested in a PR that adds an examples directory and a simple echo server example, or is that not something you want in the repo? Looks like I'm not the first to struggle with this: #103 |
Sure, sounds like a good idea! Want to create a PR? |
Submitted #122 |
I think I have some fundamental misunderstandings about how to use this library. I'm trying to get a simple echo server running. The following is a self-contained example (uses certmagic to automatically get Let's Encrypt certs):
I'm never seeing anything printed, either on the client or server side. Interestingly, if I sleep for a second before
stream.CancelWrite(0)
then I get an error log: "stream canceled with error code 0". I think I'm incorrectly assuming that EOF will be sent after a call toCancelWrite
. Is that not the case? If not, is there a correct way to signal end of stream from the writer side?The text was updated successfully, but these errors were encountered: