Zero-copy upgrade. No intermediate allocations during I/O. Low-level API which allows building your own logic of packet handling and buffers reuse. High-level wrappers and helpers around API in wsutil package, which allow to start fast without digging the protocol internals. Existing WebSocket implementations do not allow users to reuse I/O buffers between connections in clear way. This library aims to export efficient low-level interface for working with the protocol without forcing only one way it could be used. Library is tagged as v1* so its API must not be broken during some improvements or refactoring. Example applications using ws are developed in separate repository ws-examples. We can apply the same pattern to read and write structured responses through a JSON encoder and decoder.Zero-copy upgrade helps to avoid unnecessary allocations and copying while handling HTTP Upgrade request.

Features

  • No intermediate allocations during I/O
  • Low-level API which allows to build your own logic of packet handling and buffers reuse
  • Zero-copy upgrade
  • High-level wrappers and helpers around API in wsutil package, which allow to start fast without digging the protocol internals
  • Library is tagged as v1* so its API must not be broken during some improvements or refactoring
  • This implementation of RFC6455 passes Autobahn Test Suite and currently has about 78% coverage

Project Samples

Project Activity

See All Activity >

License

MIT License

Follow ws

ws Web Site

You Might Also Like
MongoDB Atlas runs apps anywhere Icon
MongoDB Atlas runs apps anywhere

Deploy in 115+ regions with the modern database for every enterprise.

MongoDB Atlas gives you the freedom to build and run modern applications anywhere—across AWS, Azure, and Google Cloud. With global availability in over 115 regions, Atlas lets you deploy close to your users, meet compliance needs, and scale with confidence across any geography.
Start Free
Rate This Project
Login To Rate This Project

User Reviews

Be the first to post a review of ws!

Additional Project Details

Operating Systems

Linux, Mac, Windows

Programming Language

Go

Related Categories

Go Libraries, Go WebSocket Servers, Go WebSocket Libraries

Registered

2023-01-10