-
Notifications
You must be signed in to change notification settings - Fork 3.4k
hubble: from and to cluster filters #33325
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
hubble: from and to cluster filters #33325
Conversation
c606e39
to
5ec0a29
Compare
5ec0a29
to
ec0d6b5
Compare
ec0d6b5
to
99fdcbe
Compare
This pull request has been automatically marked as stale because it |
This pull request has not seen any activity since it was marked stale. |
@kaworu should we keep this open? |
99fdcbe
to
f6a6755
Compare
Is this ready for review again? Otherwise I'd appreciate if we put it in draft, since every push creates an notification in all reviewers inbox. There are a couple unresolved comments still. We should resolve them (either by fixing them or declaring that we won't fix them). |
Will wait on #35415. |
Reword the IP.source_xlated documentation comment on the way. Signed-off-by: Alexandre Perrin <alex@isovalent.com>
Signed-off-by: Alexandre Perrin <alex@isovalent.com>
Signed-off-by: Alexandre Perrin <alex@isovalent.com>
Before this patch, the Hubble CLI `--cluster` flag was implemented as `--node-name cluster/`, i.e. filtering flows emitted by all the nodes in the target cluster. This behavior was inconsistent with the `--namespace foo` flag, which shows not only flows ingressing/egressing the `foo` namespace, but also flows observed from other namespaces either going to or coming from the `foo` namespace. It also made the `--cluster` and `--node-name` flags incompatible. 163c874 ("hubble: add cluster name to a flow's endpoints") added cluster name info at the flow endpoint level, and the previous commits added corresponding Hubble filters (`--from-cluster` and `--to-cluster` in the Hubble CLI). This patch refactors the `--cluster` flag to filter based on the newly introduced endpoint cluster name info, making `--cluster foo` conceptually equivalent to "--from-cluster foo || --to-namespace foo" (and thus consistent with the `--namespace` flag) and removing the incompatibility with the `--node-name` flag. Signed-off-by: Alexandre Perrin <alex@isovalent.com> Suggested-by: Sebastian Wicki <sebastian@isovalent.com>
f6a6755
to
b6c4e32
Compare
Rebased on top of #35415 since it has been merged, now ready for review. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you!
/test |
#32313 introduced cluster name info at the Hubble flow Endpoint level. This PR adds corresponding filters on the Hubble server side, and two new
--from-cluster
and--to-cluster
Hubble CLI flags leveraging the new filter.For simplicity's sake the filter is a strict match for now, with the possibility to extend if/when the need arise (e.g. to RE2).