Github user sihuazhou commented on the issue:

    https://github.com/apache/flink/pull/5979
  
    @StephanEwen , I had a micro-benchmark, here is the result
    ```
    ---------> Batch VS Put <------------
    BATCH: end insert - duration:255
    PUT: end insert - duration:545
    
    ---------> MapState#Clear New VS Old <------------
    ---->
    NEW: end delete 50 records - duration:1077719
    OLD: end delete 50 records - duration:10949887
    ---->
    NEW: end delete 100 records - duration:809182
    OLD: end delete 100 records - duration:1617317
    ---->
    NEW: end delete 200 records - duration:1970156
    OLD: end delete 200 records - duration:2731749
    ---->
    NEW: end delete 400 records - duration:2492822
    OLD: end delete 400 records - duration:13894767
    ---->
    NEW: end delete 800 records - duration:5816919
    OLD: end delete 800 records - duration:13017591
    ```
    
    I tested two things:
    - To compare the performance between `WriteBatch()` VS `Put()`
    - To compare the performance of the `RocsDBMapState#Clear()`: new version 
vs old version
    
    In general, the more records there, the more lift we would get from the new 
version, here is my code for the test:  
https://github.com/sihuazhou/flink/commit/75504ad6fdb33755cccef43935e007bd5804ea9d


---

Reply via email to