-
Notifications
You must be signed in to change notification settings - Fork 20
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
update example to adapt Envoy 1.31 #742
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #742 +/- ##
=======================================
Coverage 88.44% 88.44%
=======================================
Files 132 132
Lines 6475 6475
=======================================
Hits 5727 5727
Misses 536 536
Partials 212 212 ☔ View full report in Codecov by Sentry. |
and some more chore changes. Signed-off-by: spacewander <[email protected]>
google.golang.org/protobuf v1.33.0 | ||
mosn.io/htnn/api v0.3.2 | ||
google.golang.org/protobuf v1.34.1 | ||
mosn.io/htnn/api v0.3.3-0.20240924080219-d01ea9d6301e |
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.
Does it fair to say this api is not compatible for envoy 1.29 after the lib upgraded? Or we support both 1.28 and 1.31?
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.
I wrote a compatible layer for Envoy 1.29, so both Envoy 1.29 and 1.31 are supported. If we need to support Envoy 1.30, we can write a compatible layer for it.
Here are the steps to support Envoy 1.29: https://github.com/mosn/htnn/blob/main/site/content/en/docs/developer-guide/dataplane_support.md#choosing-the-target-data-plane-version. We use replace in go.mod
and build tag to switch the Envoy SDK we used as Go doesn't support multiple version of the same library in one module. If you use the latest Envoy (1.31), you don't need to do anything - the support is out of the box.
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.
Thanks a lot! We're using envoy 1.31 for now, and having some old versions running in production as well. In case we will probably need to support multiple envoy versions in the long term for some useful filters, I would like to have your clarification here in the examples to guide us about maintaining multiple envoy versions for this example golang filter.
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.
@wonderflow
Feel free to open an issue to ask for a new example about running HTNN on the old Envoy.
For now, you can refer to
htnn/manifests/images/dp/Dockerfile
Lines 37 to 42 in d01ea9d
COPY patch/switch-envoy-go-version.sh patch/switch-envoy-go-version.sh | |
COPY common.mk common.mk | |
# hadolint ignore=DL3003 | |
RUN ./patch/switch-envoy-go-version.sh 1.29.5 && \ | |
cd plugins/ && \ | |
ENVOY_API_VERSION=1.29 make build-so-local |
In this living code we build a shared lib target to the istio 1.21.3's data plane (which is covered by the e2e tests).
BTW, I don't recommend using HTNN on Envoy < 1.29. Versions before that are too old unless you can backport the latest Envoy Golang filter to an old version.
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.
The dockefile above is helpful, thanks! What is our compatible strategy? I don't want old version support, but in the feature let's say when envoy 1.32 or newer version come out, when will we retire the 1.29 support?
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.
What is our compatible strategy?
We will maintain the Envoy X support as long as Envoy still provides security updates for version X or the istio version used by Ant Group (currently 1.21) requires version X.
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.
that's cool
and some more chore changes.
Signed-off-by: spacewander [email protected]