maria-developers team mailing list archive
Mailing list archive
Re: [MariaDB/server] Compressed binary log (#247)
On 28 Oct 2016, at 06:18, 陈福荣 <vinchen13@xxxxxxxxx<mailto:vinchen13@xxxxxxxxx>> wrote:
Thanks for knielsen's nice replay. I would like to add some comments
>> (2) Senders would try to compress the event as requested. If the
>> compressed event is not any smaller then do not bother compressing it,
>> just send the original event.
> This is not in the current patch, but it could be added easily enough. It
> might not be needed though, the log_bin_compress_min_len kind of serves a
> similar purpose.
It just saves the receiver doing extra work and I’d expect that allowing that
would be trivial even if not implemented now. Just a thought anyway.
As knielsen said, the main purpose of log_bin_compress_min_len is avoiding the too small binlog events.
Can’t you just find out how big the compressed event is and if it’s not smaller than the original event send the original?
That way you know you get some extra compression which if you’re enabling this feature it’s what you want anyway.
Having to configure this minimum size means you need to set a specific value. Maybe you can use this
new setting with it’s current usage and use -1 to mean only write a compressed event if it’s actually smaller ?
SBR is also work in this feature.
That’s good to hear.