-
Notifications
You must be signed in to change notification settings - Fork 2
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
feat: initial implementation of evpn gw cni #14
Conversation
Signed-off-by: Dimitrios Markou <[email protected]>
d09a7fc
to
12625ed
Compare
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #14 +/- ##
======================================
Coverage 0 0.00%
======================================
Files 0 9 +9
Lines 0 1104 +1104
======================================
- Misses 0 1104 +1104 ☔ View full report in Codecov by Sentry. |
|
||
FROM docker.io/library/golang:1.21.6-alpine as builder |
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.
please do not remove docker.io
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.
done
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.
Added back in the line below.
pkg/utils/netlink_manager.go
Outdated
// Copyright (C) 2023 Nordix Foundation. | ||
|
||
package utils | ||
|
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.
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.
@glimchb in your netlink wrapper library that you want me to use each function there takes as parameter a context.
In this case here should I use an empty context right ? Like context.Background() ? Is this enough ?
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.
yes, context.Background()
is perfectly valid
or context.WithTimeout(context.Background(), 3)
if you care about timeouts of the operation...
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.
@glimchb I think is not so trivial to just import that library and use it. The reason is that this library expects that there is some otel server that runs somewhere. If not then I get errors back related to the tracer.start(ctx) function
https://github.com/opiproject/opi-evpn-bridge/blob/main/pkg/utils/netlink.go#L50
We need to make the tracer.start code section optional in order to skip it if there is no otel service
WDYT ?
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.
errors should not be fatal, service just trying to send traces to otel collector should not fail...
I also suggest to spin a jaeger
like I do in all other OPI repos, example: https://github.com/opiproject/opi-evpn-bridge/blob/5440fb9f85ed80d74658412a0cf3ff352b8d29dd/docker-compose.yml#L221-L235
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.
@glimchb Even if that doesn't cause a fatal fail due to the fact that it waits until it timeouts (because there is no otel collector) make the calls extremely long and delayed.
Also a CNI is just a binary that you throw in a K8s system and just works. Is highly unlikely to have CNI depend on an OTEL collector like jaeger. In most of the systems there is no Jaegger.
I think the implementation that we have today in the netlink wrapper is not good enough to just import it from a CNI. I believe we should make some changes to at least make the trace part optional.
WDYT ?
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.
Hello @glimchb can you please respond to my comment above ?
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.
you can add if n.tracer != nil
in https://github.com/opiproject/opi-evpn-bridge/blob/main/pkg/utils/netlink.go#L50
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.
// SPDX-License-Identifier: Apache-2.0 | ||
// Copyright (C) 2023 Nordix Foundation. | ||
// Copyright (c) 2024 Ericsson AB. | ||
|
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.
this code should just import and use https://github.com/opiproject/godpu library
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.
done
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.
library imported in line 15 below
|
||
[](https://github.com/opiproject/opi-gateway-evpn-cni/actions/workflows/linters.yml) |
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.
why badges removed ?
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.
done
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.
Badges included again in latest.
|
||
## I Want To Contribute |
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.
this section must stay
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.
done
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.
Now in line 205 below
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.
- code dup
- ci failed
- no tests
- no godpu usage
- readme removed badges
- readme : i want to contribute section must stay
@glimchb Thank you for the review. I will take a look |
@mardim91 Any update on the resolution of the comments? |
Hello @sandersms, No I haven't found the time to work on that yet. I will do it beginning of Q2. I was working on this PR: opiproject/opi-evpn-bridge#377 |
Signed-off-by: Dimitrios Markou <[email protected]>
Signed-off-by: Dimitrios Markou <[email protected]>
Hello @sandersms I have resolved all the above comments. |
Signed-off-by: Dimitrios Markou <[email protected]>
I have converted this to draft as the dependent PR in opi-evpn-bridge is still unmerged |
Signed-off-by: Dimitrios Markou <[email protected]>
|
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.
Changes and updates from comments look to be resolved.
Hello @glimchb, I have resolved all the comments that you have left. I will propose that maybe we can merge this one as the first PR to the project and then if we need to fix or add anything more we can create new PRs on top. This PR is a working one and is quite some time open so I am thinking that we can merge it as the comments are resolved and all the dependent PRs in the OPI-EVPN-BR project are merged. |
code dup fixed Tests for the feature are missing and should be included for validation. Issue #16 opened to cover the missing aspect that needs to be added. |
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.
Re-review of changes look good.
Tests still missing. Added an issue for the functionality to be addressed in subsequent PR
Reported items are fixed and one issue opened for the test routines. No response on approval and needs to move forward.
Initial implementation of EVPN GW CNI. Currently only Intel Mt.Evans IPUs are supported by this CNI. Target is to support more IPUs/DPUs in the future. It has an integration with the EVPN GW API .