-
Notifications
You must be signed in to change notification settings - Fork 16
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
Force CPP++17 installation for Thrift and Boost. #66
base: main
Are you sure you want to change the base?
Conversation
@vgurevich These changes update Thrift from version 0.14 to 0.21, which I think were released about 3.5 years apart. I do not know the Thrift developers policies on maintaining compatibility across versions, but it seems worth running at least one test that exercises Thrift to test such a change. Do you knew whether: (a) running a test like the tna_counters one exercises using the Thrift API at all? |
@jafingerhut -- P4_16 tests do not use Thrift. They use gRPC. All P4_14 tests use Thrift. Also it is used by bf-diags and SAI |
I will try building with this PR's changes locally, and then try out a P4_14 test or two to check whether they pass, and if so, how long they take, and suggest one for adding to the CI build & test. |
@fruffy I successfully built on an Ubuntu 20.04 freshly installed VM with this PR's changes. I am still testing a few more P4_14 tests, but have results for most of them here: https://docs.google.com/spreadsheets/d/1WCP2J7_g4j3ilFVRXaEM9S39_v6Go1_5WcCYJ6uJYY4/edit?gid=0#gid=0 I will add results for trying the P4_16 tests after that. The few P4_14 tests that are failing are due to one of two reasons, so far: (a) missing configuration files. I think they are tests where they are intended to have the user write a JSON config file to direct exactly how the test behaves, and no default version of those files were included in the repository (and maybe aren't in the original repository at Intel, either). I have checked, and they are not part of the private open-p4studio-old repository. (b) One test named 'knet_mgr_test' has a Python ptf program that tries to use a class As far as I can tell, none of the failures are because of issues with Thrift, so that is good. I recommend adding to this PR, in file the following new lines, to run one P4_14 test that takes less than 40 sec on my system. Or we might want to put the existing test and the new one in a bash for loop, to make it easier to add new ones later, perhaps. Note that the
|
I wonder whether we should even bother maintaining P4-14? I have been thinking of deprecating that code entirely for P4C to reduce the complexity of the code base. |
I think @vgurevich probably has a better view of how useful it is to keep it working. Dropping test support at some point seems reasonable, but given how new this repository is, it seems worth putting forth some minimal effort to see if it is working now, before explicitly saying "from date X forward, we are no longer testing P4_14 support". |
@fruffy -- let's make sure we can make everything run first. There are still plenty of projects and publications that use (used) P4_14, including the number of those who had done it on Tofino. Do we want to leave all these people "high and dry"? Also, as I mentioned above, the same API framework (PD API) is also used by bf-diags. Some of the APIs available through Thrift are still not available via BRI. So, even if you kill P4_14, it is not going to help you to remove Thrift. |
Not proposing to get rid of Thrift but proposing to get rid of P4-14. At some point we have to progress and there is a lot of code dedicated to P4-14 which can make changes to the infrastructure hard. We are not Microsoft who can afford the backwards compatibility and there are no paying customers here. I am actually quite okay with leaving users who refuse to move on high and dry. I even assume these users are still using some old version of the SDE anyway. But this is something for the future. Right now, it probably makes sense to get one working version done. The Thrift changes here are mostly for making sure that we can compile bf-diags for Ubuntu 24.04 and C++17 (which most of the code base uses now). |
If/when we drop P4_14 support, it would be good to create a tag with the latest version that had P4_14 support, and document that tag in an easy-to-find place, e.g. top level README or some document linked from there, with test results. |
Yes, totally! |
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.
Most P4_14 tests pass, and the only failures are for reasons other than the Thrift library. Most P4_16 tests pass as well, and the few failures appear to have nothing to do with the Thrift library.
Signed-off-by: fruffy <[email protected]>
Signed-off-by: fruffy <[email protected]>
Signed-off-by: fruffy <[email protected]>
4ab5492
to
57130fb
Compare
@fruffy I have approved based on earlier testing, before your latest changes. Do you want me to retest before you merge? I am fine either way. |
Not necessary. I might do some config tweaks to simplify and speed up the Thrift installation. That's it. |
Btw, we should really automate these kinds of tests that you do not have to do this every time. |
I certainly won't be doing them every time. Once things settle down and we trust the CI tests to catch most things, I'll probably try installing on a freshly installed system once per month or so, maybe even create a VirtualBox VM image for people to download if they don't want to build the code themselves. I have forgotten exactly which recent PRs we were seeing differences between CI test results and my local install, but I haven't seen those in a while now. |
Fixes #8.