This is an automated email from the ASF dual-hosted git repository.

eze pushed a commit to branch 9.2.x
in repository https://gitbox.apache.org/repos/asf/trafficserver.git


The following commit(s) were added to refs/heads/9.2.x by this push:
     new 2abc121214 Fix up logging for write-fail-5/collapsed-forwarding 
(#12050) (#12093)
2abc121214 is described below

commit 2abc121214dd876520e4c73cf27eb958b96a98f3
Author: Evan Zelkowitz <[email protected]>
AuthorDate: Mon Mar 10 16:36:59 2025 -0600

    Fix up logging for write-fail-5/collapsed-forwarding (#12050) (#12093)
    
    The logic here changed so that it no longer loops for all write retries 
before retrying
    to the read. So the logging no longer worked correctly
    
    (cherry picked from commit c82122e743258d26f05874330959f23d56d64fec)
---
 proxy/logging/LogAccess.cc | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/proxy/logging/LogAccess.cc b/proxy/logging/LogAccess.cc
index ff93479afc..e071c3985f 100644
--- a/proxy/logging/LogAccess.cc
+++ b/proxy/logging/LogAccess.cc
@@ -2970,8 +2970,8 @@ 
LogAccess::marshal_cache_collapsed_connection_success(char *buf)
     if (m_http_sm) {
       SquidLogCode code = m_http_sm->t_state.squid_codes.log_code;
 
-      // We increment open_write_tries beyond the max when we want to jump 
back to the read state for collapsing
-      if ((m_http_sm->get_cache_sm().get_open_write_tries() > 
(m_http_sm->t_state.txn_conf->max_cache_open_write_retries)) &&
+      // We attempted an open write, but ended up with some sort of HIT which 
means we must have gone back to the read state
+      if ((m_http_sm->get_cache_sm().get_open_write_tries() > (0)) &&
           ((code == SQUID_LOG_TCP_HIT) || (code == SQUID_LOG_TCP_MEM_HIT) || 
(code == SQUID_LOG_TCP_DISK_HIT) ||
            (code == SQUID_LOG_TCP_CF_HIT))) {
         // Attempted collapsed connection and got a hit, success

Reply via email to