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:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: bbf914880612f207ca4535d38a6adbba00d75713
|
4
|
+
data.tar.gz: 1de673ca2eb056627156f0984df6a7a4ac41ec9f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
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
|
|
@@ -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
|
|
data/spec/fixtures/fix-input.log
CHANGED
@@ -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
|