logstash-filter-varnishlog 0.1.7 → 0.1.8

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: b5bad4a2635a7e8d23f99156c2bb9d7dda5ab37b
4
- data.tar.gz: 3336e14b86616bf2ea870769eecc06851f26ed4f
3
+ metadata.gz: cb578535f6eb304f2cd9bd244f5a8f10c369f374
4
+ data.tar.gz: ff53e0ccf4eca5ec229d29cbee63e9fadee14dde
5
5
  SHA512:
6
- metadata.gz: 92d81615cc6f94db12c8dbf769922a0b9ab6f21c7d4f7d29169ea3395c6151caf6bbfdb921c819541050da4504bcb4675f7240c9eeb175fc319c5f490d1b0baf
7
- data.tar.gz: 685985a711e67a5d8e1686493731b26e964f939840110d168cebbc620c6609dc8e2b278d4ab2879df9530bbf95e67a86664254f3984c3a1cd3292e983651f694
6
+ metadata.gz: 7ca241ae26db16e8d929bf38f5163eefd6b3056df219ad2cc8e096b51e25a49f4163d71c029de4926cb28b47ca0ff896410a4b1f9af4dbc945e6fdd620d1b93f
7
+ data.tar.gz: b76284e146aa9ab422b77c49b6a08bad1bcd87640aab670dd7f44c208b337e927638b6e348faac5099f6b19ff19f3bec8390cec3fa1be8f62c3f203c7f007947
@@ -1,3 +1,6 @@
1
+ ## 0.1.8
2
+ - Fix Acct
3
+ - Add Fetch Error
1
4
  ## 0.1.7
2
5
  - Refactor regex parser
3
6
  ## 0.1.6
@@ -57,7 +57,7 @@ class LogStash::Filters::Varnishlog < LogStash::Filters::Base
57
57
  ##Acct
58
58
  account = items.grep(/(Be|Req)Acct/)
59
59
  account.each do |acct|
60
- if acct_match = /-\s+(Be|Req)Acct\s+(?<size_a>\d)\s+(?<size_b>\d)\s+(?<size_c>\d)\s+(?<size_d>\d)\s+(?<size_e>\d)\s+(?<size_f>\d)\s+/.match(acct)
60
+ if acct_match = /-\s+(Be|Req)Acct\s+(?<size_a>\d+)\s+(?<size_b>\d+)\s+(?<size_c>\d+)\s+(?<size_d>\d+)\s+(?<size_e>\d+)\s+(?<size_f>\d+)/.match(acct)
61
61
  event.set("bytes", acct_match['size_e'])
62
62
  end
63
63
  end
@@ -93,7 +93,10 @@ class LogStash::Filters::Varnishlog < LogStash::Filters::Base
93
93
  if protocol_match = /-+\s+(Be)?([rR]eq|[rR]esp)Protocol\s+(?<protocol>.*)/.match(items.grep(/(Be)?([rR]eq|[rR]esp)Protocol/)[0])
94
94
  event.set("protocol", protocol_match['protocol'])
95
95
  end
96
-
96
+ ## FetchError.
97
+ if error_match = /-+\s+FetchError\s+(?<error>.*)/.match(items.grep(/FetchError/)[0])
98
+ event.set("FetchError", error_match['error'])
99
+ end
97
100
  ## Match RespStatus
98
101
  status_match = items.grep(/(Be)?([rR]eq|[rR]esp)Status/)
99
102
  states = []
@@ -1,6 +1,6 @@
1
1
  Gem::Specification.new do |s|
2
2
  s.name = 'logstash-filter-varnishlog'
3
- s.version = '0.1.7'
3
+ s.version = '0.1.8'
4
4
  s.licenses = ['Apache License (2.0)']
5
5
  s.summary = 'A logstash plugin reading varnishlog output'
6
6
  s.description = 'logstash filter plugin reading varnishlog grouped by id'
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: logstash-filter-varnishlog
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.7
4
+ version: 0.1.8
5
5
  platform: ruby
6
6
  authors:
7
7
  - Christian Herweg
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2018-04-23 00:00:00.000000000 Z
11
+ date: 2018-04-27 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  requirement: !ruby/object:Gem::Requirement