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

Support Websockets #1

Open
ikitommi opened this issue Jul 9, 2019 · 1 comment
Open

Support Websockets #1

ikitommi opened this issue Jul 9, 2019 · 1 comment
Labels
enhancement New feature or request

Comments

@ikitommi
Copy link
Member

ikitommi commented Jul 9, 2019

No description provided.

@ikitommi ikitommi added the enhancement New feature or request label Jul 9, 2019
@plexus
Copy link
Contributor

plexus commented Oct 31, 2019

Here's a starting point: https://github.com/plexus/procflow/blob/master/src/procflow/http/websocket.clj

It assumes you're using reitit like this

["/ws" {:websocket {:on-connect procflow.http/on-connect
                                                     :on-receive procflow.http/on-receive
                                                     :on-close   procflow.http/on-close
                                                     :on-error   procflow.http/on-error}}]

Not optimized at all, probably still has serious bugs, and contains some obvious inefficiencies (e.g. it will match all non-websocket routes twice), but like I said it's a starting point.

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

2 participants