Uploaded image for project: 'Solr'
  1. Solr
  2. SOLR-11752

add gzip to jetty

    XMLWordPrintableJSON

    Details

    • Type: New Feature
    • Status: Patch Available
    • Priority: Trivial
    • Resolution: Unresolved
    • Affects Version/s: 8.0
    • Fix Version/s: None
    • Component/s: Server
    • Labels:

      Description

      with a little bit of typing I am able to add gzip to my solr's jetty, which is a big help for WAN access and completely out-of-band to solr, and only happens if the client requests it so I think it is is a good default.

      I will just inline my code to this ticket:

      #server/etc/jetty-gzip.xml
      #just download it from here: http://grepcode.com/file/repo1.maven.org/maven2/org.eclipse.jetty/jetty-server/9.3.0.v20150612/etc/jetty-gzip.xml?av=f
      
      
      #server/modules/gzip.mod
      [depend]
      server
      
      [xml]
      etc/jetty-gzip.xml
      

      This is where you might want to add an option, but the result should look like this:

      #bin/solr
      else
        SOLR_JETTY_CONFIG+=("--module=http,gzip")
      fi
      

      I can now do this:

      curl -vvv --compressed localhost:8983/solr/ > /dev/null
      

      With:

      < Content-Encoding: gzip
      < Content-Length: 2890
      

      Without:

      < Content-Length: 13349
      

      A regular query:
      With:

      < Content-Encoding: gzip
      < Content-Length: 2876
      

      Without:

      < Content-Length: 17761
      

        Attachments

        1. SOLR-11752.patch
          6 kB
          Shawn Heisey
        2. SOLR-11752.patch
          6 kB
          Matthew Sporleder

          Issue Links

            Activity

              People

              • Assignee:
                Unassigned
                Reporter:
                msporleder Matthew Sporleder
              • Votes:
                0 Vote for this issue
                Watchers:
                11 Start watching this issue

                Dates

                • Created:
                  Updated: