fluent-plugin-azurestorage-gen2 0.2.2 → 0.2.3

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: c631dda137f661c5692855eb46d97696df14a5e0
4
- data.tar.gz: 174ace2e26b75f25b12a38d3c76726d3526f0866
3
+ metadata.gz: bfc46c8346705fa3762b1d47ae4080841f074f52
4
+ data.tar.gz: b5a6b4c58ce33385f6e4fb767c8f0b9598667731
5
5
  SHA512:
6
- metadata.gz: 5f135ffbe42f292666e66bca2b84a8c1f49d3ddf727460e376c95658b0382419a9008b110371d48314ccef6af0dc2f3cff5b0ae64730ae29222571dd20333163
7
- data.tar.gz: e81ba7ac31051ac5813ab4f3c845ee866f7dce3061c16a72fc5f3164e4b53c9c345c1135820762671162f092b195191a93ff6650a2562fc61cb12ea9a4b97ff2
6
+ metadata.gz: 689208930fe0c07cd97b09793bfdb9a1541d510b97783c1ea02a665bc8792db7d76ef0b88a272a4ab3de73d3cd56844fa3a8d0972c43fe061b301432122945b8
7
+ data.tar.gz: 721e081ee7d7c8ee06ad5814bf561578c1428627cb0d377a886526b556b027d55b1e1ce255ecd93a3afd18f8ed2e333448446d406812a55bf87dafd19698bc7d
data/README.md CHANGED
@@ -106,7 +106,7 @@ OAuth client secret that is used for OAuth based authentication. Required if OAu
106
106
 
107
107
  ### azure_oauth_refresh_interval
108
108
 
109
- OAuth2 access token refreshment interval in second. Only applies when MSI / OAuth authentication is used. (default value is 59 minutes)
109
+ OAuth2 access token refreshment interval in second. Only applies when MSI / OAuth authentication is used.
110
110
 
111
111
  ### azure_oauth_use_azure_cli (Preview)
112
112
 
@@ -126,7 +126,7 @@ You can skip the initial container listing (and container creation) operations a
126
126
 
127
127
  ### enable_retry
128
128
 
129
- If you set this option, operations can be retried in the buffer. Default value is false. (Currently only flush command is supported)
129
+ If you set this option, operations can be retried in the buffer. Default value is false. (Used for create/update/flush Blob operations)
130
130
 
131
131
  ### azure_object_key_format
132
132
 
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.2.2
1
+ 0.2.3
@@ -27,7 +27,7 @@ module Fluent::Plugin
27
27
  config_param :azure_oauth_secret, :string, :default => nil, :secret => true
28
28
  config_param :azure_oauth_tenant_id, :string, :default => nil
29
29
  config_param :azure_oauth_use_azure_cli, :bool, :default => false
30
- config_param :azure_oauth_refresh_interval, :integer, :default => 60 * 59 # 59 minutes, do not wait one hour
30
+ config_param :azure_oauth_refresh_interval, :integer, :default => 60 * 60
31
31
  config_param :azure_container, :string, :default => nil
32
32
  config_param :azure_object_key_format, :string, :default => "%{path}%{time_slice}_%{index}.%{file_extension}"
33
33
  config_param :file_extension, :string, :default => "log"
@@ -321,11 +321,11 @@ module Fluent::Plugin
321
321
  if response.success?
322
322
  log.debug "azurestorage_gen2: Blob '#{blob_path}' has been created, response code: #{response.code}"
323
323
  elsif response.timed_out?
324
- raise Fluent::UnrecoverableError, "Creating blob '#{blob_path}' request timed out."
324
+ raise_error "Creating blob '#{blob_path}' request timed out."
325
325
  elsif response.code == 409
326
326
  log.debug "azurestorage_gen2: Blob already exists: #{blob_path}"
327
327
  else
328
- raise Fluent::UnrecoverableError, "Creating blob '#{blob_path}' request failed - code: #{response.code}, body: #{response.body}, headers: #{response.headers}"
328
+ raise_error "Creating blob '#{blob_path}' request failed - code: #{response.code}, body: #{response.body}, headers: #{response.headers}"
329
329
  end
330
330
  end
331
331
  request.run
@@ -344,13 +344,13 @@ module Fluent::Plugin
344
344
  if response.success?
345
345
  log.debug "azurestorage_gen2: Blob '#{blob_path}' has been appended, response code: #{response.code}"
346
346
  elsif response.timed_out?
347
- raise Fluent::UnrecoverableError, "Appending blob #{blob_path}' request timed out."
347
+ raise_error "Appending blob #{blob_path}' request timed out."
348
348
  elsif response.code == 404
349
349
  raise AppendBlobResponseError.new("Blob '#{blob_path}' has not found. Error code: #{response.code}", 404)
350
350
  elsif response.code == 409
351
351
  raise AppendBlobResponseError.new("Blob '#{blob_path}' has conflict. Error code: #{response.code}", 409)
352
352
  else
353
- raise Fluent::UnrecoverableError, "Appending blob '#{blob_path}' request failed - code: #{response.code}, body: #{response.body}, headers: #{response.headers}"
353
+ raise_error "Appending blob '#{blob_path}' request failed - code: #{response.code}, body: #{response.body}, headers: #{response.headers}"
354
354
  end
355
355
  end
356
356
  request.run
@@ -369,7 +369,7 @@ module Fluent::Plugin
369
369
  if response.success?
370
370
  log.debug "azurestorage_gen2: Blob '#{blob_path}' flush was successful, response code: #{response.code}"
371
371
  elsif response.timed_out?
372
- raise Fluent::UnrecoverableError, "Bloub '#{blob_path}' flush request timed out."
372
+ raise_error "Bloub '#{blob_path}' flush request timed out."
373
373
  else
374
374
  raise_error "Blob flush request failed - code: #{response.code}, body: #{response.body}, headers: #{response.headers}"
375
375
  end
@@ -391,12 +391,12 @@ module Fluent::Plugin
391
391
  log.debug "azurestorage_gen2: Get blob properties for '#{blob_path}', response headers: #{response.headers}"
392
392
  content_length = response.headers['Content-Length'].to_i
393
393
  elsif response.timed_out?
394
- raise Fluent::UnrecoverableError, "Get blob properties '#{blob_path}' request timed out."
394
+ raise_error "Get blob properties '#{blob_path}' request timed out."
395
395
  elsif response.code == 404
396
396
  log.debug "azurestorage_gen2: Blob '#{blob_path}' does not exist. Creating it if needed..."
397
397
  content_length = 0
398
398
  else
399
- raise Fluent::UnrecoverableError, "Get blob properties '#{blob_path}' request failed - code: #{response.code}, body: #{response.body}, headers: #{response.headers}"
399
+ raise_error "Get blob properties '#{blob_path}' request failed - code: #{response.code}, body: #{response.body}, headers: #{response.headers}"
400
400
  end
401
401
  end
402
402
  request.run
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fluent-plugin-azurestorage-gen2
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.2
4
+ version: 0.2.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Oliver Szabo
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2020-01-07 00:00:00.000000000 Z
11
+ date: 2020-01-09 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: fluentd