GithubHelp home page GithubHelp logo

tempbottle / libquic Goto Github PK

View Code? Open in Web Editor NEW

This project forked from devsisters/libquic

0.0 2.0 1.0 15.32 MB

QUIC, a multiplexed stream transport over UDP

Home Page: http://devsisters.github.io/goquic/

License: BSD 3-Clause "New" or "Revised" License

CMake 0.33% Makefile 1.81% C 36.83% C++ 44.44% Perl 11.19% Shell 0.07% Go 3.34% Assembly 1.15% Python 0.49% CSS 0.01% Objective-C 0.12% Objective-C++ 0.21% Protocol Buffer 0.02%

libquic's Introduction

QUIC, a multiplexed stream transport over UDP

QUIC is an experimental protocol aimed at reducing web latency over that of TCP. On the surface, QUIC is very similar to TCP+TLS+SPDY implemented on UDP. Because TCP is implemented in operating system kernels, and middlebox firmware, making significant changes to TCP is next to impossible. However, since QUIC is built on top of UDP, it suffers from no such limitations.

Key features of QUIC over existing TCP+TLS+SPDY include

  • Dramatically reduced connection establishment time
  • Improved congestion control
  • Multiplexing without head of line blocking
  • Forward error correction
  • Connection migration

See Chromium QUIC Page for detailed information.

libquic

This repository is sources and dependencies extracted from Chromium's QUIC Implementation with a few modifications and patches to minimize dependencies needed to build QUIC library.

Notable and only dependency is BoringSSL. The BoringSSL sources is already embedded in this repository and linked with CMake build file. You don't need any kind of dependency installs.

Language Bindings

This library is intended as an essential reference point for other language bindings and possibly for integration with other C/C++ codebase such as HTTP servers like Apache or nginx.

Currently there is only one experimental language binding:

Getting Started

How to build

Building with CMake and Ninja (Recommended):

$ mkdir build/
$ cd build/
$ cmake -GNinja ..
$ ninja

Building with CMake and Make:

$ mkdir build/
$ cd build/
$ cmake ..
$ make -j 4

make -j limits the number of simultaneously executed Recepies. Adapt this number to the capabilities of your build machine.

libquic.a library file will be generated. libssl.a, libcrypto.a will be located in build/boringssl directory.

To do release builds run $ cmake -GNinja -DCMAKE_BUILD_TYPE=Release .. instead of $ cmake -GNinja ...

How to integrate

In order to integrate libquic to your code, your best source of documentation is official Chromium QUIC toy client and server. Golang binding will help too.

Syncing from Upstream

Great effort has been made to make syncing from upstream Chromium sources as effortless as possible. See DEPS file for all the dependencies. See manage.py script for actual syncing.

If you want to apply upstream changes,

  1. Clone & Checkout chromium upstream.
  2. Build QUIC server: cd out/Debug; ninja quic_server
  3. Update "chromium_revision" var at DEPS to your chromium source code revision.
  4. Do ./sync.py <CHROMIUM_GIT_ROOT> All necessary files will be updated to new ones without patches applied.
  5. Temporarily commit here.
  6. Do ./sync.py <CHROMIUM_GIT_ROOT>--patch All the patches will be applied. Some patches will be rejected.
  7. If there is any patch collision, manually apply the rejected patches. Open the *.rej files and carefully apply the rejected hunks manually.
  8. Try build, and you'll find that you may need to add additional modifications to make build successful. There may be added or deleted source files. Update CMakeLists.txt accordingly.
  9. If the build is successful, make a patch by: git diff src/ > patch/basepatch.patch (Make sure you don't include custom/ directory sources to the patch)
  10. Add patch file to DEPS or update existing patch files. Amend previous commit.
  11. Commit DEPS, new patch, and source changes

libquic's People

Contributors

hodduc avatar kuss avatar parkayun avatar raeesiqbal avatar romedius avatar serialx avatar vkovtash avatar

Watchers

 avatar  avatar

Forkers

genghaolove

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.