fluent-plugin-mysql-appender 0.2.1 → 0.2.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: b9640d25120932e4ea0b2a254789a79572def373
|
4
|
+
data.tar.gz: a4cf4b25bd86021994199609a9b9a2c4ea8de020
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 39d7f9255c6998d8a78a1d5beaec7077a7ad67afa15822f3e0b3e55e61f21da0e921a2abb3b5d159f5ea4e84bb60fd77af47e803538b91fbd8449bad7ab05285
|
7
|
+
data.tar.gz: dc8ca2f3eb07fd2492b2eb791db7f9192d3c83f5047f622b308a80d2d20912453ecdf20cdc99c10ef1e23137fe2f69a86a87e903be59f287209b7f1997632204
|
@@ -54,9 +54,12 @@ module Fluent
|
|
54
54
|
|
55
55
|
def poll(config)
|
56
56
|
begin
|
57
|
+
masked_config = Hash[config.map {|k,v| (k == 'password') ? [k, v.to_s.gsub(/./, '*')] : [k,v]}]
|
58
|
+
$log.info "mysql_replicator_multi: polling start. :config=>#{masked_config}"
|
57
59
|
con = get_connection()
|
58
60
|
last_id = config['last_id']
|
59
61
|
loop do
|
62
|
+
$log.info "loop start in #{format_tag(config)}."
|
60
63
|
rows_count = 0
|
61
64
|
start_time = Time.now
|
62
65
|
rows, con = query(get_query(config, last_id), con)
|
@@ -80,6 +83,7 @@ module Fluent
|
|
80
83
|
end
|
81
84
|
con.close
|
82
85
|
elapsed_time = sprintf("%0.02f", Time.now - start_time)
|
86
|
+
$log.info "mysql_appender_multi: finished execution :tag=>#{tag} :rows_count=>#{rows_count} :last_id=>#{last_id} :elapsed_time=>#{elapsed_time} sec"
|
83
87
|
sleep @interval
|
84
88
|
end
|
85
89
|
rescue StandardError => e
|
@@ -123,7 +127,7 @@ module Fluent
|
|
123
127
|
:cache_rows => false
|
124
128
|
})
|
125
129
|
rescue Exception => e
|
126
|
-
$log.warn "
|
130
|
+
$log.warn "mysql_appender_multi: #{e}"
|
127
131
|
sleep @interval
|
128
132
|
retry
|
129
133
|
end
|