Skip to content

New network transport library based on QUIC #477

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Draft
wants to merge 1 commit into
base: master
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 20 additions & 0 deletions packages/network-transport-quic/LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
Copyright (c) Laurent P. René de Cotret

Permission is hereby granted, free of charge, to any person obtaining
a copy of this software and associated documentation files (the
"Software"), to deal in the Software without restriction, including
without limitation the rights to use, copy, modify, merge, publish,
distribute, sublicense, and/or sell copies of the Software, and to
permit persons to whom the Software is furnished to do so, subject to
the following conditions:

The above copyright notice and this permission notice shall be included
in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
94 changes: 94 additions & 0 deletions packages/network-transport-quic/network-transport-quic.cabal
Original file line number Diff line number Diff line change
@@ -0,0 +1,94 @@
cabal-version: 3.0
Name: network-transport-quic
Version: 0.1.0
build-Type: Simple
License: BSD-3-Clause
License-file: LICENSE
Copyright: Laurent P. René de Cotret
Author: Laurent P. René de Cotret
maintainer: The Distributed Haskell team
Stability: experimental
Homepage: http://haskell-distributed.github.com
Bug-Reports: https://github.com/haskell-distributed/distributed-process/issues
Synopsis: Networking layer for Cloud Haskell based on QUIC
Description: Networking layer for Cloud Haskell based on QUIC
tested-with: GHC==8.10.7 GHC==9.0.2 GHC==9.2.8 GHC==9.4.5 GHC==9.6.4 GHC==9.8.2 GHC==9.10.1 GHC==9.12.1
Category: Network
extra-doc-files: ChangeLog
extra-source-files: test/credentials/*

source-repository head
Type: git
Location: https://github.com/haskell-distributed/distributed-process
SubDir: packages/network-transport-quic

common common
ghc-options:
-- warnings
-Wall
-Wcompat
-Widentities
-Wincomplete-uni-patterns
-Wincomplete-record-updates
-Wredundant-constraints
-fhide-source-paths
-Wpartial-fields
-Wunused-packages
-- The -threaded option is /required/ to use the quic library
-threaded

library
import: common
build-depends: attoparsec
, base >= 4.14 && < 5
, binary >= 0.8 && < 0.10
, bytestring >= 0.10 && < 0.13
, containers
, ip
, microlens-platform ^>=0.4
, network >= 3.1 && < 3.3
, network-transport >= 0.5 && < 0.6
, quic ^>=0.2
, stm >=2.4 && <2.6
, text >= 2.0 && <2.2
, tls
, tls-session-manager
exposed-modules: Network.Transport.QUIC
Network.Transport.QUIC.Internal
other-modules: Network.Transport.QUIC.Internal.Configuration
Network.Transport.QUIC.Internal.Client
Network.Transport.QUIC.Internal.EndpointState
Network.Transport.QUIC.Internal.Messaging
Network.Transport.QUIC.Internal.QUICAddr
Network.Transport.QUIC.Internal.QUICTransport
Network.Transport.QUIC.Internal.Server
Network.Transport.QUIC.Internal.TLS
Network.Transport.QUIC.Internal.TransportState
default-language: Haskell2010
default-extensions: ImportQualifiedPost
-- The -threaded option is /required/ to use the quic library
hs-source-dirs: src

test-suite network-transport-quic-tests
import: common
default-language: Haskell2010
default-extensions: ImportQualifiedPost
main-is: Main.hs
other-modules: Test.Network.Transport.QUIC
Test.Network.Transport.QUIC.Internal.Messaging
Test.Network.Transport.QUIC.Internal.QUICAddr
type: exitcode-stdio-1.0
hs-source-dirs: test
build-depends: base
, bytestring
, filepath
, hedgehog
, ip
, network
, network-transport
, network-transport-quic
, network-transport-tests
, tasty ^>=1.5
, tasty-hedgehog
, tasty-hunit
, text
16 changes: 16 additions & 0 deletions packages/network-transport-quic/src/Network/Transport/QUIC.hs
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
module Network.Transport.QUIC (
createTransport,
QUICAddr (..),

-- * Re-export to generate credentials
Credential,
credentialLoadX509,
) where

import Network.Transport.QUIC.Internal (
-- \* Re-export to generate credentials
Credential,
QUICAddr (..),
createTransport,
credentialLoadX509,
)
Loading
Loading