Uploaded image for project: 'Java Driver'
  1. Java Driver
  2. JAVA-4969

make zstd compression level configurable

    • Type: Icon: Improvement Improvement
    • Resolution: Duplicate
    • Priority: Icon: Unknown Unknown
    • None
    • Affects Version/s: None
    • Component/s: None
    • None
    • Hide

      1. What would you like to communicate to the user about this feature?
      2. Would you like the user to see examples of the syntax and/or executable code and its output?
      3. Which versions of the driver/connector does this apply to?

      Show
      1. What would you like to communicate to the user about this feature? 2. Would you like the user to see examples of the syntax and/or executable code and its output? 3. Which versions of the driver/connector does this apply to?

      Allow configuring the zstd compression level in the same way it is configured for zlib, i.e.:

      MongoCompressor.createZstdCompressor().withProperty(MongoCompressor.LEVEL, 22);

      Note, this will currently only be used for compression of requests, not responses, because the connection string specification currently does not support a "zstdcompressionlevel" param, though it does support a "zlibcompressionlevel" param (https://www.mongodb.com/docs/manual/reference/connection-string/#mongodb-urioption-urioption.zlibCompressionLevel). I plan to file a separate SERVER issue for adding a "zstdcompressionlevel" param. Nonetheless, a configurable compression level for requests only is still better than nothing, and support for responses can be added once it's implemented by the server.

      My team's use case for this is as follows. We use the Java driver within a real-time personalization engine that must process events with super low latency. We would like to enable network compression to reduce cross-AZ network costs, but we want to enable it with compression level 1 or 2 to minimize latency.

            Assignee:
            ashni.mehta@mongodb.com Ashni Mehta (Inactive)
            Reporter:
            ian.springer@salesforce.com Ian Springer
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: