Class: Fluent::Plugin::S3Input::LZMA2Extractor
- Inherits:
-
Extractor
- Object
- Extractor
- Fluent::Plugin::S3Input::LZMA2Extractor
show all
- Defined in:
- lib/fluent/plugin/s3_extractor_lzma2.rb
Constant Summary
Constants inherited
from Extractor
Extractor::BYTES_TO_READ
Instance Attribute Summary
Attributes inherited from Extractor
#log
Instance Method Summary
collapse
Methods inherited from Extractor
#initialize
Instance Method Details
8
9
10
11
|
# File 'lib/fluent/plugin/s3_extractor_lzma2.rb', line 8
def configure(conf)
super
check_command('xz', 'LZMA')
end
|
#content_type ⇒ Object
17
18
19
|
# File 'lib/fluent/plugin/s3_extractor_lzma2.rb', line 17
def content_type
'application/x-xz'.freeze
end
|
#ext ⇒ Object
13
14
15
|
# File 'lib/fluent/plugin/s3_extractor_lzma2.rb', line 13
def ext
'xz'.freeze
end
|
21
22
23
24
25
26
27
28
29
|
# File 'lib/fluent/plugin/s3_extractor_lzma2.rb', line 21
def (io)
begin
extract_with_command("xz #{@command_parameter}", io, "xz-temp")
rescue SizeLimitError
raise
rescue
raise "Failed to extract #{path} with xz command."
end
end
|