Skip to content
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 Thrift to version 0.16 #657

Merged
merged 26 commits into from
Nov 12, 2023

Conversation

LoremIPsummer
Copy link
Collaborator

@LoremIPsummer LoremIPsummer commented Oct 27, 2023

Update Thrift to version 0.16.

Since version 0.14, Thrift does not generate certain files, causing an error in CMake. To solve this, I made a wrapper function around the generation logic, so if some of the specified files are not generated, we manually create them.

There was an undocumented breaking change involving the java transport protocol implementations. The indexer service didn't handle all the exceptions correctly, leading to an API mismatch.

Since version 0.15, the javascript library provided by the thrift npm package also ships with the nodejs bindings. For environment detection, it internally uses a package called browser-or-node. However, this plugin needs to be bundled with the generated javascript code, making it impossible to directly use it in the old webgui by simply referencing the thrift.js library downloaded from npm. Such change requires the introduction of a build system (like webpack or browserify), and the proper conversion of CommonJS modules to AMD, so it goes beyond the scope of this PR. However, a traditional browser version of the library can still be acquired by downloading it directly from the Thrift repository with the proper version. I've decided to simply grab it from here and put it into the appropriate scripts directory.

The new webgui doesn't produce this behavior, as expected.

fixes #630

@LoremIPsummer LoremIPsummer self-assigned this Oct 27, 2023
@LoremIPsummer LoremIPsummer marked this pull request as draft October 28, 2023 03:59
@LoremIPsummer LoremIPsummer marked this pull request as ready for review October 28, 2023 15:26
@mcserep mcserep self-requested a review October 31, 2023 11:53
@mcserep mcserep added Kind: Refactor 🔃 Target: Developer environment Developer environment issues consist of CodeCompass or 3rd-party build tooling, configuration or CI. Target: Service Issues related to the Thrift service. labels Oct 31, 2023
Functions.cmake Outdated Show resolved Hide resolved
@LoremIPsummer LoremIPsummer requested a review from mcserep October 31, 2023 16:32
Copy link
Collaborator

@mcserep mcserep left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The GitHub CI should also be updated to use Thrift 16.

doc/deps.md Show resolved Hide resolved
@LoremIPsummer LoremIPsummer requested a review from mcserep November 8, 2023 05:08
.github/scripts/ubuntu-20.04/postcompile_build.sh Outdated Show resolved Hide resolved
.github/scripts/ubuntu-20.04/postcompile_runtime.sh Outdated Show resolved Hide resolved
.github/scripts/ubuntu-20.04/compile_build.sh Outdated Show resolved Hide resolved
.github/scripts/ubuntu-20.04/download_build.sh Outdated Show resolved Hide resolved
.github/scripts/ubuntu-20.04/download_build.sh Outdated Show resolved Hide resolved
.github/scripts/ubuntu-20.04/compile_build.sh Outdated Show resolved Hide resolved
.github/workflows/ci.yml Outdated Show resolved Hide resolved
 empty lines
@LoremIPsummer
Copy link
Collaborator Author

@mcserep
I also removed the not generated files from the new cppmetrics plugin from CMake.

Copy link
Collaborator

@mcserep mcserep left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good now, nice work!

@mcserep mcserep merged commit 09958e1 into Ericsson:master Nov 12, 2023
7 checks passed
wbqpk3 pushed a commit to wbqpk3/CodeCompass that referenced this pull request Jul 8, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Kind: Refactor 🔃 Target: Developer environment Developer environment issues consist of CodeCompass or 3rd-party build tooling, configuration or CI. Target: Service Issues related to the Thrift service.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Update Thrift to 0.16
2 participants