<html>
  <head>
    <meta content="text/html; charset=utf-8" http-equiv="Content-Type">
  </head>
  <body bgcolor="#FFFFFF" text="#000000">
    <p><br>
    </p>
    <p>Hum.. Amos, that store_miss would just make the object with that
      Vary header to not be cached, right?</p>
    <p>I've just tested it. But I think we need to choose what types of
      Vary are valid/usable or not.</p>
    <p>Reading the source code since yesterday, I made a patch that
      seems to fix my vary loop problem and will increase HITs a lot.</p>
    <p> It will only accept "accept-encoding" as a Vary statement and
      ignore all the other garbage servers are using as "Vary"...</p>
    <p>A simple change on http.cc, not client_side.cc</p>
    <p><br>
    </p>
    <p>Here it goes, use at your own risk:</p>
    <p><b>--- http.cc     2016-05-08 09:46:35.000000000 -0300</b><b><br>
      </b><b>+++ http.cc.new 2016-06-08 12:25:16.000000000 -0300</b><b><br>
      </b><b>@@ -595,6 +595,11 @@</b><b><br>
      </b><b>         xstrncpy(name, item, ilen + 1);</b><b><br>
      </b><b>         Tolower(name);</b><b><br>
      </b><b> </b><b><br>
      </b><b>+        if (strcmp(name, "accept-encoding") != 0)  {</b><b><br>
      </b><b>+           safe_free(name);</b><b><br>
      </b><b>+            continue;</b><b><br>
      </b><b>+       }</b><b><br>
      </b><b>+</b><b><br>
      </b><b>         if (strcmp(name, "*") == 0) {</b><b><br>
      </b><b>             /* Can not handle "Vary: *" withtout ETag
        support */</b><b><br>
      </b><b>             safe_free(name);</b></p>
    <p><br>
    </p>
    Save this text as http.patch on "src" directory and then: patch <
    http.patch<br>
    <br>
    <br>
    <pre class="moz-signature" cols="72">-- 
Best Regards,

Heiler Bemerguy
Network Manager - CINBESA
55 91 98151-4894/3184-1751</pre>
    <br>
    <br>
    <div class="moz-cite-prefix">Em 08/06/2016 10:34, Heiler Bemerguy
      escreveu:<br>
    </div>
    <blockquote
      cite="mid:1830582b-25a0-b222-81b7-6ba93a270727@cinbesa.com.br"
      type="cite">
      <div class="moz-text-flowed" style="font-family: -moz-fixed;
        font-size: 14px;" lang="x-unicode">
        <br>
        So.. with store_miss I could make squid store only some types of
        vary?
        <br>
        Wouldn't it "fix" the vary loop "bug" without messing with
        sources?
        <br>
        <br>
        <br>
        <div class="moz-txt-sig"><span class="moz-txt-tag">-- <br>
          </span>Best Regards,
          <br>
          <br>
          Heiler Bemerguy
          <br>
          Network Manager - CINBESA
          <br>
          55 91 98151-4894/3184-1751
          <br>
          <br>
          <br>
          Em 08/06/2016 03:31, Amos Jeffries escreveu:
          <br>
          <blockquote type="cite" style="color: #000000;">
            <br>
            <blockquote type="cite" style="color: #000000;">entry->mem_obj->vary_headers
              =
              <br>
'accept="text%2Fhtml,application%2Fxhtml+xml,application%2Fxml%3Bq%3D0.9,*%2F*%3Bq%3D0.8",
              <br>
              if-none-match, if-modified-since,
              <br>
accept-language="en-US,en%3Bq%3D0.8,pt-BR%3Bq%3D0.5,pt%3Bq%3D0.3",
              <br>
              accept-encoding="none", x-client-locale,
              <br>
user-agent="Mozilla%2F5.0%20(Windows%20NT%2010.0%3B%20WOW64%3B%20rv%3A46.0)%20Gecko%2F20100101%20Firefox%2F46.0",
              <br>
              x-device'
              <br>
              <br>
              That's why it always gives vary object loop
              <br>
              <br>
            </blockquote>
            <span class="moz-smiley-s2" title=":-("><span>:-(</span></span>
            Stupidity at its best with that sites designer.
            <br>
            <br>
            <br>
            Heres a little recipe that should raise the HIT ratio for
            that kind of
            <br>
            crap in 3.5:
            <br>
            <br>
              acl brokenVaryHeaders rep_header Vary -i \
            <br>
                 user-agent \
            <br>
                 if(-none)?-match \
            <br>
                 if-(un)?modified-since
            <br>
            <br>
              store_miss deny brokenVaryHeaders
            <br>
            <br>
            <br>
            Amos
            <br>
            <br>
          </blockquote>
          <br>
          _______________________________________________
          <br>
          squid-users mailing list
          <br>
          <a moz-do-not-send="true" class="moz-txt-link-abbreviated"
            href="mailto:squid-users@lists.squid-cache.org">squid-users@lists.squid-cache.org</a>
          <br>
          <a moz-do-not-send="true" class="moz-txt-link-freetext"
            href="http://lists.squid-cache.org/listinfo/squid-users">http://lists.squid-cache.org/listinfo/squid-users</a>
          <br>
        </div>
      </div>
    </blockquote>
    <br>
  </body>
</html>