code: private void loadBinlogChecksum() {
          ResultSetPacket rs = null;
          try {
              rs = query("select @@global.binlog_checksum");
              List<String> columnValues = rs.getFieldValues();
              if (columnValues != null && columnValues.size() >= 1 && columnValues.get(0).toUpperCase().equals("CRC32")) {
                  binlogChecksum = LogEvent.BINLOG_CHECKSUM_ALG_CRC32;
              } else {
                  binlogChecksum = LogEvent.BINLOG_CHECKSUM_ALG_OFF;
              }
          } catch (Throwable e) {
              logger.error("", e);
              binlogChecksum = LogEvent.BINLOG_CHECKSUM_ALG_OFF;
          }
      }
docs: 获取主库checksum信息
  
  <pre>
  mariadb区别于mysql会在binlog的第一个事件Rotate_Event里也会采用checksum逻辑,而mysql是在第二个binlog事件之后才感知是否需要处理checksum
  导致maraidb只要是开启checksum就会出现binlog文件名解析乱码
  fixed issue : https://github.com/alibaba/canal/issues/1081
  </pre>