Giter Club home page Giter Club logo

helio's Introduction

Helio - backend development framework in C++ using io_uring and epoll event-loop.

=====

ci-tests

codecov

Async is a set of C++ primitives that allows you efficient and rapid development in c++17 on Linux systems. The focus is mostly on backend development, data processing, etc.

  1. Dependency on abseil-cpp
  2. Dependency on Boost 1.71
  3. Uses ninja-build on top of cmake
  4. Built artifacts are docker-friendly.
  5. HTTP server implementation.
  6. Fibers library and fiber-friendly synchronization primitives.

I will gradually add explanations for the most crucial blocks in this library.

Setting Up & Building

> sudo ./install-dependencies.sh
> ./blaze.sh -release
> cd build-opt && ninja -j4 echo_server

third_party folder is checked out under build directories.

Then, from 2 tabs run:

  server> ./echo_server --logtostderr
  client> ./echo_server --connect=localhost --n 100000 --c=4

HTTP

HTTP handler is implemented using Boost.Beast library. It's integrated with the io_uring-based ProactorPool. Please see http_main.cc, for example. HTTP also provides support for backend monitoring (Varz status page) and for an extensible debugging interface. With monitoring C++ backend returns JSON object that is formatted inside status page in the browser. To check how it looks, please go to localhost:8080 while echo_server is running.

Self-profiling

Every http-powered backend has integrated CPU profiling capabilities using gperf-tools and pprof Profiling can be triggered in prod using magic-url commands. Enabled profiling usually has a very minimal impact on CPU performance of the running backend.

Logging

Logging is based on Google's glog library. The library is very reliable, performant, and solid. It has many features that allow resilient backend development. Unfortunately, Google's version has some bugs, which I fixed (waiting for review...), so I use my own fork. Glog library gives me the ability to control the logging levels of a backend at run-time without restarting it.

Tests

ASYNC uses a googletest+gmock unit-test environment.

Conventions

Third_party packages have TRDP:: prefix in CMakeLists.txt. absl libraries have prefix absl::....

helio's People

Contributors

adiholden avatar andydunstall avatar boazsade avatar chaitanya110703 avatar chakaz avatar dranikpg avatar iko1 avatar kostasrim avatar romange avatar royjacobson avatar super-long avatar talbii avatar vvhungy avatar yashsalunke12 avatar yuelimv avatar zhjwpku avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.