gejun123456 / redispluginIssues

8 stars 1 forks source link

"gzip" type #36

Open ostrolucky opened 3 years ago

ostrolucky commented 3 years ago

We store our redis values gzipped. Your plugin hence shows them as so:

image

Would it be possible to add "gzip" or "compressed" support into a dropdown? Currently, there is only "text", "bytes", "json" there. I would like to see the data in view decompressed.

For comparison, phpRedisAdmin project allows to define custom serialization/deserialization mechanisms via a config. It looks like so for us:

  'serialization' => [
        'BL::o::*' => $gzipStrategy = [
            'save' => fn ($data) => gzcompress(json_encode(json_decode($data))),
            'load' => fn ($data) => json_encode(json_decode(gzuncompress($data)), JSON_PRETTY_PRINT),
        ],
        'BL::po::*' => $gzipStrategy,
        'BL::marketing-feeds' => $gzipStrategy,
  ],
gejun123456 commented 3 years ago

thanks for reporting, will think about it.