1
0
mirror of https://github.com/facebookincubator/mvfst.git synced 2025-11-10 21:22:20 +03:00
Commit Graph

24 Commits

Author SHA1 Message Date
Matt Joras
30bff94e85 Introduce new connection rate limits.
Summary:
This introduces a rate limit to new connections created by a worker.

Right now it will simply send a VN, but eventually this will only issue a RETRY for unverified initials.

Reviewed By: udippant

Differential Revision: D21614905

fbshipit-source-id: 1832fbdad525c53fb1cb810aa9d7bae868c267d6
2020-05-18 16:40:43 -07:00
Yang Chi
081b63ffce Give QuicServerWorker an output buffer for GSO write with continuous memory
Summary: as title

Reviewed By: mjoras

Differential Revision: D20919833

fbshipit-source-id: 8cd9674d7bccf115cbdac5b976ba70e5dcb70e14
2020-04-28 22:14:20 -07:00
Udip Pant
bf71c1364a cleanup logging of routing info in QuicServerWorker
Summary: Extract out logging of all relavent routing info into a separate method

Reviewed By: sharmafb

Differential Revision: D21217339

fbshipit-source-id: 7982a4d9a3f3549a470e543e0a14aac1c6dec5f0
2020-04-24 11:49:55 -07:00
Dan Melnic
1cbdf1cd0a Add quic client and server GRO support
Summary: Add quic client and server GRO support

Reviewed By: mjoras

Differential Revision: D20876123

fbshipit-source-id: d32f8ea8b6ede3df56465746166907b1e1754c57
2020-04-20 13:11:56 -07:00
Luca Niccolini
5ca21a5278 rename infoCallback to statsCallback
Summary:
```
find ./quic | xargs -I{} sed -i "s/infoCallback/statsCallback/g" {}
find ./quic | xargs -I{} sed -i "s/InfoCallback/StatsCallback/g" {}
```

(Note: this ignores all push blocking failures!)

Reviewed By: mjoras

Differential Revision: D20860675

fbshipit-source-id: 4fe99a375b5983da51b6727d7f40788f89083ab3
2020-04-11 11:16:51 -07:00
Matt Joras
a230720c3c Avoid throwing an exception on decoding Connection IDs
Summary: This can happen more often than we'd like, and there's no reason to force throwing the exception when we can instead validate the length first.

Reviewed By: udippant

Differential Revision: D20770869

fbshipit-source-id: 93e2349b02d6d2067f345b5fa9decee800c84ea6
2020-04-05 19:47:44 -07:00
Yedidya Feldblum
ace2cc78a6 Unqualify uses of folly::AsyncUDPSocket::ReadCallback::OnDataAvailableParams
Summary: Unqualify nearly all uses of `folly::AsyncUDPSocket::ReadCallback::OnDataAvailableParams` since nearly all uses already have `OnDataAvailableParams` in scope.

Differential Revision: D20450063

fbshipit-source-id: c0fd49a7eace44a6edc8086762c44753224788dd
2020-03-16 02:57:30 -07:00
Dan Melnic
ba5ef797a5 Add UDP GRO support
Summary: Add UDP GRO support

Reviewed By: mjoras

Differential Revision: D20347326

fbshipit-source-id: be3c31f070c4f2c1ef84f9e2df60f49a5fcabd93
2020-03-13 10:12:22 -07:00
Yang Chi
9cea11f2bd QuicServerWorker rejects CID already present in CID Map
Summary:
The CID Algo can possibly generate a CID that's already in the map.
This diff adds a mechanism to reject such CID and try another one.
ServerStateMachine will loop encoding CIDs until either QuicServerWorker no
longer rejects, or encode fails

Reviewed By: udippant, vchynarov

Differential Revision: D20251043

fbshipit-source-id: a38e4e8b33007779a9710c32057d47f32f7d1774
2020-03-09 16:06:22 -07:00
Yang Chi
1b6810a828 Track bound QuicServerTransport with both raw pointers and weak_ptrs
Summary: For safety reason.

Reviewed By: mjoras

Differential Revision: D20041431

fbshipit-source-id: 6535afa25ab7ed80870912a6402ff21254dc9014
2020-03-04 17:07:29 -08:00
Luca Niccolini
39db4700c0 allow custom socket options
Summary: generic API for setting socket Options on both client and server

Reviewed By: yangchi

Differential Revision: D19763928

fbshipit-source-id: 7078eb8738aebc192bbace2498aaf9489526efff
2020-02-21 22:11:40 -08:00
Udip Pant
ba79292fa9 reset existing (takeover) socket when rebinding to different address
Reviewed By: afrind

Differential Revision: D18925452

fbshipit-source-id: dc431cbf899eb8e21a18d421a640e4f0649743cb
2019-12-20 17:29:28 -08:00
Matt Joras
592558ccb4 Use F14 for remaining unordered containers.
Summary: We've seen good results with F14, and while these don't show up much in profiles, there's not much reason to keep them as the STL variants.

Reviewed By: yangchi

Differential Revision: D18702489

fbshipit-source-id: 829f7e17107a8962cd7b4dad9b3b5e3df01318e6
2019-12-02 11:39:30 -08:00
Udip Pant
80b3a9f393 add more checks for internally forwarded data
Summary:
This adds checks for forwarded data on all the possible branches that lead to
forwarding of packets to another process

Reviewed By: mjoras

Differential Revision: D18416971

fbshipit-source-id: 22dc3fd63de615904a411f90164a138bf0ef56e0
2019-11-18 11:05:36 -08:00
Udip Pant
024bbbba29 retry few times if there's a conflict in takeover handler address
Reviewed By: sharma95

Differential Revision: D17403844

fbshipit-source-id: 3084335be30e2376a6888ba24e21aa63bb040e3e
2019-11-18 11:05:36 -08:00
Viktor Chynarov
27536bc1e4 Delete all transport connIds from server connIdMap on unbound [3/3]
Summary:
This diff is the one that introduces+passes the test of multiple server conn
ids routing to a single transport.

Currently, there is still only one time in non-test code that more than one
server connection id is added. This diff ensures when we call connectionUnbound
we remove all associated connection ids.

Reviewed By: udippant

Differential Revision: D17479563

fbshipit-source-id: 8d0ebbf26251f7bef44cdea53dfd4ff93ab465ae
2019-10-09 08:25:07 -07:00
Viktor Chynarov
2bd01800f3 Use set of transports instead of connIdMap for server shutdown [2/x]
Summary:
Currently, there is a 1:1 relationship between conn Id and transports. So for
all connections with a bound connection id, we iterate over all
connectionIdMap_ entries and delete the associate transport.

This won't work if connectionIdMap_ will map multiple conn ids to a single
transport.

Reviewed By: JunqiWang

Differential Revision: D17456965

fbshipit-source-id: 8923540abf205cfd10ad09d637e8c05790b4acf9
2019-09-27 07:57:44 -07:00
Viktor Chynarov
4ace4b5c21 Create helper for version negotiation in QuicServerWorker [2/x]
Summary: Simplify a bit of the server handling logic.

Reviewed By: sharma95

Differential Revision: D17194278

fbshipit-source-id: 356b3e2673d5befead571b2d0bae8418fb9629da
2019-09-25 14:26:55 -07:00
Udip Pant
e22d2df950 avoid possibility of loop during packet forwarding
Reviewed By: lnicco

Differential Revision: D17401129

fbshipit-source-id: db255f313311acd462e7bee1a33c45191ef8c3df
2019-09-19 17:14:53 -07:00
Konstantin Tsoy
41d4c6afbe Add run-time partial reliability setting override
Summary: Enable/disable partial reliability in transport settings of a QUIC server run-time.

Reviewed By: yangchi

Differential Revision: D16135672

fbshipit-source-id: 93c1175263ec03dc707764520ee73c1c2fd449c9
2019-07-08 22:12:33 -07:00
Aman Sharma
a38d9157fd Plumbing to override transport parameters
Summary:
I've added in some plumbing to enable us to override transport settings based on a specific `(datacenter, vip, server port, client prefix)` tuple.

  +-------------------------------------+
  |         HTTPRevProxyService         |
  +-------------------------------------+
                     |    Get the vip name, the datacenter,
                     |    and the server port. Create a lambda that
                     |    takes in the client IP address and applies
                     V    overrides to the transport settings.
  +-------------------------------------+
  |           ProxygenHQServer          |
  +-------------------------------------+
                     |
                     |    Pass on the lambda
                     |
                     V
  +-------------------------------------+
  |             QuicServer              |
  +-------------------------------------+
                     |
                     |    Pass on the lambda
                     |
                     V
  +-------------------------------------+
  |          QuicServerWorker           |
  +-------------------------------------+
                     |    Call the lambda (passing in the
                     |    client IP address) when we create
                     |    a QuicSocket, and set the transport
                     V    settings apprpriately
  +-------------------------------------+
  |         QuicServerTransport         |
  +-------------------------------------+

Reviewed By: udippant

Differential Revision: D15227915

fbshipit-source-id: 23c94aa558b381eae13f98ae06c6a97125c1a071
2019-06-24 14:31:23 -07:00
Bonnie Xu
2762cc1597 Setup stateless reset token
Summary: Replace hard coded stateless reset token with a token from the stateless reset token generator.

Reviewed By: yangchi

Differential Revision: D15481858

fbshipit-source-id: 30c96843c38c616600466b2fabb6defd5fcc5799
2019-06-13 08:44:53 -07:00
Yang Chi
c6d2fcc47d Fix typos in Quic code comments
Summary: as title

Reviewed By: sharma95

Differential Revision: D15262509

fbshipit-source-id: 519f17cb51752e8b8f8e7342f322533d551d6591
2019-05-08 13:24:01 -07:00
udippant
50d4939e9e Initial commit of mvfst 2019-04-22 23:42:46 -07:00