Commit graph

90 commits

Author SHA1 Message Date
Marten Seemann
8ef69143ba implement a context for the stream
The context is cancelled when the write-side of the stream is closed.
2017-08-02 11:28:17 +07:00
Marten Seemann
f333a9b3e7
fix stream id checks in streamsMap
There were several bugs here:
- We must always return an error when the peer tries to open a stream
from the wrong side.
- We must never return an error when GetOrOpenStream is called for a
stream that was already closed. GetOrOpenStream is called when a frame
on a stream is received, so this happens when we receive retransmissions
of STREAM frames for a closed stream. We only used to do that check for
peer-initiated streams, not for streams we opened ourselves.
2017-06-22 22:09:21 +02:00
Lucas Clemente
c02f904479 Mock CPM everywhere using gomock 2017-06-09 12:38:07 +02:00
Lucas Clemente
050358bbc5 Mock CPM in streams map using gomock 2017-06-09 11:58:09 +02:00
Lucas Clemente
1311629830 Remove unnecessary error return value in newStream 2017-06-08 11:09:11 +02:00
Marten Seemann
ba16a80864
return an error when calling OpenStream after the session was closed
fixes #615
2017-05-14 13:56:38 +08:00
Marten Seemann
cd465ae0b5
move utils.Stream to quic.Stream 2017-02-22 23:03:09 +07:00
Marten Seemann
9c46ee6b24
unblock OpenStreamSync in streamsMap when an error is registered 2017-02-22 23:03:08 +07:00
Marten Seemann
d1562e5f87
add an OpenStreamSync method to the streamsMap 2017-02-22 23:03:08 +07:00
Marten Seemann
777f5f1ded
open implicitly opened streams in order 2017-02-22 23:03:08 +07:00
Marten Seemann
2fe9da6d27
unblock Accept in streamsMap when an error is registered 2017-02-22 23:03:06 +07:00
Marten Seemann
7c005ec7ad
implement a method for accepting streams in the streamsMap 2017-02-22 23:03:06 +07:00
Marten Seemann
92aa9c2b13
remove obsolete garbage collection from streamsMap 2017-02-22 23:03:06 +07:00
Marten Seemann
6d3e94bf21
open implicitly opened streams in streamsMap 2017-02-22 23:03:06 +07:00
Marten Seemann
f47142eaac
remove stream ID from OpenStream() method 2017-02-22 23:03:05 +07:00
Marten Seemann
a587af079d
improve the connection parameters manager for the client 2017-01-14 18:58:46 +07:00
Marten Seemann
16da08a440
add client functionality to the streamsMap 2017-01-14 18:54:15 +07:00
Marten Seemann
f72fbc57a9
send connection parameters in CHLO 2017-01-14 18:52:24 +07:00
Marten Seemann
3b4feedb2c
add support for server-side opened streams
fixes #296
2016-12-09 23:14:15 +07:00
Marten Seemann
10f8156951
remove unused function from streamsMap 2016-12-09 17:56:04 +07:00
Marten Seemann
c12508c3c9
use a mock ConnectionParametersManager in quic tests 2016-12-08 21:50:10 +07:00
Marten Seemann
ebc053dbe0
create interface for the ConnectionParametersManager 2016-12-08 18:39:14 +07:00
Marten Seemann
5af50c8fd0
correctly read MIDS and MSPC parameter
fixes #367
2016-12-08 16:15:31 +07:00
Lucas Clemente
e8ef0de5b4 exit framer loop early if no space is left in packet 2016-09-17 13:40:51 +02:00
Marten Seemann
aa16873794
prioritize crypto stream and header stream in streamsMap
fixes #151
2016-09-03 15:35:53 +07:00
Marten Seemann
416e3f9e2e garbage collect streams map
fixes #256
2016-08-24 16:26:30 +02:00
Marten Seemann
15352e9591 implement garbage collection of closed streams in streamsMap
ref #256
2016-08-24 16:26:30 +02:00
Marten Seemann
543ce21a5a prevent opening of new streams with very low StreamIDs
ref #256
2016-08-24 16:26:30 +02:00
Lucas Clemente
993dd2cd5f improve max dynamic streams calculation in streamsMap 2016-08-23 17:09:53 +02:00
Lucas Clemente
6d5a9b84e5 reject streams with even IDs opened by the client
fixes #267
2016-08-18 11:40:27 +02:00
Lucas Clemente
02c28c3a59 remove unneeded streamsMap.{Put,Get}Stream 2016-08-08 20:51:57 +02:00
Lucas Clemente
65663c3314 implement GetOrOpenStream in streamsMap 2016-08-08 20:51:57 +02:00
Lucas Clemente
c8bb818e4d fix some typos 2016-08-06 14:46:09 +02:00
Marten Seemann
8e7215aaeb only increase round-robin index when lambda returns true 2016-08-06 17:00:33 +07:00
Marten Seemann
b0d116ad5a implement a round-robin iterate function in StreamsMap
ref #207
2016-08-06 14:13:52 +07:00
Marten Seemann
64b0e03234 store StreamIDs of open Streams in a slice in the StreamsMap
ref #207
2016-08-05 23:38:43 +07:00
Marten Seemann
1f25ff5569 more explicit tests for counting the number of streams in StreamsMap 2016-08-05 20:33:35 +07:00
Marten Seemann
0cc42b8847 add an Iterate function to the StreamsMap 2016-08-05 19:27:06 +07:00
Marten Seemann
c3dcb649c7 return bool if stream exists in StreamsMap GetStream 2016-08-05 19:27:06 +07:00
Lucas Clemente
b3e76770de add a streamsMap class 2016-08-05 19:27:06 +07:00