Http server 'upgrade' event does not perform the basic methods of websocket connection #47386
Labels
duplicate
Issues and PRs that are duplicates of other issues or PRs.
feature request
Issues that request new features to be added to Node.js.
What is the problem this feature will solve?
Recently I've been modifying a websocket application in nodejs that previously used 'socket.io', such packages have their place in the market and are of great help for small and medium-sized applications.
The big problem is when these applications scale to large projects and we need to refine and have more control over our websockets connections and in these cases
we need to implement all basic websocket methods from handshake to decode and endocode message frames, ping and pong events, etc...
For example as the basic structure of the webscoket followed by an implementation on the http server below written with typescript
Create basic helpers websocket > touch src/base.ts
Create basic api websocket > touch src/app.ts
What is the feature you are proposing to solve the problem?
What is proposed is to natively bring the methods to work with websocket in http
This will help a lot and save time for us developers, it is very exhausting and discouraging to work with websocket in nodejs due to all the work mentioned above. This native implementation for websockets will help those who don't have such in-depth knowledge about networks and protocols and allow less dependency on packages with 'socket.io' and 'ws'
What alternatives have you considered?
There is not so clear nodejs documentation on how to work with websocket connection in http 'upgrade' event
The text was updated successfully, but these errors were encountered: