|
| 1 | +syntax = "proto3"; |
| 2 | + |
| 3 | +package envoy.extensions.compression.brotli.compressor.v3; |
| 4 | + |
| 5 | +import "google/protobuf/wrappers.proto"; |
| 6 | + |
| 7 | +import "udpa/annotations/status.proto"; |
| 8 | +import "validate/validate.proto"; |
| 9 | + |
| 10 | +option java_package = "io.envoyproxy.envoy.extensions.compression.brotli.compressor.v3"; |
| 11 | +option java_outer_classname = "BrotliProto"; |
| 12 | +option java_multiple_files = true; |
| 13 | +option (udpa.annotations.file_status).package_version_status = ACTIVE; |
| 14 | + |
| 15 | +// [#protodoc-title: Brotli Compressor] |
| 16 | +// [#extension: envoy.compression.brotli.compressor] |
| 17 | + |
| 18 | +// [#next-free-field: 7] |
| 19 | +message Brotli { |
| 20 | + enum EncoderMode { |
| 21 | + DEFAULT = 0; |
| 22 | + GENERIC = 1; |
| 23 | + TEXT = 2; |
| 24 | + FONT = 3; |
| 25 | + } |
| 26 | + |
| 27 | + // Value from 0 to 11 that controls the main compression speed-density lever. |
| 28 | + // The higher quality, the slower compression. The default value is 3. |
| 29 | + google.protobuf.UInt32Value quality = 1 [(validate.rules).uint32 = {lte: 11}]; |
| 30 | + |
| 31 | + // A value used to tune encoder for specific input. For more information about modes, |
| 32 | + // please refer to brotli manual: https://brotli.org/encode.html#aa6f |
| 33 | + // This field will be set to "DEFAULT" if not specified. |
| 34 | + EncoderMode encoder_mode = 2 [(validate.rules).enum = {defined_only: true}]; |
| 35 | + |
| 36 | + // Value from 10 to 24 that represents the base two logarithmic of the compressor's window size. |
| 37 | + // Larger window results in better compression at the expense of memory usage. The default is 18. |
| 38 | + // For more details about this parameter, please refer to brotli manual: |
| 39 | + // https://brotli.org/encode.html#a9a8 |
| 40 | + google.protobuf.UInt32Value window_bits = 3 [(validate.rules).uint32 = {lte: 24 gte: 10}]; |
| 41 | + |
| 42 | + // Value from 16 to 24 that represents the base two logarithmic of the compressor's input block |
| 43 | + // size. Larger input block results in better compression at the expense of memory usage. The |
| 44 | + // default is 24. For more details about this parameter, please refer to brotli manual: |
| 45 | + // https://brotli.org/encode.html#a9a8 |
| 46 | + google.protobuf.UInt32Value input_block_bits = 4 [(validate.rules).uint32 = {lte: 24 gte: 16}]; |
| 47 | + |
| 48 | + // Value for compressor's next output buffer. If not set, defaults to 4096. |
| 49 | + google.protobuf.UInt32Value chunk_size = 5 [(validate.rules).uint32 = {lte: 65536 gte: 4096}]; |
| 50 | + |
| 51 | + // If true, disables "literal context modeling" format feature. |
| 52 | + // This flag is a "decoding-speed vs compression ratio" trade-off. |
| 53 | + bool disable_literal_context_modeling = 6; |
| 54 | +} |
0 commit comments