-
Notifications
You must be signed in to change notification settings - Fork 203
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
Latency Spin Bit #609
Latency Spin Bit #609
Conversation
Syncto 03 drafts
This is the result of the discussion of latency monitoring during the Paris interim meeting.
I like this approach, but would like to dig into how it breaks in corner cases. It seems to me to be quite related to "coloring" based approaches, see e.g. https://datatracker.ietf.org/doc/draft-ietf-ippm-alt-mark/ |
I also like this approach, and I think the one key corner case (out-of-order packet arrival) can be handled by description of how to smooth the base RTT signal. That would allow out of color packets to be seen as out-of-order indications rather than screwing up the RTT calculation. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this a per-path signal? I think that it is and that we need more text about that.
draft-ietf-quic-transport.md
Outdated
@@ -198,6 +198,8 @@ strengths of QUIC include: | |||
|
|||
* Version negotiation | |||
|
|||
* Support for monitoring |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would rather that we not include this section.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
in any case "support for monitoring" is much broader than what this is.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If you completely remove the question, then the bit description just appears out of nowhere. But then, yes, we could be specific about latency monitoring, rather than monitoring in general.
I would suggest to make it optional. There are some privacy issues associated with this allowing to assocate packets with a connection. Though UDP also associates packets, alternate transport layers can obfuscate routing. |
Instead of using a 'whole' bit, you can also have another packet type for protected packets. And if you define a well know patter that is used, you can even measure loss with it. |
Or just have the flag on short packets... |
Adding a reference to draft-ietf-ippm-alt-mark, as Brian suggested in his review.
I get Martin's point about per path signal, which it indeed is. But then, we don't really have an end-to-end vs path distinction yet. In the current transport draft, there seems to be just one path at a time. I think the distinction will only become apparent when we start specifying QUIC multipath. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There's no discussion of what to do when marked packets are lost. I think there needs to be to ensure the signal doesn't die during the connection.
draft-ietf-quic-transport.md
Outdated
@@ -294,6 +296,15 @@ QUIC version negotiation allows for multiple versions of the protocol to be | |||
deployed and used concurrently. Version negotiation is described in | |||
{{version-negotiation}}. | |||
|
|||
## Support for Latency Monitoring | |||
|
|||
Network administrators often find difficult to monitor the behavior |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: how about "Network administrators have difficulty monitoring ..."?
draft-ietf-quic-transport.md
Outdated
|
||
Network administrators often find difficult to monitor the behavior | ||
of encrypted protocols. Bandwidth can be monitored by observing the | ||
flow of encrypted packets, but the usal tools for monitoring |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
usal/usual
draft-ietf-quic-transport.md
Outdated
flow of encrypted packets, but the usal tools for monitoring | ||
latency require observing packet numbers and acknowledgements, which | ||
in QUIC are encrypted. | ||
QUIC packets include a clear text latency spin bit that enables |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: "QUIC packets enable monitoring of latency by including a clear text latency spin bit that is reflected between peers."
draft-ietf-quic-transport.md
Outdated
the network path. This bit is set as follow: | ||
|
||
* The connection responder sets the spin bit value to the value of the | ||
spin bit in the last packet received from the connection initiator. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What if two packets were received and the first had the spin bit set and the second did not? I would think the spin bit would still be set by the responder in that case?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Also, can you add clarifying text about what to do when exiting quiescence?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ian, there are two references to quiescence in the current draft. One about the Ping frame, "The default is to send a PING frame after 15 seconds of quiescence." The other about flow control, "it is generally considered best to not let the sender go into quiescence if avoidable." But the concept of quiescence is not well defined. Is it just "has not sent packet for a long time"?
What would you suggest to do?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What if two packets were received and the first had the spin bit set and the second did not? I would think the spin bit would still be set by the responder in that case?
If an old packet race ahead this could add noise to signal. I think it would be good to explain how this would work, or alternatively filter out the noise by only flipping when a new highest packet number is received. Noise could probably be used effectively if understood by analyser.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Scratch my comment, I think if we define this correctly, we don't need to talk about quiescence, it'll just naturally work out.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
One more comment: I think we need text on packet reordering here. Possibly this should be the largest packet received instead of the last?
Mirja, I hesitated between the "packet type" design and the "spin bit". I like having Red/Blue packet types, but I am concerned with the interaction with issue 311, "GREASE the packet type octet". If we do grease the packet type, we will need to leave the spin bit in clear text. This is much easier to do with a reserved bit than with the packet type. |
Yes, there is dependency on greasing. We could also just grease the long header because the short header has a bunch of flags that can anyway change all the time. I even thought about having only flags with the short header (and no type anymore) because that's nearly what we have already and that makes sense to me (and also looks slightly clearer to me) because all control packets are long headers. For me the point of the short header is basically a packet where you want to save some of the header bits and use it for payload instead and the flags simply define which part of the header bits you omit. |
There is also the option to grease the type but reserve a single ungreased value for monitoring packets. The benefit of a separate packet is both more payload for monitoring, and disassociation with other packets to better protect against timing analysis. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I like the 'spin bit' approach personally.
draft-ietf-quic-transport.md
Outdated
the network path. This bit is set as follow: | ||
|
||
* The connection responder sets the spin bit value to the value of the | ||
spin bit in the last packet received from the connection initiator. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Also, can you add clarifying text about what to do when exiting quiescence?
This is unaffected by my favourite form of greasing (xor with the last octet of the unencrypted frame). We have a choice as to whether or not this is greased, of course. |
Thinking about this some more, this bit will flip lots in ways that aren't immediately obvious. I think that we can safely not grease this. (We could also grease it, but that makes it a teensy bit less accessible to the devices who we intend to consume it, so not greasing is probably best.) Either way, that's not a question we need to resolve with the change as it stands. I still strongly think that we should avoid adding this to the list of transport features, and I think that you should address @ianswett's comments about dropping an entire flight (the answer being just "oh well" here). |
Oh, and I really think that this needs to be crisp about being per-path. I think that we need to explicitly sasy that we reset the signal when the IP or port at either end changes. |
Fixes suggested in Ian's review.
draft-ietf-quic-transport.md
Outdated
* The connection responder sets the spin bit value to the value of the | ||
spin bit in the last packet received from the connection initiator. | ||
|
||
* The connection initiator sets the spin bit value to the opposite |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm confused about why it's the opposite? My mental model is that the bit would be set to 1 on a packet, and then it would be bounced back and forth, so there would only be a single packet marked with the 1 spin bit at any given point in time.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ok, ekr explained to me out of band that I misunderstood how the spin bit worked. I think the design here is more robust to loss than what I was thinking of, so I'm happy with it.
However, an overview sentence explaining what it's doing (ie: mark the entire flight with the spin bit, etc) would have prevented my confusion.
Can we please move discussions to issues, and not have them on PRs? |
@janaiyengar I filed #631 for that purpose. |
And the loss-detection inference ability of this proposal can be discussed in #632. |
I've moved discussion to the issue (thanks for filing it, @britram). |
@janaiyengar To clarify, I think my comments were editorial, and so those still belong here, not in the issue? |
Ian -- I wasn't responding to your comments specifically, but I wanted to
move general discussion over to the issue.
…On Wed, Jun 14, 2017 at 9:09 PM, ianswett ***@***.***> wrote:
@janaiyengar <https://github.com/janaiyengar> To clarify, I think my
comments were editorial, and so those still belong here, not in the issue?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#609 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AKjg1AlptAKveShqQ2-_WMy689YPEfzFks5sED30gaJpZM4Nzrwr>
.
|
Great, thanks for clarifying. |
draft-ietf-quic-transport.md
Outdated
the network path. This bit is set as follow: | ||
|
||
* The connection responder sets the spin bit value to the value of the | ||
spin bit in the last packet received from the connection initiator. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The terminology elsewhere appears to be Client and Server, not Connecton Initiator and Connection Responder, although I prefer the latter since the protocol is not necessarily used in a client-server setup.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
"connection initiator" and "connection responder" are just pretentious ways of saying client and server. We happily use client-server protocols in non-client-server arrangements all the time.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Martin, initiator and responder are certainly equivalent to client and server when the application is HTTP. Not necessarily so is other applications, e.g. DNS or Web RTC. But as you seem to feel strongly about it, lets use Client and Server in the PR to make it consistent with the rest of the document.
Replacing initiator/responder by client and server for consistency with the rest of the document. Adding some minimal explanation of the expected behavior.
The phrase is a bit clumsy, but this solves the issues of flipping the bit when packets are received out of order.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks Christian, I think this LGTM.
draft-ietf-quic-transport.md
Outdated
|
||
* The client sets the spin bit value to the opposite | ||
of the last value received from the server, or to 0 | ||
of the value set in the packet received from the server with the | ||
largest sequence number, or to 0 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: I think these two lines may fit on one line?
Aside from being bitrotten, #1046 covers this now. |
Adding text to the transport spec to describe the "latency spin bit".