This repository was archived by the owner on Dec 14, 2022. It is now read-only.
File tree Expand file tree Collapse file tree 3 files changed +14
-9
lines changed
Expand file tree Collapse file tree 3 files changed +14
-9
lines changed Original file line number Diff line number Diff line change 11{
22 "index_patterns" : [
3- " apigw-traffic-details-*"
3+ " apigw-traffic-details-*" ,
4+ " apigw-traffic-errors-*"
45 ],
56 "settings" : {
67 "number_of_shards" : 5 ,
Original file line number Diff line number Diff line change @@ -80,13 +80,17 @@ filter {
8080 clone {
8181 clones => ['errorEvent']
8282 }
83- # Fill the URI based on the given path to have it shown in Traffic-Monitor
84- mutate { add_field => { "[transactionElements][leg0][protocolInfo][http][uri]" => "%{[transactionSummary][path]}" } }
85- mutate { replace => { "[transactionElements][leg0][protocolInfo][http][status]" => "XXX" } }
86- mutate { replace => { "[transactionElements][leg0][protocolInfo][http][statusText]" => "ERROR" } }
87- mutate { replace => { "[transactionElements][leg0][protocolInfo][http][authSubjectId]" => "ID: %{[correlationId]}" } }
88- mutate { replace => { "[transactionSummary][serviceContext][vhost]" => "Logstash Error" } }
89- mutate { replace => { "[transactionSummary][serviceContext][method]" => "check the logs" } }
83+ if [type] == 'errorEvent' {
84+ # Fill the URI based on the given path to have it shown in Traffic-Monitor
85+ mutate { add_field => { "[correlationId]" => "-Error" } }
86+ mutate { add_field => { "[transactionElements][leg0][protocolInfo][http][uri]" => "%{[transactionSummary][path]}" } }
87+ mutate { replace => { "[transactionElements][leg0][protocolInfo][http][vhost]" => "Logstash Error" } }
88+ mutate { replace => { "[transactionElements][leg0][protocolInfo][http][method]" => "LOGSTASH" } }
89+ mutate { replace => { "[transactionElements][leg0][protocolInfo][http][status]" => "900" } }
90+ mutate { replace => { "[transactionElements][leg0][protocolInfo][http][statusText]" => "ERROR" } }
91+ mutate { replace => { "[transactionElements][leg0][protocolInfo][http][authSubjectId]" => "ID: %{[correlationId]}" } }
92+ mutate { replace => { "[transactionSummary][serviceContext][method]" => "check the logs" } }
93+ }
9094 }
9195 }
9296 #}
Original file line number Diff line number Diff line change 138138 },
139139 {
140140 "@timestamp" : " 2020-07-13T20:07:27.467Z" ,
141- "correlationId" : " OMG-UNKNOWN-API" ,
141+ "correlationId" : " OMG-UNKNOWN-API-Error " ,
142142 "logtype" : " openlog" ,
143143 "processInfo" : {
144144 "hostname" : " ip-172-31-62-146.ec2.internal" ,
You can’t perform that action at this time.
0 commit comments