fluent-plugin-s3 0.2.5 → 0.2.6

Sign up to get free protection for your applications and to get access to all the features.
data/ChangeLog CHANGED
@@ -1,3 +1,7 @@
1
+ Release 0.2.6 - 2012/01/15
2
+
3
+ * Add use_ssl option
4
+
1
5
 
2
6
  Release 0.2.5 - 2012/12/06
3
7
 
@@ -18,7 +22,7 @@ Release 0.2.3 - 2012/11/19
18
22
 
19
23
  Release 0.2.2 - 2011/12/15
20
24
 
21
- * Add s3_endpoint optio
25
+ * Add s3_endpoint option
22
26
 
23
27
 
24
28
  Release 0.2.1 - 2011/10/24
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.2.5
1
+ 0.2.6
@@ -10,6 +10,8 @@ class S3Output < Fluent::TimeSlicedOutput
10
10
  require 'zlib'
11
11
  require 'time'
12
12
  require 'tempfile'
13
+
14
+ @use_ssl = true
13
15
  end
14
16
 
15
17
  config_param :path, :string, :default => ""
@@ -35,6 +37,17 @@ class S3Output < Fluent::TimeSlicedOutput
35
37
  @format_json = false
36
38
  end
37
39
 
40
+ if use_ssl = conf['use_ssl']
41
+ if use_ssl.empty?
42
+ @use_ssl = true
43
+ else
44
+ @use_ssl = Config.bool_value(use_ssl)
45
+ if @use_ssl.nil?
46
+ raise ConfigError, "'true' or 'false' is required for use_ssl option on s3 output"
47
+ end
48
+ end
49
+ end
50
+
38
51
  @timef = TimeFormatter.new(@time_format, @localtime)
39
52
  end
40
53
 
@@ -46,6 +59,8 @@ class S3Output < Fluent::TimeSlicedOutput
46
59
  options[:secret_access_key] = @aws_sec_key
47
60
  end
48
61
  options[:s3_endpoint] = @s3_endpoint if @s3_endpoint
62
+ options[:use_ssl] = @use_ssl
63
+
49
64
  @s3 = AWS::S3.new(options)
50
65
  @bucket = @s3.buckets[@s3_bucket]
51
66
  end
@@ -29,6 +29,7 @@ class S3OutputTest < Test::Unit::TestCase
29
29
  assert_equal 'test_sec_key', d.instance.aws_sec_key
30
30
  assert_equal 'test_bucket', d.instance.s3_bucket
31
31
  assert_equal 'log', d.instance.path
32
+ assert d.instance.instance_variable_get(:@use_ssl)
32
33
  end
33
34
 
34
35
  def test_format
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fluent-plugin-s3
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.5
4
+ version: 0.2.6
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2012-12-06 00:00:00.000000000 Z
12
+ date: 2013-01-14 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: fluentd
@@ -102,12 +102,18 @@ required_ruby_version: !ruby/object:Gem::Requirement
102
102
  - - ! '>='
103
103
  - !ruby/object:Gem::Version
104
104
  version: '0'
105
+ segments:
106
+ - 0
107
+ hash: -957364254525035982
105
108
  required_rubygems_version: !ruby/object:Gem::Requirement
106
109
  none: false
107
110
  requirements:
108
111
  - - ! '>='
109
112
  - !ruby/object:Gem::Version
110
113
  version: '0'
114
+ segments:
115
+ - 0
116
+ hash: -957364254525035982
111
117
  requirements: []
112
118
  rubyforge_project:
113
119
  rubygems_version: 1.8.23
@@ -116,4 +122,3 @@ specification_version: 3
116
122
  summary: Amazon S3 output plugin for Fluent event collector
117
123
  test_files:
118
124
  - test/out_s3.rb
119
- has_rdoc: false