fluent-plugin-aggregate 1.0.5 → 1.0.6

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
  SHA256:
3
- metadata.gz: c02851919e0b692dc10b5381aa9930450a618f2b2362daca4ff92bae2daebcaa
4
- data.tar.gz: ff6434cb1a3424d7372da9f915ea4792f22c8a072c3563da405ba66f7b811dd9
3
+ metadata.gz: 7f1c9f42d9ebe69daf7ee5ddf227c408ff1163c6d893ad6b2647856c3749aed0
4
+ data.tar.gz: e826daa48e38022a94f149f711da5e814f7eb10b7797e3276f158fb9a63ab050
5
5
  SHA512:
6
- metadata.gz: c4e83ddfa0cc700645a83a64bf08a965b4137df8047da63404625daa9fa1d42a7d2f18a9f6ef6233434dbef175e0530b65da5ed6279d6d1b8e51a5a12d76568b
7
- data.tar.gz: 90169ab3b44ce01388a53893803b57b182c6240ea405971be46c3046b20e5076afb505134589793af4bbc93f42e5f0c16e1b1317113d86ddb849668f397e5bae
6
+ metadata.gz: ea597e2e46f2c4dabf878b9cf821fba7b245af07870450bc9596e2aed50f3729cf9f08df08a43afb28420f719818d0ad8c4e4cb3fdd134b23ff3046c7565f255
7
+ data.tar.gz: b1c93692beaeeda9c90987ecd7207f6e9a3554fdeaf3eedecdc46efbd636fc6fa8065d2b57031cc040079187da1e584f82c7ae7aaddbe851c322d80a2862d3a7
@@ -20,12 +20,14 @@ module Fluent
20
20
  config_param :emit_original_message, :bool, :default => true
21
21
  config_param :aggregate_event_tag, :string, :default => 'aggregate'
22
22
  config_param :aggregations, :array, :default => ['sum','min','max','mean','median','variance','standard_deviation'], value_type: :string
23
+ config_param :buckets, :array, :default => [], value_type: :integer
24
+ config_param :bucket_metrics, :array, :default => [], value_type: :string
23
25
  config_param :temporary_status_file_path, :string, :default => nil, :desc => 'File to store aggregate information when the agent down'
24
26
  config_param :load_temporarystatus_file_enabled, :bool, :default => true, :desc => 'Enable load saved data from file (if exist status file)'
25
27
  config_param :processing_mode, :string, :default => 'online', :desc => 'Processing mode (batch/online)'
26
28
  config_param :time_started_mode, :string, :default => 'first_event', :desc => 'Time started mode (first_event/last_event)'
27
29
 
28
- VALID_AGGREGATIONS = ['sum','min','max','mean','median','variance','standard_deviation']
30
+ VALID_AGGREGATIONS = ['sum','min','max','mean','median','variance','standard_deviation','bucket']
29
31
 
30
32
  def initialize
31
33
  super
@@ -62,6 +64,12 @@ module Fluent
62
64
  end
63
65
  }
64
66
 
67
+ if @aggregation_names.include?("bucket") && (buckets.empty? || bucket_metrics.empty?)
68
+ log.warn "bucket aggregation disabled, need buckets & bucket_metrics parameters to work, please review documentation."
69
+ else
70
+ log.info "bucket aggregation enabled, bucket count bucket_metrics with values <= buckets parameter"
71
+ end
72
+
65
73
  @aggregator = {}
66
74
  if load_temporarystatus_file_enabled && ! @temporary_status_file_path.nil? && File.exist?(@temporary_status_file_path) && file_status = File.open(@temporary_status_file_path,'r')
67
75
  begin
@@ -96,7 +104,10 @@ module Fluent
96
104
  aggregator_name: @aggregator_name,
97
105
  aggregation_names: @aggregation_names,
98
106
  group_field_names: @group_field_names,
99
- aggregate_field_names: @aggregate_field_names)
107
+ aggregate_field_names: @aggregate_field_names,
108
+ buckets: @buckets,
109
+ bucket_metrics: @bucket_metrics
110
+ )
100
111
  end
101
112
 
102
113
  def filter(tag, time, record)
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fluent-plugin-aggregate
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.5
4
+ version: 1.0.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - superguillen
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2020-05-20 00:00:00.000000000 Z
11
+ date: 2023-04-08 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: fluentd
@@ -36,14 +36,14 @@ dependencies:
36
36
  requirements:
37
37
  - - ">="
38
38
  - !ruby/object:Gem::Version
39
- version: 0.0.1
39
+ version: 0.0.7
40
40
  type: :runtime
41
41
  prerelease: false
42
42
  version_requirements: !ruby/object:Gem::Requirement
43
43
  requirements:
44
44
  - - ">="
45
45
  - !ruby/object:Gem::Version
46
- version: 0.0.1
46
+ version: 0.0.7
47
47
  - !ruby/object:Gem::Dependency
48
48
  name: rake
49
49
  requirement: !ruby/object:Gem::Requirement
@@ -101,7 +101,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
101
101
  - !ruby/object:Gem::Version
102
102
  version: '0'
103
103
  requirements: []
104
- rubygems_version: 3.0.3
104
+ rubygems_version: 3.0.3.1
105
105
  signing_key:
106
106
  specification_version: 4
107
107
  summary: Filter aggregtation plugin for Fluent