Optimize ip address handling in flow classification engine

Description

The flow classification engine uses a decision tree to classify flows. At each node the protocol, src/dst port, or src/dst address of a flow is compared to some threshold.

This works well in case for protocols and ports because they are represented by single integer numbers. Comparison is cheap. In case of ip addresses comparison is expensive because a byte array representation of ip addresses is used for comparison. It would be much more performant to use an integer (for IPv4) or 2 longs (for IPv6) for representing ip addresses.

The ClassificationEngineBenchmark can be used to check classification performance.

Acceptance / Success Criteria

None

Lucidchart Diagrams

Activity

Show:

Stefan Wachter September 24, 2021 at 12:33 PM

Stefan Wachter September 24, 2021 at 12:26 PM

After a more efficient representation for IP addresses has been implemented a couple of more optimization opportunities have been exploited:

Fixed

Details

Assignee

Reporter

Sprint

Fix versions

Priority

PagerDuty

Created September 15, 2021 at 1:43 PM
Updated September 29, 2021 at 6:40 AM
Resolved September 29, 2021 at 6:40 AM