logstash-filter-fix_protocol 0.1.2 → 0.1.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: 454431f7e36a07d087e15a1b6c2f18ea274557de
4
- data.tar.gz: 997359c4fab37712934c8252bf209039ee782b56
3
+ metadata.gz: bbf914880612f207ca4535d38a6adbba00d75713
4
+ data.tar.gz: 1de673ca2eb056627156f0984df6a7a4ac41ec9f
5
5
  SHA512:
6
- metadata.gz: 841e0c9cbbfc740092d1f52a7d9aab62c54a94370d447d9109a73e179eb8a57fdd4e04d396caec903bf2f8a2f4d52155a24785fca77417501b6ea2bc98ffed17
7
- data.tar.gz: 2b45940ea8d8100286a47f35317daca43a0d244a10e179835c2b3ecac71eb3855ee9bf2a1bc90f9d6820ff62ba185cb7120ce3f8b7d8c805ff6032da94f04c1d
6
+ metadata.gz: 79be0dc6622bd4bca51a524443b40414b07c581cca300c38104010c794a114175b1274af517e90bb024b6ac73fba1f725b6ad4ee719318ec241db651c1c2122b
7
+ data.tar.gz: b5ac803915f4886257ed3849f02887521ccbb5b39f5bd3123edebfcbcd96f96727481a3ad7abee64532fb35359a1ce00fcad4eba8a90ec5ab10dda3ac3c77002
@@ -41,7 +41,7 @@ module LogStash
41
41
 
42
42
  begin
43
43
  fix_message = FixMessage.new(message_string, data_dictionary, session_dictionary)
44
- rescue Java::Quickfix::InvalidMessage
44
+ rescue Java::Quickfix::InvalidMessage, ArgumentError
45
45
  event["tags"] = ["_fix_parse_failure"]
46
46
  end
47
47
 
@@ -4,7 +4,7 @@ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
4
4
 
5
5
  Gem::Specification.new do |s|
6
6
  s.name = "logstash-filter-fix_protocol"
7
- s.version = "0.1.2"
7
+ s.version = "0.1.3"
8
8
  s.authors = ["Connamara Systems"]
9
9
  s.email = ["info@connamara.com"]
10
10
 
@@ -36,7 +36,7 @@ describe LF::FixProtocol do
36
36
  end
37
37
  end
38
38
 
39
- context 'invalid message' do
39
+ context 'invalid message - Java::Quickfix::InvalidMessage' do
40
40
  config fix_4_configuration
41
41
 
42
42
  invalid_msg = "8=invalid_stuff"
@@ -47,6 +47,17 @@ describe LF::FixProtocol do
47
47
  end
48
48
  end
49
49
 
50
+ context 'invalid message - ArgumentError' do
51
+ config fix_4_configuration
52
+
53
+ invalid_msg = "8=FIX.4.09=8135=D34=349garbled=TW52=<TIME>56=ISLD11=ID21=340=154=155=INTC10=0"
54
+
55
+ sample(invalid_msg) do
56
+ insist { subject["tags"] } == ["_fix_parse_failure"]
57
+ insist { subject["message"] } == invalid_msg
58
+ end
59
+ end
60
+
50
61
  context 'an incoming execution report' do
51
62
  config fix_4_configuration
52
63
 
@@ -8,4 +8,5 @@
8
8
  2015-08-26 23:08:38,096 FIX.4.2:DUMMY_INC->ANOTHER_INC: 8=FIX.4.29=18435=F34=249=ANOTHER_INC50=DefaultSenderSubID52=20150826-23:08:38.09456=DUMMY_INC1=DefaultAccount11=clordid_of_cancel41=15101256954=155=ITER60=20250407-13:14:15167=FUT200=20151210=147
9
9
  2015-08-31 17:48:20,890 FIXT.1.1:DUMMY_INC->ANOTHER_INC: 8=FIXT.1.19=14035=W34=249=DUMMY_INC52=20150831-17:48:20.89056=ANOTHER_INC22=9948=.AQUA-W262=golden_path_test268=1269=3270=640754272=20150831273=17:48:20.88210=070
10
10
  2015-08-31 20:48:26,536 FIXT.1.1:DUMMY_INC->ANOTHER_INC: 8=FIXT.1.19=18935=W34=549=DUMMY_INC52=20150831-20:48:26.53556=ANOTHER_INC22=9948=ITRZ21262=req_A268=2269=0270=0.01005271=10272=20150831273=20:48:26.514269=1270=0.0101271=2272=20150831273=20:48:26.51410=123
11
-
11
+ 2015-08-31 20:48:26,536 FIXT.1.1:DUMMY_INC->ANOTHER_INC: 8=FIX.4.09=8135=D34=349garbled=TW52=<TIME>56=ISLD11=ID21=340=154=155=INTC10=0
12
+ 2015-08-31 20:48:26,536 FIXT.1.1:DUMMY_INC->ANOTHER_INC: 8=invalid_stuff
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: logstash-filter-fix_protocol
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.2
4
+ version: 0.1.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Connamara Systems