logstash-output-mongodb 2.0.5 → 3.0.0

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: ca0ef44f6e3daf9d0fea3a5b931ceb98331441f1
4
- data.tar.gz: e22c4db8e2bc1c0d90ee4618002758f4ee6ac45f
3
+ metadata.gz: 4261d96d74df5b9ca9c612cc91f082bdb1f6e9f0
4
+ data.tar.gz: 3be2f47775fb15b98d6986c76426a5005939df7e
5
5
  SHA512:
6
- metadata.gz: dea5823a0f133b146cebbbfd8b2164f1b7ae0b1876c691083eb88eafc5ca177b27a5a6cb183de0e790d04b954a21de78a856c5b2ac8e25b85242f5b219e25f4e
7
- data.tar.gz: c69f381002a8ca592d882080b2d1b9c432bcaf2bf5b317c3696e8b082d37aa7cc2c6d8a818b0a3a14fd5e105d73185e8936c32ee2b60857a4c1e37c7c988580a
6
+ metadata.gz: 01c2bc8b14ee269e0d5f3beaa8b4b99ec16b9bf3c532a84818513356d12af9a7374b40d02c94e9e82aeac7420a7cf4939507b0ceae56c953acb1bb310de3ae41
7
+ data.tar.gz: 84a522503b241ecb0541de98a16d556e05d3b86a5b3a1d38a9b66e55ef3b4a5bf5105a2cec341ed4bbbbd78792e2971e42ac120862995e796d543eaf7c958245
data/CHANGELOG.md CHANGED
@@ -1,7 +1,14 @@
1
- # 2.0.5
1
+ ## 3.0.0
2
+ - Breaking: Updated plugin to use new Java Event APIs
3
+ - relax logstash-core-plugin-api constrains
4
+ - update .travis.yml
5
+
6
+ ## 2.0.5
2
7
  - Depend on logstash-core-plugin-api instead of logstash-core, removing the need to mass update plugins on major releases of logstash
3
- # 2.0.4
8
+
9
+ ## 2.0.4
4
10
  - New dependency requirements for logstash-core for the 5.0 release
11
+
5
12
  ## 2.0.3
6
13
  - Patch Timestamp and BigDecimal with to_bson method and register with BSON.
7
14
 
data/LICENSE CHANGED
@@ -1,4 +1,4 @@
1
- Copyright (c) 2012–2015 Elasticsearch <http://www.elastic.co>
1
+ Copyright (c) 2012–2016 Elasticsearch <http://www.elastic.co>
2
2
 
3
3
  Licensed under the Apache License, Version 2.0 (the "License");
4
4
  you may not use this file except in compliance with the License.
data/README.md CHANGED
@@ -1,7 +1,6 @@
1
1
  # Logstash Plugin
2
2
 
