Skip to content
Snippets Groups Projects
Unverified Commit 4d8f9d9d authored by Mohamed S. Mahmoud's avatar Mohamed S. Mahmoud Committed by GitHub
Browse files

optimize filter sampling logic when filtering not enabled (#488)


* optimize filter sampling logic when filtering not enabled

Signed-off-by: default avatarMohamed Mahmoud <mmahmoud@redhat.com>

* Fix generating flows from additional map

It's possible that flow ids found in the additional map don't match any
id from the main flow map, for different reasons. This is especially
visible when filtering for drops, as in this case all flows are produced
only by the drop hook.

In these cases, we must be able to reconstruct the flows from the user
space. 3 things were particularly missing: end/start time and
eth_protocol. So, they are added back into the additional map.

Also, in user space, need to iterate separately over the two maps, to
not miss any orphan flow.

* Format, fix test, handle legacy mode

---------

Signed-off-by: default avatarMohamed Mahmoud <mmahmoud@redhat.com>
Co-authored-by: default avatarJoel Takvorian <jtakvori@redhat.com>
parent ecdb8407
No related branches found
No related tags found
No related merge requests found
Showing
with 182 additions and 51 deletions
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment