Skip to content

Conversation

giorio94
Copy link
Member

Please review commit by commit, and refer to the individual commit messages for additional details.

@giorio94 giorio94 added release-note/minor This PR changes functionality that users may find relevant to operating Cilium. cilium-cli This PR contains changes related with cilium-cli labels Feb 19, 2025
@giorio94 giorio94 force-pushed the pr/giorio94/main/cli-perf-egress-gateway branch 2 times, most recently from 5c3997d to 4ef7d9b Compare February 19, 2025 16:49
@giorio94
Copy link
Member Author

/test

@giorio94 giorio94 force-pushed the pr/giorio94/main/cli-perf-egress-gateway branch 3 times, most recently from 75ff51c to 84c62ca Compare February 25, 2025 14:33
@giorio94 giorio94 requested a review from marseel February 25, 2025 14:33
@giorio94 giorio94 marked this pull request as ready for review February 25, 2025 14:34
@giorio94 giorio94 requested review from a team as code owners February 25, 2025 14:34
@giorio94 giorio94 requested review from tklauser, a user and Artyop February 25, 2025 14:34
@giorio94
Copy link
Member Author

/test

@giorio94 giorio94 enabled auto-merge February 26, 2025 09:25
Currently, the ConcurrentLogger implementation can panic when stopped
due to the messageCh channel being closed twice. Let's slightly rework
the implementation to ensure that the channel can only be closed once.

Example output of the crash:

^CCancellation request (context canceled) received, cancelling tests...
panic: close of closed channel

goroutine 1 [running]:
github.com/cilium/cilium/cilium-cli/connectivity/check.(*ConcurrentLogger).Stop(0xc000a74320)
       .../cilium/cilium-cli/connectivity/check/logger.go:56 +0x1e
github.com/cilium/cilium/cilium-cli/cli.newCmdConnectivityPerf.RunE.func2(0xc0008fb808, {0x453e450?, 0x4?, 0x453e310?})
       .../cilium/cilium-cli/cli/connectivity.go:106 +0x7f0
github.com/spf13/cobra.(*Command).execute(0xc0008fb808, {0xc000599e40, 0x1, 0x1})
       .../cilium/vendor/github.com/spf13/cobra/command.go:985 +0xaaa
github.com/spf13/cobra.(*Command).ExecuteC(0xc0002aac08)
       .../cilium/vendor/github.com/spf13/cobra/command.go:1117 +0x3ff
github.com/spf13/cobra.(*Command).Execute(0x624ecd0?)
       .../cilium/vendor/github.com/spf13/cobra/command.go:1041 +0x13
main.main()
       .../cilium/cilium-cli/cmd/cilium/main.go:22 +0xc5

Signed-off-by: Marco Iorio <marco.iorio@isovalent.com>
Hubble is not leverage by performance tests, and the corresponding flag
is not even registered. Hence, ensure that it is disabled, so that the
CLI does not attempt to contact hubble relay, emitting warnings in case
it fails.

Signed-off-by: Marco Iorio <marco.iorio@isovalent.com>
Currently, the perf tests panic when executed against a cluster with
at least one of the nodes not running Cilium. The reason is that the
common logic expects host-netns pods to be running on these nodes,
which are instead not deployed when running in perf mode. Let's fix
this by disabling the NodeWithoutCilium feature in this mode to turn
off the extra logic, given that it is not relevant in this context.

Signed-off-by: Marco Iorio <marco.iorio@isovalent.com>
The client does not expose any ports, hence it does not make sense to
configure it in the container definition.

Signed-off-by: Marco Iorio <marco.iorio@isovalent.com>
Configure the server to directly run in foreground, rather than sleeping
forever. Additionally, change the container port to actually reflect the
one used by netserver.

Signed-off-by: Marco Iorio <marco.iorio@isovalent.com>
Currently, performance tests are always run both with client and server
hosted on the same node, and with the client hosted on a different node.
Let's add two new flags to allow selectively enabling only one of the
two modes if desired. The default values preserve the current behavior.

Signed-off-by: Marco Iorio <marco.iorio@isovalent.com>
Currently, performance tests can be run for the pod-to-pod, host-to-host
and possibly mixed scenarios. Let's extend this to allow running mixed
configurations only (e.g., pod-to-host), without necessarily having to
run all the others.

Signed-off-by: Marco Iorio <marco.iorio@isovalent.com>
Extend the granularity of the node selectors configurable for the
performance test pods, allowing to separately specify the selector
associated with the client and server pods. This enables extra
flexibility for the cases in which placement really matters.

Signed-off-by: Marco Iorio <marco.iorio@isovalent.com>
Extend the performance tests to allow configuring the list of tolerations
assigned to the test pods, so that they can be scheduled on tainted nodes
as well (e.g., to ensure that no other pod gets scheduled there).

Signed-off-by: Marco Iorio <marco.iorio@isovalent.com>
Add the possibility of specifying a configurable delay before starting
the performance measurements, in case it is needed for state propagation.
For instance, this can be useful in the egress gateway context, to
give enough time for the datapath to be configured accordingly.

Signed-off-by: Marco Iorio <marco.iorio@isovalent.com>
@giorio94 giorio94 force-pushed the pr/giorio94/main/cli-perf-egress-gateway branch from 84c62ca to 5e4ebc2 Compare February 26, 2025 14:33
@giorio94
Copy link
Member Author

Rebased onto main to fix a conflict.

@giorio94
Copy link
Member Author

/test

@giorio94 giorio94 added this pull request to the merge queue Feb 26, 2025
@maintainer-s-little-helper maintainer-s-little-helper bot added the ready-to-merge This PR has passed all tests and received consensus from code owners to merge. label Feb 26, 2025
Merged via the queue into main with commit 7671222 Feb 26, 2025
210 checks passed
@giorio94 giorio94 deleted the pr/giorio94/main/cli-perf-egress-gateway branch February 26, 2025 19:26
@julianwiedmann julianwiedmann added the feature/egress-gateway Impacts the egress IP gateway feature. label Feb 27, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cilium-cli This PR contains changes related with cilium-cli feature/egress-gateway Impacts the egress IP gateway feature. ready-to-merge This PR has passed all tests and received consensus from code owners to merge. release-note/minor This PR changes functionality that users may find relevant to operating Cilium.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants