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

Other Useful Business Software
$300 in Free Credit Towards Top Cloud Services Icon
$300 in Free Credit Towards Top Cloud Services

Build VMs, containers, AI, databases, storage—all in one place.

Start your project in minutes. After credits run out, 20+ products include free monthly usage. Only pay when you're ready to scale.
Get Started
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