logstash-output-s3-leprechaun-fork 1.0.11 → 1.0.12
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/logstash/outputs/s3.rb +7 -9
- data/logstash-output-s3.gemspec +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: b4d4a035506bfea17656d618d97ae590e3b76254
|
4
|
+
data.tar.gz: 7e11cf877da0ceecbdf5a3383cf8d56a842f26d7
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: e815ccb950cb4c0c6d02af82817b351842a30bf2ed7f84674eb553df74566e2e45c014aa0e322ae316f2a233ca890d7147916809882184aa6b3574f57ea327e6
|
7
|
+
data.tar.gz: e444597e6a89cce44125be7546f319e4657ff10299277faa936828869b883cd0b58acdf3046e56a7ca39aab033e5e9fe66af22481c92e32d9da1bb03fb0f9d3a
|
data/lib/logstash/outputs/s3.rb
CHANGED
@@ -65,7 +65,7 @@ require "fileutils"
|
|
65
65
|
class LogStash::Outputs::S3 < LogStash::Outputs::Base
|
66
66
|
include LogStash::PluginMixins::AwsConfig
|
67
67
|
|
68
|
-
TEMPFILE_EXTENSION = "
|
68
|
+
TEMPFILE_EXTENSION = "log.gz"
|
69
69
|
S3_INVALID_CHARACTERS = /[\^`><]/
|
70
70
|
|
71
71
|
config_name "s3"
|
@@ -310,9 +310,9 @@ class LogStash::Outputs::S3 < LogStash::Outputs::Base
|
|
310
310
|
@logger.info("segregation 2: #{@segregations[segregation].inspect}")
|
311
311
|
|
312
312
|
new_file_name = get_temporary_filename(
|
313
|
-
|
314
|
-
|
315
|
-
|
313
|
+
directory,
|
314
|
+
file,
|
315
|
+
0
|
316
316
|
)
|
317
317
|
|
318
318
|
@segregations[segregation] = {
|
@@ -321,9 +321,7 @@ class LogStash::Outputs::S3 < LogStash::Outputs::Base
|
|
321
321
|
:file_base => file,
|
322
322
|
:current_page => 0,
|
323
323
|
:file_pointers => {
|
324
|
-
0 => Zlib::GzipWriter.open(
|
325
|
-
new_file_name,
|
326
|
-
'a')
|
324
|
+
0 => Zlib::GzipWriter.open(new_file_name)
|
327
325
|
}
|
328
326
|
}
|
329
327
|
|
@@ -339,7 +337,7 @@ class LogStash::Outputs::S3 < LogStash::Outputs::Base
|
|
339
337
|
|
340
338
|
def commit_locally(segregation, event, encoded_event)
|
341
339
|
seg = @segregations[segregation]
|
342
|
-
if seg[:file_pointers][seg[:current_page]].
|
340
|
+
if seg[:file_pointers][seg[:current_page]].write(encoded_event)
|
343
341
|
@logger.info("S3> commit_locally: write success (file: #{seg[:file_pointers][seg[:current_page]].path}")
|
344
342
|
else
|
345
343
|
# What do?
|
@@ -352,7 +350,7 @@ class LogStash::Outputs::S3 < LogStash::Outputs::Base
|
|
352
350
|
def should_commit?(segregation)
|
353
351
|
begin
|
354
352
|
seg = @segregations[segregation]
|
355
|
-
|
353
|
+
if @size_file > 0 and File.size(seg[:file_pointers][seg[:current_page]].path) > @size_file
|
356
354
|
@logger.info("S3> should_commit: upload because of size")
|
357
355
|
return true
|
358
356
|
end
|
data/logstash-output-s3.gemspec
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
Gem::Specification.new do |s|
|
2
2
|
|
3
3
|
s.name = 'logstash-output-s3-leprechaun-fork'
|
4
|
-
s.version = '1.0.
|
4
|
+
s.version = '1.0.12'
|
5
5
|
s.licenses = ['Apache License (2.0)']
|
6
6
|
s.summary = "This plugin was created for store the logstash's events into Amazon Simple Storage Service (Amazon S3)"
|
7
7
|
s.description = "This gem is a logstash plugin required to be installed on top of the Logstash core pipeline using $LS_HOME/bin/plugin install gemname. This gem is not a stand-alone program"
|