logstash-filter-uuid 3.0.2 → 3.0.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: f6155ec051b59acd27f1f5318081c88d48f7484e
4
- data.tar.gz: 98e3b8f17a720e6971f075b2473c7ff408608220
3
+ metadata.gz: 36f2c6233f852976d7c1314fb365aa32b62f394a
4
+ data.tar.gz: 3ecf812989d1912005a995d9fde24c6d0f073e19
5
5
  SHA512:
6
- metadata.gz: 9b67d184365484e4b92e86460313b1383a06417e75a8a0c48d7fb47eac931ac39625af08b19988dbdaf1442dd82b7ddd5fea452edc402bf817df67d3d976f3e8
7
- data.tar.gz: f20517dc3d1a420d690079a444319c35e830647e05bb88b652bbdff219ab982910961a65ff0b7a784cbd0819dce048f326da7e98ff836751a408eae560e6010f
6
+ metadata.gz: 4d0add02d984ba5e219b789026c30cd237fbe9078bca0484aa1015ade5cb77190bb0713eb012917947c350a8092c52600ff96b2319d1582a2ec5cce3e4dc68ef
7
+ data.tar.gz: ec4ef5b7dfdd8aa5a3e4b4c739ec5c1c9015afaa9f754571ee7dd5f7a74c0232fc93b57c2f87c097060290030979dc594e91de98092905a9cd054fa46da22d32
data/Gemfile CHANGED
@@ -1,4 +1,11 @@
1
1
  source 'https://rubygems.org'
2
2
 
3
- # Specify your gem's dependencies in logstash-mass_effect.gemspec
4
3
  gemspec
