2018-08-25 10:04:14 +02:00
2018-05-06 16:43:26 +02:00
2018-07-02 21:56:21 +02:00
2018-08-25 10:04:14 +02:00
2018-08-25 10:04:14 +02:00
2018-07-02 21:56:21 +02:00
2018-08-25 10:04:14 +02:00
2018-07-02 21:58:19 +02:00

µWS ("microWS") is simple and efficient message passing for the modern web.

Build optimized, standard web clients & servers in no time.

uWS::App a; // or uWS::SSLApp(options) for SSL

a.onGet("/", [](auto *s, auto *req, auto *args) {

    s->writeStatus("200 OK")->writeHeader("Hello", "World")->end(buffer);

}).onGet("/largefile", [](auto *s, auto *req, auto *args) {

    s->write([](int offset) {
        // stream chunks of the large file
    }, fileSize);

}).onPost("/upload/:filename", [](auto *s, auto *req, auto *args) {

    s->read([std::string filename = args[0]](int offset, auto chunk) {
        // stream chunks of data in to database with filename
    });

}).onWebSocket("/wsApi", [](auto *protocol) {

    protocol->onConnection([](auto *ws) {

        // store this websocket somewhere

    })->onMessage([](auto *ws, auto message, auto opCode) {

        ws->send(message, opCode);

    })->onDisconnection([]() {

        // remove this websocket

    });

}).listen("localhost", 3000, 0);

Deploy with confidence.

Feeling uncertain about your design? In need of professional help? Want to talk about the weather? I might have a few consulting hours for you and your business, send me, the author a mail and we'll figure out the rest.

Excel across the board.

<todo: insert new image here>

Pay what you want.

A free & open source (Zlib) project since 2016. Kindly sponsored by BitMEX, Bitfinex & Coinbase in 2018.

Become a paying sponsor of the project to unlock support, issue reporting, roadmaps and to drop suggestions.

S
Description
No description provided
Readme Apache-2.0
2.5 MiB
Languages
C++ 81.9%
C 14.2%
Rust 1.8%
Makefile 1.4%
JavaScript 0.7%