In quicconnection::sendallpendingacks, update instead of set the ack alarm. protected by --gfe2_reloadable_flag_quic_update_ack_alarm_in_send_all_pending_acks. PiperOrigin-RevId: 312510742 Change-Id: Ieec2e3ffee600202202f6719bf566d9e7ce29685
diff --git a/quic/core/quic_connection.cc b/quic/core/quic_connection.cc index 3519bbc..1ef3cf7 100644 --- a/quic/core/quic_connection.cc +++ b/quic/core/quic_connection.cc
@@ -4043,7 +4043,13 @@ uber_received_packet_manager_.GetEarliestAckTimeout(); if (timeout.IsInitialized()) { // If there are ACKs pending, re-arm ack alarm. - ack_alarm_->Set(timeout); + if (update_ack_alarm_in_send_all_pending_acks_) { + QUIC_RELOADABLE_FLAG_COUNT( + quic_update_ack_alarm_in_send_all_pending_acks); + ack_alarm_->Update(timeout, kAlarmGranularity); + } else { + ack_alarm_->Set(timeout); + } } // Only try to bundle retransmittable data with ACK frame if default // encryption level is forward secure.
diff --git a/quic/core/quic_connection.h b/quic/core/quic_connection.h index 87c049b..c1e95f3 100644 --- a/quic/core/quic_connection.h +++ b/quic/core/quic_connection.h
@@ -1665,6 +1665,9 @@ const bool advance_ack_timeout_update_ = GetQuicReloadableFlag(quic_advance_ack_timeout_update); + + const bool update_ack_alarm_in_send_all_pending_acks_ = + GetQuicReloadableFlag(quic_update_ack_alarm_in_send_all_pending_acks); }; } // namespace quic