lifepuzzlefun commented on code in PR #19561:
URL: https://github.com/apache/pulsar/pull/19561#discussion_r1113770434


##########
managed-ledger/src/main/java/org/apache/bookkeeper/mledger/ManagedLedgerFactoryConfig.java:
##########
@@ -92,8 +92,30 @@ public class ManagedLedgerFactoryConfig {
      */
     private String managedLedgerInfoCompressionType = 
MLDataFormats.CompressionType.NONE.name();
 
+    /**
+     * ManagedLedgerInfo compression threshold. If the origin metadata size 
below configuration.
+     * compression will not apply.
+     */
+    private int managedLedgerInfoCompressionSizeThresholdBytes = 0;
+
     /**
      * ManagedCursorInfo compression type. If the compression type is null or 
invalid, don't compress data.
      */
     private String managedCursorInfoCompressionType = 
MLDataFormats.CompressionType.NONE.name();
+
+    /**
+     * ManagedCursorInfo compression threshold. If the origin metadata size 
below configuration.
+     * compression will not apply.
+     */
+    private int managedCursorInfoCompressionSizeThresholdBytes = 0;
+
+    public MetadataCompressionConfig 
getCompressionConfigForManagedLedgerInfo() {

Review Comment:
   It is for create MetadataCompressionConfig which encapsulate the compression 
type and threshold。



##########
managed-ledger/src/main/java/org/apache/bookkeeper/mledger/ManagedLedgerFactoryConfig.java:
##########
@@ -92,8 +92,30 @@ public class ManagedLedgerFactoryConfig {
      */
     private String managedLedgerInfoCompressionType = 
MLDataFormats.CompressionType.NONE.name();
 
+    /**
+     * ManagedLedgerInfo compression threshold. If the origin metadata size 
below configuration.
+     * compression will not apply.
+     */
+    private int managedLedgerInfoCompressionSizeThresholdBytes = 0;
+
     /**
      * ManagedCursorInfo compression type. If the compression type is null or 
invalid, don't compress data.
      */
     private String managedCursorInfoCompressionType = 
MLDataFormats.CompressionType.NONE.name();
+
+    /**
+     * ManagedCursorInfo compression threshold. If the origin metadata size 
below configuration.
+     * compression will not apply.
+     */
+    private int managedCursorInfoCompressionSizeThresholdBytes = 0;
+
+    public MetadataCompressionConfig 
getCompressionConfigForManagedLedgerInfo() {

Review Comment:
   It is for create MetadataCompressionConfig which encapsulate the compression 
type and threshold.



-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to