Deprecate gfe2_reloadable_flag_quic_single_ack_in_packet2.

Please note, the chrome_value is false, and the chrome failed tests should be fixed by https://chromium-review.googlesource.com/c/chromium/src/+/3489151.

PiperOrigin-RevId: 430962355
diff --git a/quic/core/quic_connection.cc b/quic/core/quic_connection.cc
index 58daa88..b955d66 100644
--- a/quic/core/quic_connection.cc
+++ b/quic/core/quic_connection.cc
@@ -4523,14 +4523,10 @@
     // If there was a packet write error, write the smallest close possible.
     ScopedPacketFlusher flusher(this);
     // Always bundle an ACK with connection close for debugging purpose.
-    bool send_ack = error != QUIC_PACKET_WRITE_ERROR &&
-                    !uber_received_packet_manager_.IsAckFrameEmpty(
-                        QuicUtils::GetPacketNumberSpace(encryption_level_));
-    if (GetQuicReloadableFlag(quic_single_ack_in_packet2)) {
-      QUIC_RELOADABLE_FLAG_COUNT_N(quic_single_ack_in_packet2, 1, 2);
-      send_ack = !packet_creator_.has_ack() && send_ack;
-    }
-    if (send_ack) {
+    if (error != QUIC_PACKET_WRITE_ERROR &&
+        !uber_received_packet_manager_.IsAckFrameEmpty(
+            QuicUtils::GetPacketNumberSpace(encryption_level_)) &&
+        !packet_creator_.has_ack()) {
       SendAck();
     }
     QuicConnectionCloseFrame* frame;
@@ -4566,14 +4562,10 @@
     ScopedEncryptionLevelContext context(this, level);
     // Bundle an ACK of the corresponding packet number space for debugging
     // purpose.
-    bool send_ack = error != QUIC_PACKET_WRITE_ERROR &&
-                    !uber_received_packet_manager_.IsAckFrameEmpty(
-                        QuicUtils::GetPacketNumberSpace(encryption_level_));
-    if (GetQuicReloadableFlag(quic_single_ack_in_packet2)) {
-      QUIC_RELOADABLE_FLAG_COUNT_N(quic_single_ack_in_packet2, 2, 2);
-      send_ack = !packet_creator_.has_ack() && send_ack;
-    }
-    if (send_ack) {
+    if (error != QUIC_PACKET_WRITE_ERROR &&
+        !uber_received_packet_manager_.IsAckFrameEmpty(
+            QuicUtils::GetPacketNumberSpace(encryption_level_)) &&
+        !packet_creator_.has_ack()) {
       QuicFrames frames;
       frames.push_back(GetUpdatedAckFrame());
       packet_creator_.FlushAckFrame(frames);
diff --git a/quic/core/quic_connection_test.cc b/quic/core/quic_connection_test.cc
index d487eb0..f55138b 100644
--- a/quic/core/quic_connection_test.cc
+++ b/quic/core/quic_connection_test.cc
@@ -13476,11 +13476,7 @@
   ProcessFramesPacketWithAddresses(frames, kSelfAddress, kPeerAddress,
                                    ENCRYPTION_FORWARD_SECURE);
   ASSERT_FALSE(writer_->ack_frames().empty());
-  if (GetQuicReloadableFlag(quic_single_ack_in_packet2)) {
-    EXPECT_EQ(1u, writer_->ack_frames().size());
-  } else {
-    EXPECT_EQ(2u, writer_->ack_frames().size());
-  }
+  EXPECT_EQ(1u, writer_->ack_frames().size());
 }
 
 TEST_P(QuicConnectionTest,
@@ -13699,7 +13695,6 @@
     return;
   }
   SetQuicReloadableFlag(quic_can_send_ack_frequency, true);
-  SetQuicReloadableFlag(quic_single_ack_in_packet2, true);
   set_perspective(Perspective::IS_SERVER);
 
   QuicConfig config;
diff --git a/quic/core/quic_flags_list.h b/quic/core/quic_flags_list.h
index bfe20e2..43a7b23 100644
--- a/quic/core/quic_flags_list.h
+++ b/quic/core/quic_flags_list.h
@@ -63,8 +63,6 @@
 QUIC_FLAG(FLAGS_quic_reloadable_flag_quic_disable_server_blackhole_detection, false)
 // If true, discard INITIAL packet if the key has been dropped.
 QUIC_FLAG(FLAGS_quic_reloadable_flag_quic_discard_initial_packet_with_key_dropped, true)
-// If true, do not bundle 2nd ACK with connection close if there is an ACK queued.
-QUIC_FLAG(FLAGS_quic_reloadable_flag_quic_single_ack_in_packet2, false)
 // If true, do not call ProofSourceHandle::SelectCertificate if QUIC connection has disconnected.
 QUIC_FLAG(FLAGS_quic_reloadable_flag_quic_tls_no_select_cert_if_disconnected, true)
 // If true, do not count bytes sent/received on the alternative path into the bytes sent/received on the default path.
diff --git a/quic/core/quic_packet_creator.cc b/quic/core/quic_packet_creator.cc
index 885dc48..4065e7e 100644
--- a/quic/core/quic_packet_creator.cc
+++ b/quic/core/quic_packet_creator.cc
@@ -1526,9 +1526,7 @@
          "generator tries to send ACK frame.";
   // MaybeBundleAckOpportunistically could be called nestedly when sending a
   // control frame causing another control frame to be sent.
-  QUIC_BUG_IF(quic_bug_12398_18,
-              GetQuicReloadableFlag(quic_single_ack_in_packet2) &&
-                  !frames.empty() && has_ack())
+  QUIC_BUG_IF(quic_bug_12398_18, !frames.empty() && has_ack())
       << ENDPOINT << "Trying to flush " << quiche::PrintElements(frames)
       << " when there is ACK queued";
   for (const auto& frame : frames) {