3
- [![Build
4
- Status](http://build-eu-00.elastic.co/view/LS%20Plugins/view/LS%20Outputs/job/logstash-plugin-output-mongodb-unit/badge/icon)](http://build-eu-00.elastic.co/view/LS%20Plugins/view/LS%20Outputs/job/logstash-plugin-output-mongodb-unit/)
3
+ [![Travis Build Status](https://travis-ci.org/logstash-plugins/logstash-output-mongodb.svg)](https://travis-ci.org/logstash-plugins/logstash-output-mongodb)
5
4
 
6
5
  This is a plugin for [Logstash](https://github.com/elastic/logstash).
7
6
 
@@ -56,7 +55,12 @@ gem "logstash-filter-awesome", :path => "/your/local/logstash-filter-awesome"
56
55
  ```
57
56
  - Install plugin
58
57
  ```sh
58
+ # Logstash 2.3 and higher
59
+ bin/logstash-plugin install --no-verify
60
+
61
+ # Prior to Logstash 2.3
59
62
  bin/plugin install --no-verify
63
+
60
64
  ```
61
65
  - Run Logstash with your plugin
62
66
  ```sh
@@ -74,7 +78,12 @@ gem build logstash-filter-awesome.gemspec
74
78
  ```
75
79
  - Install the plugin from the Logstash home
76
80
  ```sh
77
- bin/plugin install /your/local/plugin/logstash-filter-awesome.gem
81
+ # Logstash 2.3 and higher
82
+ bin/logstash-plugin install --no-verify
83
+
84
+ # Prior to Logstash 2.3
85
+ bin/plugin install --no-verify
86
+
78
87
  ```
79
88
  - Start Logstash and proceed to test the plugin
80
89
 
@@ -48,10 +48,10 @@ class LogStash::Outputs::Mongodb < LogStash::Outputs::Base
48
48
  document = {}.merge(event.to_hash)
49
49
  if !@isodate
50
50
  # not using timestamp.to_bson
51
- document["@timestamp"] = event["@timestamp"].to_json
51
+ document["@timestamp"] = event.timestamp.to_json
52
52
  end
53
53
  if @generateId
54
- document["_id"] = BSON::ObjectId.new(nil, event["@timestamp"])
54
+ document["_id"] = BSON::ObjectId.new(nil, event.timestamp)
55
55
  end
56
56
  @db[event.sprintf(@collection)].insert_one(document)
57
57
  rescue => e
@@ -1,10 +1,9 @@
1
1
  Gem::Specification.new do |s|
2
-
3
2
  s.name = 'logstash-output-mongodb'
4
- s.version = '2.0.5'
3
+ s.version = '3.0.0'
5
4
  s.licenses = ['Apache License (2.0)']
6
5
  s.summary = "Store events into MongoDB"
7
- s.description = "This gem is a logstash plugin required to be installed on top of the Logstash core pipeline using $LS_HOME/bin/plugin install gemname. This gem is not a stand-alone program"
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"
8
7
  s.authors = ["Elastic"]
9
8
  s.email = 'info@elastic.co'
10
9
  s.homepage = "http://www.elastic.co/guide/en/logstash/current/index.html"
@@ -20,7 +19,7 @@ Gem::Specification.new do |s|
20
19
  s.metadata = { "logstash_plugin" => "true", "logstash_group" => "output" }
21
20
 
22
21
  # Gem dependencies
23
- s.add_runtime_dependency "logstash-core-plugin-api", "~> 1.0"
22
+ s.add_runtime_dependency "logstash-core-plugin-api", ">= 1.60", "<= 2.99"
24
23
  s.add_runtime_dependency 'logstash-codec-plain'
25
24
  s.add_runtime_dependency 'mongo', '~> 2.0.6'
26
25
 
@@ -19,7 +19,7 @@ describe LogStash::Outputs::Mongodb do
19
19
 
20
20
  describe "#send" do
21
21
 
22
- subject { LogStash::Outputs::Mongodb.new(config) }
22
+ subject! { LogStash::Outputs::Mongodb.new(config) }
23
23
 
24
24
  let(:properties) { { "message" => "This is a message!",
25
25
  "uuid" => SecureRandom.uuid,
metadata CHANGED
@@ -1,29 +1,35 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: logstash-output-mongodb
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.0.5
4
+ version: 3.0.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Elastic
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-03-24 00:00:00.000000000 Z
11
+ date: 2017-01-16 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  requirement: !ruby/object:Gem::Requirement
15
15
  requirements:
16
- - - "~>"
16
+ - - ">="
17
+ - !ruby/object:Gem::Version
18
+ version: '1.60'
19
+ - - "<="
17
20
  - !ruby/object:Gem::Version
18
- version: '1.0'
21
+ version: '2.99'
19
22
  name: logstash-core-plugin-api
20
23
  prerelease: false
21
24
  type: :runtime
22
25
  version_requirements: !ruby/object:Gem::Requirement
23
26
  requirements:
24
- - - "~>"
27
+ - - ">="
28
+ - !ruby/object:Gem::Version
29
+ version: '1.60'
30
+ - - "<="
25
31
  - !ruby/object:Gem::Version
26
- version: '1.0'
32
+ version: '2.99'
27
33
  - !ruby/object:Gem::Dependency
28
34
  requirement: !ruby/object:Gem::Requirement
29
35
  requirements:
@@ -66,7 +72,7 @@ dependencies:
66
72
  - - ">="
67
73
  - !ruby/object:Gem::Version
68
74
  version: '0'
69
- description: This gem is a logstash plugin required to be installed on top of the Logstash core pipeline using $LS_HOME/bin/plugin install gemname. This gem is not a stand-alone program
75
+ 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
70
76
  email: info@elastic.co
71
77
  executables: []
72
78
  extensions: []