-
Notifications
You must be signed in to change notification settings - Fork 690
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
Response does not implement http.Hijacker #354
Comments
Incidentally related to #338 This feature is needed to allow the gorilla websocket implementation to work with go-restful. |
thank you for contributing |
kujenga
added a commit
to kujenga/go-stdlib
that referenced
this issue
Jul 16, 2018
This is needed in order for users of this package to implement websocket support, as without it, the statusCodeTracker struct does not implement the correct interface because it knows nothing about the underlying implementation of it's embedded http.ResponseWriter. For reference, many other project have had this same issue, here's a list of some found in a quick search for the issue, I'm sure there are others as well: - golang/go#14797 - census-instrumentation/opencensus-go#642 - go-chi/chi#131 - nytimes/gziphandler#26 - caddyserver/caddy#133 - emicklei/go-restful#354
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
The go-restful
Response
type does not implementhttp.Hijacker
, and the underlyinghttp.ResponseWriter
loses the potentialhttp.Hijacker
implementation when it gets stored as an embedded interface, making it impossible to use a type assertion on theResponse
to get aHijacker
, even if the underlyingResponseWriter
actually does implementHijacker
.The text was updated successfully, but these errors were encountered: