From c02c74b5feae66e87246111a7caec150f6292bf0 Mon Sep 17 00:00:00 2001 From: bui Date: Tue, 24 Oct 2023 17:24:16 +0200 Subject: [PATCH] shortcut for waap events --- pkg/acquisition/modules/waap/waap_runner.go | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/pkg/acquisition/modules/waap/waap_runner.go b/pkg/acquisition/modules/waap/waap_runner.go index 566eb4607..6bfca0e12 100644 --- a/pkg/acquisition/modules/waap/waap_runner.go +++ b/pkg/acquisition/modules/waap/waap_runner.go @@ -221,8 +221,15 @@ func (r *WaapRunner) Run(t *tomb.Tomb) error { continue } } - r.logger.Debugf("sending event %p to outChan", &evt) r.outChan <- evt + /*we generate a second event that will go directly to LAPI. + we don't want to risk losing all visibility on waap events if the user is missing a scenario*/ + waapOvlfw, err := WaapEventGeneration(evt) + if err != nil { + r.logger.Errorf("unable to generate waap event : %s", err) + } else { + r.outChan <- waapOvlfw + } } } }