Sha256: 6ddbf17d66fbbc24865ae46641341ae2190824af535488265377678ac0ab9f2d
Contents?: true
Size: 739 Bytes
Versions: 29
Compression:
Stored size: 739 Bytes
Contents
require 'flydata/parser/parser_provider' require 'flydata/source_mysql/plugin_support/ddl_query_handler' module Flydata module SourceMysql module PluginSupport class UnsupportedQueryHandler < TableDdlQueryHandler PATTERN = /.*/ # Catch all ddl def initialize(context) super end def pattern PATTERN end def process(record) query = record['normalized_query'] if acceptable_db?(record) && should_log?(query) $log.info({ type: :unsupported_query, query: query.to_s.strip}.to_s + " at \"#{binlog_pos(record)}\"") end end def should_log?(query) return false if query.to_s.empty? @context.tables.any?{|tbl| query.include?(tbl)} end end end end end
Version data entries
29 entries across 29 versions & 1 rubygems