logstash-input-jdbc 4.2.4 → 4.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +3 -0
- data/lib/logstash/plugin_mixins/jdbc.rb +2 -5
- data/logstash-input-jdbc.gemspec +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 23a5c2c6b744d78dbfe02dbeed5849c13682990c
|
4
|
+
data.tar.gz: ddcc30f19579b97f5fc3720ade23460eed65aa61
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 04f46de1c612553e4fb4be725168eda9d43c0ecd12800d03745aef7cda3ac244f2621e631bdd812fbad0b27b5fc1b408b95f3b6bcfdd3ee14f6c2ad60e2bc1e3
|
7
|
+
data.tar.gz: 888454f2452849be6445f5241db822ee95b3a82424160c5c5a8d127b5380b5fd5555352ed1958dec2615ea756834a48a3940618e094f2f702000e43e9bc4db0a
|
data/CHANGELOG.md
CHANGED
@@ -1,3 +1,6 @@
|
|
1
|
+
## 4.3.0
|
2
|
+
- [#147](https://github.com/logstash-plugins/logstash-input-jdbc/issues/147) Open and close connection for each query
|
3
|
+
|
1
4
|
## 4.2.4
|
2
5
|
- [#220](https://github.com/logstash-plugins/logstash-input-jdbc/issues/220) Log exception when database connection test fails
|
3
6
|
- Database reconnect: Mark old connection as dead even when clean disconnect fails.
|
@@ -210,15 +210,14 @@ module LogStash::PluginMixins::Jdbc
|
|
210
210
|
rescue => e
|
211
211
|
@logger.warn("Failed to close connection", :exception => e)
|
212
212
|
end
|
213
|
-
@database = nil
|
214
213
|
end
|
215
214
|
|
216
215
|
public
|
217
216
|
def execute_statement(statement, parameters)
|
218
217
|
success = false
|
218
|
+
open_jdbc_connection
|
219
219
|
begin
|
220
220
|
parameters = symbolized_params(parameters)
|
221
|
-
open_jdbc_connection if @database == nil
|
222
221
|
query = @database[statement, parameters]
|
223
222
|
sql_last_value = @use_column_value ? @sql_last_value : Time.now.utc
|
224
223
|
@tracking_column_warning_sent = false
|
@@ -246,12 +245,10 @@ module LogStash::PluginMixins::Jdbc
|
|
246
245
|
success = true
|
247
246
|
rescue Sequel::DatabaseConnectionError, Sequel::DatabaseError => e
|
248
247
|
@logger.warn("Exception when executing JDBC query", :exception => e)
|
249
|
-
@logger.warn("Attempt reconnection.")
|
250
|
-
close_jdbc_connection()
|
251
|
-
open_jdbc_connection()
|
252
248
|
else
|
253
249
|
@sql_last_value = sql_last_value
|
254
250
|
end
|
251
|
+
close_jdbc_connection
|
255
252
|
return success
|
256
253
|
end
|
257
254
|
|
data/logstash-input-jdbc.gemspec
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
Gem::Specification.new do |s|
|
2
2
|
s.name = 'logstash-input-jdbc'
|
3
|
-
s.version = '4.
|
3
|
+
s.version = '4.3.0'
|
4
4
|
s.licenses = ['Apache License (2.0)']
|
5
5
|
s.summary = "This example input streams a string at a definable interval."
|
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"
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: logstash-input-jdbc
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 4.
|
4
|
+
version: 4.3.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Elastic
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2017-
|
11
|
+
date: 2017-10-27 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
requirement: !ruby/object:Gem::Requirement
|