4
+
5
+ logstash_path = ENV["LOGSTASH_PATH"] || "../../logstash"
6
+ use_logstash_source = ENV["LOGSTASH_SOURCE"] && ENV["LOGSTASH_SOURCE"].to_s == "1"
7
+
8
+ if Dir.exist?(logstash_path) && use_logstash_source
9
+ gem 'logstash-core', :path => "#{logstash_path}/logstash-core"
10
+ gem 'logstash-core-plugin-api', :path => "#{logstash_path}/logstash-core-plugin-api"
11
+ end
@@ -0,0 +1,95 @@
1
+ :plugin: uuid
2
+ :type: filter
3
+
4
+ ///////////////////////////////////////////
5
+ START - GENERATED VARIABLES, DO NOT EDIT!
6
+ ///////////////////////////////////////////
7
+ :version: %VERSION%
8
+ :release_date: %RELEASE_DATE%
9
+ :changelog_url: %CHANGELOG_URL%
10
+ :include_path: ../../../../logstash/docs/include
11
+ ///////////////////////////////////////////
12
+ END - GENERATED VARIABLES, DO NOT EDIT!
13
+ ///////////////////////////////////////////
14
+
15
+ [id="plugins-{type}-{plugin}"]
16
+
17
+ === Uuid filter plugin
18
+
19
+ include::{include_path}/plugin_header.asciidoc[]
20
+
21
+ ==== Description
22
+
23
+ The uuid filter allows you to generate a
24
+ https://en.wikipedia.org/wiki/Universally_unique_identifier[UUID]
25
+ and add it as a field to each processed event.
26
+
27
+ This is useful if you need to generate a string that's unique for every
28
+ event, even if the same input is processed multiple times. If you want
29
+ to generate strings that are identical each time a event with a given
30
+ content is processed (i.e. a hash) you should use the
31
+ <<plugins-filters-fingerprint,fingerprint filter>> instead.
32
+
33
+ The generated UUIDs follow the version 4 definition in
34
+ https://tools.ietf.org/html/rfc4122[RFC 4122]) and will be
35
+ represented as a standard hexadecimal string format, e.g.
36
+ "e08806fe-02af-406c-bbde-8a5ae4475e57".
37
+
38
+ [id="plugins-{type}s-{plugin}-options"]
39
+ ==== Uuid Filter Configuration Options
40
+
41
+ This plugin supports the following configuration options plus the <<plugins-{type}s-{plugin}-common-options>> described later.
42
+
43
+ [cols="<,<,<",options="header",]
44
+ |=======================================================================
45
+ |Setting |Input type|Required
46
+ | <<plugins-{type}s-{plugin}-overwrite>> |<<boolean,boolean>>|No
47
+ | <<plugins-{type}s-{plugin}-target>> |<<string,string>>|Yes
48
+ |=======================================================================
49
+
50
+ Also see <<plugins-{type}s-{plugin}-common-options>> for a list of options supported by all
51
+ filter plugins.
52
+
53
+ &nbsp;
54
+
55
+ [id="plugins-{type}s-{plugin}-overwrite"]
56
+ ===== `overwrite`
57
+
58
+ * Value type is <<boolean,boolean>>
59
+ * Default value is `false`
60
+
61
+ If the value in the field currently (if any) should be overridden
62
+ by the generated UUID. Defaults to `false` (i.e. if the field is
63
+ present, with ANY value, it won't be overridden)
64
+
65
+ Example:
66
+ [source,ruby]
67
+ filter {
68
+ uuid {
69
+ target => "uuid"
70
+ overwrite => true
71
+ }
72
+ }
73
+
74
+ [id="plugins-{type}s-{plugin}-target"]
75
+ ===== `target`
76
+
77
+ * This is a required setting.
78
+ * Value type is <<string,string>>
79
+ * There is no default value for this setting.
80
+
81
+ Select the name of the field where the generated UUID should be
82
+ stored.
83
+
84
+ Example:
85
+ [source,ruby]
86
+ filter {
87
+ uuid {
88
+ target => "uuid"
89
+ }
90
+ }
91
+
92
+
93
+
94
+ [id="plugins-{type}s-{plugin}-common-options"]
95
+ include::{include_path}/{type}.asciidoc[]
@@ -3,21 +3,31 @@ require "logstash/filters/base"
3
3
  require "logstash/namespace"
4
4
  require "securerandom"
5
5
 
6
- # The uuid filter allows you to add a `UUID` field to messages.
7
- # This is useful to be able to control the `_id` messages are indexed into Elasticsearch
8
- # with, so that you can insert duplicate messages (i.e. the same message multiple times
9
- # without creating duplicates) - for log pipeline reliability
6
+ # The uuid filter allows you to generate a
7
+ # https://en.wikipedia.org/wiki/Universally_unique_identifier[UUID]
8
+ # and add it as a field to each processed event.
10
9
  #
10
+ # This is useful if you need to generate a string that's unique for every
11
+ # event, even if the same input is processed multiple times. If you want
12
+ # to generate strings that are identical each time a event with a given
13
+ # content is processed (i.e. a hash) you should use the
14
+ # <<plugins-filters-fingerprint,fingerprint filter>> instead.
15
+ #
16
+ # The generated UUIDs follow the version 4 definition in
17
+ # https://tools.ietf.org/html/rfc4122[RFC 4122]) and will be
18
+ # represented as a standard hexadecimal string format, e.g.
19
+ # "e08806fe-02af-406c-bbde-8a5ae4475e57".
11
20
  class LogStash::Filters::Uuid < LogStash::Filters::Base
12
21
  config_name "uuid"
13
22
 
14
- # Add a UUID to a field.
23
+ # Select the name of the field where the generated UUID should be
24
+ # stored.
15
25
  #
16
26
  # Example:
17
27
  # [source,ruby]
18
28
  # filter {
19
29
  # uuid {
20
- # target => "@uuid"
30
+ # target => "uuid"
21
31
  # }
22
32
  # }
23
33
  config :target, :validate => :string, :required => true
@@ -30,7 +40,7 @@ class LogStash::Filters::Uuid < LogStash::Filters::Base
30
40
  # [source,ruby]
31
41
  # filter {
32
42
  # uuid {
33
- # target => "@uuid"
43
+ # target => "uuid"
34
44
  # overwrite => true
35
45
  # }
36
46
  # }
@@ -1,7 +1,7 @@
1
1
  Gem::Specification.new do |s|
2
2
 
3
3
  s.name = 'logstash-filter-uuid'
4
- s.version = '3.0.2'
4
+ s.version = '3.0.3'
5
5
  s.licenses = ['Apache License (2.0)']
6
6
  s.summary = "The uuid filter allows you to add a UUID field to messages."
7
7
  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"
@@ -11,7 +11,7 @@ Gem::Specification.new do |s|
11
11
  s.require_paths = ["lib"]
12
12
 
13
13
  # Files
14
- s.files = Dir['lib/**/*','spec/**/*','vendor/**/*','*.gemspec','*.md','CONTRIBUTORS','Gemfile','LICENSE','NOTICE.TXT']
14
+ s.files = Dir["lib/**/*","spec/**/*","*.gemspec","*.md","CONTRIBUTORS","Gemfile","LICENSE","NOTICE.TXT", "vendor/jar-dependencies/**/*.jar", "vendor/jar-dependencies/**/*.rb", "VERSION", "docs/**/*"]
15
15
 
16
16
  # Tests
17
17
  s.test_files = s.files.grep(%r{^(test|spec|features)/})
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: logstash-filter-uuid
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.0.2
4
+ version: 3.0.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Elastic
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-07-14 00:00:00.000000000 Z
11
+ date: 2017-06-23 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  requirement: !ruby/object:Gem::Requirement
@@ -56,6 +56,7 @@ files:
56
56
  - LICENSE
57
57
  - NOTICE.TXT
58
58
  - README.md
59
+ - docs/index.asciidoc
59
60
  - lib/logstash/filters/uuid.rb
60
61
  - logstash-filter-uuid.gemspec
61
62
  - spec/filters/uuid_spec.rb
@@ -82,7 +83,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
82
83
  version: '0'
83
84
  requirements: []
84
85
  rubyforge_project:
85
- rubygems_version: 2.6.3
86
+ rubygems_version: 2.4.8
86
87
  signing_key:
87
88
  specification_version: 4
88
89
  summary: The uuid filter allows you to add a UUID field to messages.