Sha256: 4496079a306aa4e2dc8917c3e18bd62e59f161a4c3bdd7f4643fb661decb02ec
Contents?: true
Size: 1.29 KB
Versions: 42
Compression:
Stored size: 1.29 KB
Contents
require 'flydata/command/sync' require 'flydata/source_mysql/command/mysql_command_base' # Command class must be in module Flydata::Command module Flydata module Command class Mysqlbinlog < Sync include MysqlCommandBase def generate_command(dbconf, args) skip_ssl = !!args.delete('--skip-ssl') dbconf.delete('tables') dbconf[:custom_option_end] = args.join(' ') dbconf[:command] = 'mysqlbinlog' # --default-character-set=utf8 is not supported dbconf[:no_default_option] = true # ssl is not supported for mysql5.6 or older mysqlbinlog command if skip_ssl dbconf.delete('ssl_ca') dbconf.delete('ssl_cipher') end dbconf.delete('database') if args.empty? puts <<EOT example: 1. Dump raw binlog flydata mysqlbinlog --raw --read-from-remote-server --result-file "binlog-" mysql-bin-changelog.xxxx 2. Dump decoded binlog data flydata mysqlbinlog -vv --base64-output=decode-row --hexdump --read-from-remote-server --start-position=4 --stop-position=yyyyy mysql-bin-changelog.xxxxx > mysql-bin-changelog.xxxxx NOTE: Add --skip-ssl to skip ssl options EOT return end FlydataCore::Mysql::CommandGenerator::generate_mysql_cmd(dbconf) end end end end
Version data entries
42 entries across 42 versions & 1 rubygems