Skip to content
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

ackhandler: refactor ACK queueing logic #4225

Merged
merged 1 commit into from
Jan 4, 2024

Conversation

marten-seemann
Copy link
Member

@marten-seemann marten-seemann commented Jan 1, 2024

Once an ACK has been queued, there's no need to check futher conditions that would lead to queueing of an ACK.

In preparation for #3995.

Copy link

codecov bot commented Jan 1, 2024

Codecov Report

Attention: 3 lines in your changes are missing coverage. Please review.

Comparison is base (1fce81f) 83.97% compared to head (d85eef3) 84.53%.
Report is 4 commits behind head on master.

Files Patch % Lines
internal/ackhandler/received_packet_tracker.go 86.96% 2 Missing and 1 partial ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master    #4225      +/-   ##
==========================================
+ Coverage   83.97%   84.53%   +0.55%     
==========================================
  Files         149      149              
  Lines       15419    15654     +235     
==========================================
+ Hits        12948    13232     +284     
+ Misses       1972     1930      -42     
+ Partials      499      492       -7     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Once an ACK has been queued, there's no need to check futher conditions that
would lead to queueing of an ACK.
@@ -1269,7 +1269,6 @@ var _ = Describe("Connection", func() {
sph.EXPECT().ECNMode(true).AnyTimes()
runConn()
packer.EXPECT().AppendPacket(gomock.Any(), gomock.Any(), conn.version).Return(shortHeaderPacket{}, errNothingToPack).AnyTimes()
conn.receivedPacketHandler.ReceivedPacket(0x035e, protocol.ECNNon, protocol.Encryption1RTT, time.Now(), true)
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't understand what the purpose of this call was. And it now causes a race condition when accessing the ackAlarm field.

@marten-seemann marten-seemann merged commit 54d6f7d into master Jan 4, 2024
34 checks passed
@marten-seemann marten-seemann deleted the refactor-ack-queueing-logic branch January 4, 2024 02:40
nanokatze pushed a commit to nanokatze/quic-go that referenced this pull request Feb 1, 2024
Once an ACK has been queued, there's no need to check futher conditions that
would lead to queueing of an ACK.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant