tailf2kafka 0.1.6 → 0.1.7
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 +4 -4
- data/bin/tailf2kafka +11 -5
- data/lib/tailf2kafka/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA1:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 0a52bb6e6124032b75f8bd0ad29f6e3ea31e4d43
|
|
4
|
+
data.tar.gz: d0cf9ebc419b52d2a67c4de51e6ace18637c4212
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 4fc9d64f58bdb1bd22da9dc45c1f7a1c7c62cd846fc596542613b92e7baa1e1f1d95c718e4c79cce66cfd91d39fa27f8ee7ee8c3b28fe4ab5a0497951a6b1b9b
|
|
7
|
+
data.tar.gz: d4cfb41c0a41f0a905f4d68167a42aea8293d5f7a3757cf60a307d3e81a73ec85a49a8b6628a6ac9aecc76a410c3f7ae4fa9c0b2b5ca090be6938e19d2548315
|
data/bin/tailf2kafka
CHANGED
|
@@ -207,6 +207,7 @@ end
|
|
|
207
207
|
|
|
208
208
|
#Scan existing files that match watched prefixes and start failing them
|
|
209
209
|
@settings[:tailf][:files].each do |tailf_file|
|
|
210
|
+
tailf_file[:prefix] = File.expand_path(tailf_file[:prefix])
|
|
210
211
|
dir = File.dirname(tailf_file[:prefix])
|
|
211
212
|
if File.exists?(dir) and File.directory?(dir)
|
|
212
213
|
@dirs[dir] ||= []
|
|
@@ -236,11 +237,16 @@ def delete_old_tailed_files
|
|
|
236
237
|
if @settings[:tailf].has_key?(:post_delete_command)
|
|
237
238
|
@logger.info("Running post delete command => #{@settings[:tailf][:post_delete_command]}")
|
|
238
239
|
command = Mixlib::ShellOut.new(@settings[:tailf][:post_delete_command])
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
240
|
+
begin
|
|
241
|
+
command.run_command
|
|
242
|
+
if command.error?
|
|
243
|
+
@logger.error("Failed post delete command => #{@settings[:tailf][:post_delete_command]}")
|
|
244
|
+
@logger.info("STDOUT: #{command.stdout}")
|
|
245
|
+
@logger.info("STDERR: #{command.stderr}")
|
|
246
|
+
end
|
|
247
|
+
rescue => e
|
|
248
|
+
@logger.error("Failed post delete command => #{@settings[:tailf][:post_delete_command]}")
|
|
249
|
+
@logger.info(e.message)
|
|
244
250
|
end
|
|
245
251
|
end
|
|
246
252
|
end
|
data/lib/tailf2kafka/version.rb
CHANGED
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: tailf2kafka
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.1.
|
|
4
|
+
version: 0.1.7
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Alexander Piavlo
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2015-12-
|
|
11
|
+
date: 2015-12-29 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: poseidon
|