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

Websocket support #97

Open
haorendashu opened this issue Apr 10, 2024 · 2 comments
Open

Websocket support #97

haorendashu opened this issue Apr 10, 2024 · 2 comments
Labels
enhancement New feature or request

Comments

@haorendashu
Copy link

Using package github.com/gorilla/websocket to server websocket connection.
When call upgrader.Upgrade(w, r, nil), it return an error:

2024/04/10 21:16:42 failed to upgrade websocket: websocket: response does not implement http.Hijacker

It seems that the response need to implement http.Hijacker interface.

@syumai
Copy link
Owner

syumai commented Apr 12, 2024

This library is using JS API directly, so it's hard to provide http.Hijacker interface for Conn.
But WebSocket support can be implemented using Durable Object, so I want to try another approach (without providing http.Hijacker).
Thank you for submitting this issue!

@syumai syumai added the enhancement New feature or request label Aug 11, 2024
@igolaizola
Copy link

This library is using JS API directly, so it's hard to provide http.Hijacker interface for Conn.
But WebSocket support can be implemented using Durable Object, so I want to try another approach (without providing http.Hijacker).
Thank you for submitting this issue!

Hi @syumai! Have you made any progress with this approach? Been trying to make it work with websocket and Durable Objects but no luck so far.
Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants