logstash-filter-handsetdetection 4.1.1 → 4.1.2

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: 355ab24a36f7946ff03d4ea424fcb26c18026858
4
- data.tar.gz: a636e46a1f4f4dd9f565cc3b90015447e0c68134
3
+ metadata.gz: 8e2ff25a181df3eebd5b198b76c9ce6f07e28bb0
4
+ data.tar.gz: 2891e457eb34311f425f068f205460b23dbb639d
5
5
  SHA512:
6
- metadata.gz: 287afeb9918f7ff15664437662a5952dd698449ad4676f536cd17c4a4fd2e08a33faff2296d1f07085de3a533fa9e0205e6224d583474eb1bc4edafdba0b816f
7
- data.tar.gz: 4339bf074c5abe6fcfa0dec97d036373713b2b2314c1abfc7cb3c5784080fef92ddf1dbe88fb399924ccf334bd00f08df00f9acb423048bacc2da530bafae4ba
6
+ metadata.gz: 3d4210f7e6658050e27411b7f2734a9f954b330b584f56b383abe6850177ad9ea77dce11ec30a9bd4c1979594f6b6a6f35453f7e69305307ac69dc40ccf7d7a6
7
+ data.tar.gz: 08bd8d856ff0e62830adaba4da21652ed5a1bd3550b408b60c67e50b420b173cfd7ecce7e268b5f3546598f2cdd04faf4a68a2e0e2af1c82a6110cdf72db5799
data/README.md CHANGED
@@ -1,5 +1,5 @@
1
1
  [![Build Status](https://travis-ci.org/HandsetDetection/logstash-filter-handsetdetection.svg?branch=master)](https://travis-ci.org/HandsetDetection/logstash-filter-handsetdetection)
2
- [![Gem Version](https://badge.fury.io/rb/handset_detection.svg)](https://badge.fury.io/rb/handset_detection)
2
+ [![Gem Version](https://badge.fury.io/rb/logstash-filter-handsetdetection.svg)](https://badge.fury.io/rb/logstash-filter-handsetdetection)
3
3
  [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
4
4
 
5
5
  # Handset Detection for Logstash
@@ -52,10 +52,10 @@ Extract the User-Agent header from an Apache log with Grok, and then enrich the
52
52
 
53
53
  ```
54
54
  # Logstash 2.3 and higher
55
- bin/logstash-plugin install logstash-filter-handsetdetection-1.1.0.gem
55
+ bin/logstash-plugin install logstash-filter-handsetdetection-1.1.0
56
56
 
57
57
  # Prior to Logstash 2.3
58
- bin/plugin install logstash-filter-handsetdetection-1.1.0.gem
58
+ bin/plugin install logstash-filter-handsetdetection-1.1.0
59
59
  ```
60
60
 
61
61
  ## Building from source
@@ -83,8 +83,8 @@ class LogStash::Filters::HandsetDetection < LogStash::Filters::Base
83
83
  def filter(event)
84
84
  data = {}
85
85
  @match.each do |src, dest|
86
- if event.include? src
87
- data[dest] = event[src]
86
+ unless event.get(src).nil?
87
+ data[dest] = event.get src
88
88
  end
89
89
  end
90
90
  hd = @@pool.pop
@@ -93,16 +93,16 @@ class LogStash::Filters::HandsetDetection < LogStash::Filters::Base
93
93
  r = hd.get_reply
94
94
  @@pool << hd
95
95
  if r.key? 'class'
96
- event['handset_class'] = r['class']
96
+ event.set 'handset_class', r['class']
97
97
  end
98
98
  if r.key? 'hd_specs'
99
99
  if @filter.empty?
100
- event['handset_specs'] = r['hd_specs']
100
+ event.set 'handset_specs', r['hd_specs']
101
101
  else
102
- event['handset_specs'] = {}
102
+ event.set 'handset_specs', {}
103
103
  @filter.each do |f|
104
104
  if r['hd_specs'].key? f
105
- event['handset_specs'][f] = r['hd_specs'][f]
105
+ event.set "[handset_specs][#{f}]", r['hd_specs'][f]
106
106
  end
107
107
  end
108
108
  end
@@ -1,6 +1,6 @@
1
1
  Gem::Specification.new do |s|
2
2
  s.name = 'logstash-filter-handsetdetection'
3
- s.version = '4.1.1'
3
+ s.version = '4.1.2'
4
4
  s.licenses = ['MIT']
5
5
  s.summary = "Handset Detection filter plugin for Logstash"
6
6
  s.description = "This gem is a Logstash plugin required to be installed on top of the Logstash core pipeline using $LS_HOME/bin/logstash-plugin install gemname. This gem is not a stand-alone program"
@@ -18,8 +18,7 @@ Gem::Specification.new do |s|
18
18
  s.metadata = { "logstash_plugin" => "true", "logstash_group" => "filter" }
19
19
 
20
20
  # Gem dependencies
21
- s.add_runtime_dependency "logstash-core", ">= 2.0.0", "< 3.0.0"
22
- s.add_runtime_dependency "json", "~> 1.8"
21
+ s.add_runtime_dependency "logstash-core-plugin-api", ">= 1.60", "<= 2.99"
23
22
  s.add_runtime_dependency "handset_detection", "~> 4.1"
24
23
 
25
24
  #s.add_development_dependency 'logstash-devutils'
metadata CHANGED
@@ -1,100 +1,88 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: logstash-filter-handsetdetection
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.1.1
4
+ version: 4.1.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Handset Detection
8
- autorequire:
8
+ autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-10-26 00:00:00.000000000 Z
11
+ date: 2016-11-09 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
+ name: logstash-core-plugin-api
14
15
  requirement: !ruby/object:Gem::Requirement
15
16
  requirements:
16
- - - ">="
17
+ - - '>='
17
18
  - !ruby/object:Gem::Version
18
- version: 2.0.0
19
- - - "<"
19
+ version: '1.60'
20
+ - - <=
20
21
  - !ruby/object:Gem::Version
21
- version: 3.0.0
22
- name: logstash-core
23
- prerelease: false
22
+ version: '2.99'
24
23
  type: :runtime
25
- version_requirements: !ruby/object:Gem::Requirement
26
- requirements:
27
- - - ">="
28
- - !ruby/object:Gem::Version
29
- version: 2.0.0
30
- - - "<"
31
- - !ruby/object:Gem::Version
32
- version: 3.0.0
33
- - !ruby/object:Gem::Dependency
34
- requirement: !ruby/object:Gem::Requirement
35
- requirements:
36
- - - "~>"
37
- - !ruby/object:Gem::Version
38
- version: '1.8'
39
- name: json
40
24
  prerelease: false
41
- type: :runtime
42
25
  version_requirements: !ruby/object:Gem::Requirement
43
26
  requirements:
44
- - - "~>"
27
+ - - '>='
28
+ - !ruby/object:Gem::Version
29
+ version: '1.60'
30
+ - - <=
45
31
  - !ruby/object:Gem::Version
46
- version: '1.8'
32
+ version: '2.99'
47
33
  - !ruby/object:Gem::Dependency
34
+ name: handset_detection
48
35
  requirement: !ruby/object:Gem::Requirement
49
36
  requirements:
50
- - - "~>"
37
+ - - ~>
51
38
  - !ruby/object:Gem::Version
52
39
  version: '4.1'
53
- name: handset_detection
54
- prerelease: false
55
40
  type: :runtime
41
+ prerelease: false
56
42
  version_requirements: !ruby/object:Gem::Requirement
57
43
  requirements:
58
- - - "~>"
44
+ - - ~>
59
45
  - !ruby/object:Gem::Version
60
46
  version: '4.1'
61
- description: This gem is a Logstash plugin required to be installed on top of the Logstash core pipeline using $LS_HOME/bin/logstash-plugin install gemname. This gem is not a stand-alone program
47
+ description: This gem is a Logstash plugin required to be installed on top of the
48
+ Logstash core pipeline using $LS_HOME/bin/logstash-plugin install gemname. This
49
+ gem is not a stand-alone program
62
50
  email: hello@handsetdetection.com
63
51
  executables: []
64
52
  extensions: []
65
53
  extra_rdoc_files: []
66
54
  files:
67
- - Gemfile
68
- - LICENSE
69
- - README.md
70
55
  - lib/logstash/filters/handsetdetection.rb
71
- - logstash-filter-handsetdetection.gemspec
72
56
  - spec/filters/handsetdetection_spec.rb
73
57
  - spec/spec_helper.rb
58
+ - logstash-filter-handsetdetection.gemspec
59
+ - README.md
60
+ - Gemfile
61
+ - LICENSE
74
62
  homepage: http://www.handsetdetection.com/
75
63
  licenses:
76
64
  - MIT
77
65
  metadata:
78
66
  logstash_plugin: 'true'
79
67
  logstash_group: filter
80
- post_install_message:
68
+ post_install_message:
81
69
  rdoc_options: []
82
70
  require_paths:
83
71
  - lib
84
72
  required_ruby_version: !ruby/object:Gem::Requirement
85
73
  requirements:
86
- - - ">="
74
+ - - '>='
87
75
  - !ruby/object:Gem::Version
88
76
  version: '0'
89
77
  required_rubygems_version: !ruby/object:Gem::Requirement
90
78
  requirements:
91
- - - ">="
79
+ - - '>='
92
80
  - !ruby/object:Gem::Version
93
81
  version: '0'
94
82
  requirements: []
95
- rubyforge_project:
96
- rubygems_version: 2.4.8
97
- signing_key:
83
+ rubyforge_project:
84
+ rubygems_version: 2.0.14.1
85
+ signing_key:
98
86
  specification_version: 4
99
87
  summary: Handset Detection filter plugin for Logstash
100
88
  test_files: