-
Notifications
You must be signed in to change notification settings - Fork 558
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
Context value not saved with "WithValue" entry on 2nd run without going through WithOnAccept for both http1.1 and http2 #733
Comments
This issue has been marked as invalid question, please give more information by following the |
Conclusion: HTTP1 maintenance of long links only triggers Accepct once. |
I have used two different conn and it is fine |
@li-jin-gou how to workaround? what do u mean two different conn is fine? what about 1 connection? i'm testing with 1 now |
I have used two different tcp conn and it is fine |
This does not appear to be a problem with the framework and you need to change the code. |
@li-jin-gou can u tell me where do i change in the code? the example i've given u, first run doesnt save the key "2" in context but "aaa"'s value is still there. why? how to change to have "2" 's value and key stick inside the code on 2nd run? |
@li-jin-gou can u pls provide a solution? basically i would like to save key "2" into the http call. it doesnt get saved but "aaa" is saved. |
Currently working on other issues😩, you can try again yourself |
The key is that a conn holds a ctx and HTTP1 will again keep long connection |
If you are already using hertz in production, please let us know - we will provide high-quality support for the needs of enterprise users - all you need to do is just reply this issue 👀 |
@li-jin-gou i cant reply to issue coz i havent fix this yet. it's still using version 0.5 of hertz with this issue i not sure what's the solution with. |
No time at the moment and currently working on other issues, you can try again yourself @kolinfluence refer to https://www.jetbrains.com/help/go/debugging-code.html and https://l-lin.github.io/2020-02-10-debug-with-vim-go/ |
@li-jin-gou ok i got it with debug tool etc. was refactoring code and understand the issue now. |
context value not saved with "WithValue" entry on 2nd run without going through WithOnAccept for both http1.1 and http2
with reference to this issue:
#731
result gotten is where value2 is not saved on consecutive runs. totally strange! used to work before
pls provide a workaround or fix this.
The text was updated successfully, but these errors were encountered: