You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@trafficserver.apache.org by "bryancall (via GitHub)" <gi...@apache.org> on 2024/07/18 20:03:06 UTC

[PR] Log the URL when getting a cache OpenReadHead warning [trafficserver]

bryancall opened a new pull request, #11573:
URL: https://github.com/apache/trafficserver/pull/11573

       Log the URL when getting a cache OpenReadHead warning when the content
       length header doesn't match the document/object length in cache


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscribe@trafficserver.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] Log the URL when getting a cache OpenReadHead warning [trafficserver]

Posted by "smalenfant (via GitHub)" <gi...@apache.org>.
smalenfant commented on PR #11573:
URL: https://github.com/apache/trafficserver/pull/11573#issuecomment-2243039164

   Should this be using `request.url_get()->string_get_ref(&url_string_length);` instead of `alternate.response_get()->url_get()->string_get_ref(&url_string_length);` ?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscribe@trafficserver.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] Log the URL when getting a cache OpenReadHead warning [trafficserver]

Posted by "ezelkow1 (via GitHub)" <gi...@apache.org>.
ezelkow1 commented on PR #11573:
URL: https://github.com/apache/trafficserver/pull/11573#issuecomment-2596299625

   @bryancall you still want this change since its been stale for a while?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscribe@trafficserver.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] Log the URL when getting a cache OpenReadHead warning [trafficserver]

Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] commented on PR #11573:
URL: https://github.com/apache/trafficserver/pull/11573#issuecomment-2425407638

   This pull request has been automatically marked as stale because it has not had recent activity. Marking it stale to flag it for further consideration by the community.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscribe@trafficserver.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] Log the URL when getting a cache OpenReadHead warning [trafficserver]

Posted by "smalenfant (via GitHub)" <gi...@apache.org>.
smalenfant commented on PR #11573:
URL: https://github.com/apache/trafficserver/pull/11573#issuecomment-2241203248

   I added that code to 9.2.4 but it crashed.
   Is there a way to test this code without having to put in production?
   
   I might have wrongly applied the patch:
   
   ```
   $ git diff HEAD~1
   diff --git a/iocore/cache/CacheRead.cc b/iocore/cache/CacheRead.cc
   index 95e8b1838..b858a0d98 100644
   --- a/iocore/cache/CacheRead.cc
   +++ b/iocore/cache/CacheRead.cc
   @@ -1182,8 +1182,11 @@ CacheVC::openReadStartHead(int event, Event *e)
          if (field) {
            uint64_t cl = static_cast<uint64_t>(field->value_get_int64());
            if (cl != doc_len) {
   -          Warning("OpenReadHead failed for cachekey %X : alternate content length doesn't match doc_len %" PRId64 " != %" PRId64,
   -                  key.slice32(0), cl, doc_len);
   +          int url_string_length = 0;
   +          const char *url_string = alternate.response_get()->url_get()->string_get_ref(&url_string_length);
   +          Warning("OpenReadHead failed for cachekey %X : alternate content length doesn't match doc_len %" PRId64 " != %" PRId64
   +                  " url: %.*s",
   +                  key.slice32(0), cl, doc_len, url_string_length, url_string);
              CACHE_INCREMENT_DYN_STAT(cache_read_invalid_stat);
              err = ECACHE_BAD_META_DATA;
              goto Ldone;
   ```


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscribe@trafficserver.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] Log the URL when getting a cache OpenReadHead warning [trafficserver]

Posted by "github-actions[bot] (via GitHub)" <gi...@apache.org>.
github-actions[bot] closed pull request #11573: Log the URL when getting a cache OpenReadHead warning
URL: https://github.com/apache/trafficserver/pull/11573


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: github-unsubscribe@trafficserver.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org