https://github.com/bluebrain/rockets
REST and websockets C++ library
Science Score: 10.0%
This score indicates how likely this project is to be science-related based on various indicators:
-
○CITATION.cff file
-
○codemeta.json file
-
○.zenodo.json file
-
○DOI references
-
○Academic publication links
-
✓Committers with academic emails
4 of 9 committers (44.4%) from academic institutions -
○Institutional organization owner
-
○JOSS paper metadata
-
○Scientific vocabulary similarity
Low similarity (13.1%) to scientific vocabulary
Keywords
cpp
http
javascript
json
json-rpc
json-schema
python
rest-server
typescript
websocket
websocket-client
websocket-library
websocket-server
Last synced: 6 months ago
·
JSON representation
Repository
REST and websockets C++ library
Basic Info
Statistics
- Stars: 38
- Watchers: 13
- Forks: 9
- Open Issues: 22
- Releases: 0
Archived
Topics
cpp
http
javascript
json
json-rpc
json-schema
python
rest-server
typescript
websocket
websocket-client
websocket-library
websocket-server
Created about 8 years ago
· Last pushed over 4 years ago
https://github.com/BlueBrain/Rockets/blob/master/
# Rockets > A library for easy HTTP and websockets messaging in C++ applications. [](https://travis-ci.org/BlueBrain/Rockets) [](https://lgtm.com/projects/g/BlueBrain/Rockets/context:cpp) # Table of Contents * [Features](#features) * [Build](#build) * [Usage](#usage) * [Contribute](#contribute) * [Funding & Acknowledgment](#Funding--Acknowledgment) * [License](#license) ## Features `Rockets` provides the following features: * [HTTP server](rockets/server.h) with integrated websockets support * [HTTP client](rockets/http/client.h) for making simple asynchronous requests (with or without payload) * [Websockets client](rockets/ws/client.h) for sending, broadcasting and receiving text and binary messages * Support for [JSON-RPC](https://www.jsonrpc.org) as a communication protocol over HTTP and websockets. `Rockets` extends the [2.0 specification](https://www.jsonrpc.org/specification) by providing support for [Cancellation and Progress notifications](rockets/jsonrpc/cancellableReceiver.h) of pending requests. * [Server](rockets/jsonrpc/server.h) * [C++ client](rockets/jsonrpc/client.h) * [Javascript client](js/README.md) * [Python client](python/README.md) * Event loop integration for [Qt](rockets/qt) and `libuv` through the appropriate `Server` constructor ## Build `Rockets` is a cross-platform library designed to run on any modern operating system, including all Unix variants. It requires a C++11 compiler and uses CMake to create a platform specific build environment. The following platforms and build environments are tested: * Linux: Ubuntu 16.04, 18.04 * Mac OS X: 10.9 - 10.14 `Rockets` requires the following external, pre-installed dependencies: * [libwebsockets](https://libwebsockets.org/) * [Boost.test](https://www.boost.org/doc/libs/1_69_0/libs/test/doc/html/index.html) (for unit tests) Building from source is as simple as: ```shell git clone --recursive https://github.com/BlueBrain/Rockets.git mkdir Rockets/build cd Rockets/build cmake -GNinja .. ninja ``` ## Usage ### Hello world REST server ```cpp #include#include int main(int , char** ) { rockets::Server server; std::cout << "Rockets REST server running on " << server.getURI() << std::endl; server.handle(rockets::http::Method::GET, "hello", [](auto) { return rockets::http::make_ready_response(rockets::http::Code::OK, "world"); }); for(;;) server.process(100); return 0; } ``` ### Hello world websockets server ```cpp #include #include int main(int , char** ) { rockets::Server server("", "myws"); std::cout << "Rockets websockets server running on " << server.getURI() << std::endl; server.handleText([](const auto& request) { return "server echo: " + request.message; }); for(;;) server.process(100); return 0; } ``` ### Production REST server example For a more elaborate use of a `Rockets` REST server, check out the [RestServer](https://github.com/BlueBrain/Tide/blob/master/tide/master/rest/RestServer.h) of [Tide](https://github.com/BlueBrain/Tide). ### Production websockets server example For a more elaborate use of a `Rockets` websockets server, check out the [RocketsPlugin](https://github.com/BlueBrain/Brayns/blob/master/plugins/Rockets/RocketsPlugin.cpp) of [Brayns](https://github.com/BlueBrain/Brayns). ## Contribute Follow the next guidelines when making a contribution: * Install our [pre-commit](https://pre-commit.com/#install) hooks with `pre-commit install` prior the first commit * Use [Conventional Commits](https://www.conventionalcommits.org) spec whenever making a commit * Keep PRs to a single feature or fix ## Funding & Acknowledgment The development of this software was supported by funding to the Blue Brain Project, a research center of the cole polytechnique fdrale de Lausanne (EPFL), from the Swiss governments ETH Board of the Swiss Federal Institutes of Technology. Copyright (c) 2021 Blue Brain Project/EPFL ## License Rockets is licensed under the LGPL version 3, unless noted otherwise, e.g., for external dependencies. See file LICENSE.txt for the full license. External dependencies are either LGPL or BSD-licensed. See file ACKNOWLEDGEMENTS.txt and AUTHORS.txt for further details. This library is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License version 3 as published by the Free Software Foundation. This library is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details. You should have received a copy of the GNU Lesser General Public License along with this library; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
Owner
- Name: The Blue Brain Project
- Login: BlueBrain
- Kind: organization
- Email: bbp.opensource@epfl.ch
- Location: Geneva, Switzerland
- Website: https://portal.bluebrain.epfl.ch/
- Repositories: 226
- Profile: https://github.com/BlueBrain
Open Source Software produced and used by the Blue Brain Project
GitHub Events
Total
- Fork event: 1
Last Year
- Fork event: 1
Committers
Last synced: 6 months ago
Top Committers
| Name | Commits | |
|---|---|---|
| Daniel Nachbaur | d****r@e****h | 47 |
| Raphael Dumusc | r****c@e****h | 36 |
| Roland Groza | r****a@e****h | 17 |
| Judit | j****c@u****m | 4 |
| ppodhajski | p****i@g****m | 4 |
| Daniel Nachbaur | d****r@g****m | 3 |
| Ben Morrice | b****e@e****h | 1 |
| Jonas Karlsson | j****n@f****g | 1 |
| Nadir Román Guerrero | N****e@u****m | 1 |
Committer Domains (Top 20 + Academic)
epfl.ch: 4
fripost.org: 1
Issues and Pull Requests
Last synced: 6 months ago
All Time
- Total issues: 7
- Total pull requests: 93
- Average time to close issues: about 1 month
- Average time to close pull requests: about 1 month
- Total issue authors: 6
- Total pull request authors: 10
- Average comments per issue: 0.86
- Average comments per pull request: 0.94
- Merged pull requests: 44
- Bot issues: 0
- Bot pull requests: 32
Past Year
- Issues: 0
- Pull requests: 0
- Average time to close issues: N/A
- Average time to close pull requests: N/A
- Issue authors: 0
- Pull request authors: 0
- Average comments per issue: 0
- Average comments per pull request: 0
- Merged pull requests: 0
- Bot issues: 0
- Bot pull requests: 0
Top Authors
Issue Authors
- rdumusc (2)
- NeolithEra (1)
- ghost (1)
- mmertama (1)
- rolandjitsu (1)
- pyup-bot (1)
Pull Request Authors
- dependabot[bot] (32)
- tribal-tec (16)
- rdumusc (15)
- pyup-bot (15)
- rolandjitsu (5)
- ppodhajski (4)
- karjonas (2)
- jplanasc (2)
- NadirRoGue (1)
- arnaudon (1)
Top Labels
Issue Labels
Pull Request Labels
dependencies (32)
javascript (10)
Dependencies
js/package.json
npm
- @babel/core ^7.0.0 development
- @babel/preset-env ^7.0.0 development
- @trust/webcrypto ^0.9.2 development
- @types/jest ^23.3.1 development
- @types/lodash ^4.14.116 development
- @types/node ^9.4.5 development
- babel-core ^7.0.0-0 development
- babel-jest ^23.4.0 development
- babel-plugin-lodash ^3.3.4 development
- camelcase ^4.1.0 development
- jest ^23.5.0 development
- mock-socket ^8.0.1 development
- npm-run-all ^4.1.3 development
- rollup ^0.65.0 development
- rollup-plugin-babel latest development
- rollup-plugin-commonjs ^9.1.6 development
- rollup-plugin-node-resolve ^3.3.0 development
- rollup-plugin-sourcemaps ^0.4.2 development
- rollup-plugin-uglify ^4.0.0 development
- rxjs ^6.2.1 development
- standard-version ^4.4.0 development
- ts-jest ^23.1.4 development
- tslint ^5.9.1 development
- typedoc ^0.11.1 development
- typescript 2.8.3 development
- crypto-uid ^0.3.0
- lodash ^4.17.10
- tslib ^1.9.0
js/yarn.lock
npm
- 757 dependencies
python/requirements.txt
pypi
- json-rpc *
- rx *
- websockets *
python/requirements_dev.txt
pypi
- Sphinx * development
- coverage * development
- jsonrpcserver * development
- nose * development
- nosexcover * development
- pandoc * development
- pycodestyle * development
- pydocstyle * development
- pylint * development
- sphinx_rtd_theme * development
- tox * development
python/requirements_rtd.txt
pypi
- json-rpc *
- nbsphinx *
- rx *
- websockets *