No description
Find a file
Andrew Zhao a3d2458c28 Update recieve function to read full data from socket at once
The existing code reads each message from the socket individually and calls
engine_process_conns after each message. This seems inefficient as it leads
to excess calls engine_process_conns.

This changes the code that reads from the socket to read all available messages
before calling engine_process_conns based off of the logic in the reference
implementation.

reference: https://github.com/litespeedtech/lsquic/blob/master/bin/test_common.c#L737
2021-02-10 00:13:36 -05:00
spec Add specs 2019-11-27 11:53:45 -06:00
src Update recieve function to read full data from socket at once 2021-02-10 00:13:36 -05:00
.editorconfig Initial commit 2019-11-12 20:15:43 -05:00
.gitignore Initial commit 2019-11-12 20:15:43 -05:00
.travis.yml Initial commit 2019-11-12 20:15:43 -05:00
LICENSE Add license 2019-11-15 21:22:36 -05:00
LICENSE.boringssl Add licenses and update README 2019-11-16 14:15:26 -05:00
LICENSE.chrome Add licenses and update README 2019-11-16 14:15:26 -05:00
LICENSE.lsquic Add licenses and update README 2019-11-16 14:15:26 -05:00
README.md Update org to iv-org 2020-10-04 13:30:32 +02:00
shard.yml Update to latest version of lsquic 2020-07-19 11:42:57 -04:00

lsquic

Crystal bindings to the excellent LSQUIC library.

Releases track lsquic's versioning starting with v2.18.1.

liblsquic.a is licensed under LICENSE.lsquic and LICENSE.chrome.

Lsquic uses boringssl, which is licensed under LICENSE.boringssl.

This library is available under the MIT license.

Installation

  1. Add the dependency to your shard.yml:

    dependencies:
      lsquic:
        github: iv-org/lsquic.cr
    
  2. Run shards install

Usage

require "lsquic"

client = QUIC::Client.new("www.youtube.com")
client.get("/") # => #<HTTP::Client::Response>

client.get("/", headers: HTTP::Headers{
  "cookie" => "Some value",
  # ...
}) # => #<HTTP::Client::Response>

Contributing

  1. Fork it (https://github.com/iv-org/lsquic.cr/fork)
  2. Create your feature branch (git checkout -b my-new-feature)
  3. Commit your changes (git commit -am 'Add some feature')
  4. Push to the branch (git push origin my-new-feature)
  5. Create a new Pull Request

Contributors