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

[native] Convert CircleCI jobs for PrestoC++ to Github actions #24236

Merged
merged 1 commit into from
Dec 14, 2024

Conversation

czentgr
Copy link
Contributor

@czentgr czentgr commented Dec 10, 2024

This pull request converts the CircleCI workflows to GitHub actions workflows.
The workflows use the standard runners with Ubuntu 22.04.

Some modifications were made to allow a build with the limited resources available:

name build type comments expected runtime (w/out cache) unit tests E2E tests
prestocpp-linux-build debug All adapters enabled 45m N N
prestocpp-linux-build-and-unit-test release JWT, remote function, Parquet enabled 90m Y Y
prestocpp-macos-build debug Setup script plus build up to 160m N N
prestocpp-linux-adapters-build release Adapters only build 5m N N

Caching is currently enabled for the prestocpp-linux-build-and-unit-test. If the cache can be used, the time to run tests drops to 50m.

Additional workflows are prestocpp-format-check and prestocpp-header-check
That run in a few seconds.

For the original conversion see: #21545

Resolves: #24023

Test runs can be seen in the Actions tab of the prestodb/presto repo.


Description

Motivation and Context

Impact

Test Plan

Contributor checklist

  • Please make sure your submission complies with our contributing guide, in particular code style and commit standards.
  • PR description addresses the issue accurately and concisely. If the change is non-trivial, a GitHub Issue is referenced.
  • Documented new properties (with its default value), SQL syntax, functions, or other functionality.
  • If release notes are required, they follow the release notes guidelines.
  • Adequate tests were added if applicable.
  • CI passed.

Release Notes

Please follow release notes guidelines and fill in the release notes below.

== NO RELEASE NOTE ==

@prestodb-ci prestodb-ci added the from:IBM PR from IBM label Dec 10, 2024
@prestodb-ci prestodb-ci requested review from a team, zuyu and BryanCutler and removed request for a team December 10, 2024 16:51
@czentgr czentgr force-pushed the cz_test_standard_runner_build branch 25 times, most recently from f9ddbda to 68743bf Compare December 12, 2024 16:39
@czentgr czentgr force-pushed the cz_test_standard_runner_build branch from ba2a256 to edeb87f Compare December 12, 2024 22:47
@czentgr czentgr changed the title [native] test standard runner prestocpp build [native] Convert CircleCI jobs for PrestoC++ to Github actions Dec 12, 2024
@czentgr czentgr force-pushed the cz_test_standard_runner_build branch from edeb87f to f662fea Compare December 12, 2024 22:49
@czentgr
Copy link
Contributor Author

czentgr commented Dec 12, 2024

The Spark E2E pipeline is currently failing.
It turns out that CircleCI was not running all tests. It only ran a subset of tests and this exposes test issues in the Github workflow run.

The CircleCI test classes run

TESTCLASSES=TestPrestoSparkExpressionCompiler,TestPrestoSparkNativeJoinQueries,TestPrestoSparkSqlFunctions

The Github workflow test classes run:

TESTCLASSES = TestPrestoSparkExpressionCompiler,TestPrestoSparkNativeBitwiseFunctionQueries,TestPrestoSparkNativeAggregations,TestPrestoSparkNativeTpchConnectorQueries,TestPrestoSparkNativeSimpleQueries,TestPrestoSparkSqlFunctions,TestPrestoSparkNativeJoinQueries,TestPrestoSparkNativeWindowQueries,TestPrestoSparkNativeTpchQueries,TestPrestoSparkNativeArrayFunctionQueries,TestPrestoSparkNativeGeneralQueries

Issues created:
#24253
#24254
#24255

@czentgr czentgr marked this pull request as ready for review December 12, 2024 22:51
@czentgr czentgr requested review from a team as code owners December 12, 2024 22:51
@czentgr
Copy link
Contributor Author

czentgr commented Dec 12, 2024

@amitkdutta @tdcmeehan Here is the PR with the new github action workflows running on standard runners. The jobs are running as part of this PR.

There are Spark test failures. In CircleCI not all tests are apparently run and so we are running new tests that come back with errors and need fixing. I've created issues for them.

There are certainly options for more optimization within the workflows but this should be able to tide us over.

@czentgr czentgr force-pushed the cz_test_standard_runner_build branch from f662fea to 6f71f9c Compare December 12, 2024 23:02
Copy link
Collaborator

@majetideepak majetideepak left a comment

Choose a reason for hiding this comment

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

@czentgr thanks for pulling this off quickly and timely. Some comments.

.github/workflows/prestocpp-header-check.yml Outdated Show resolved Hide resolved
run: |
cd presto-native-execution
make submodules
- name: Build all adapter dependencies
Copy link
Collaborator

Choose a reason for hiding this comment

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

We can remove this job. I am adding the adapters to the dependency image.
#24251

Copy link
Contributor Author

Choose a reason for hiding this comment

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

This job is here so we can check if changes in scripts trigger a failure with the adapters. The triggers is only changes in the script dir.
I can change it to specifically only trigger on changes to setup-adapter.sh. We don't want to find out issues when building the image after having changed the setup-adapters. I think it is useful to have. It won't run very often.

Copy link
Contributor Author

@czentgr czentgr Dec 12, 2024

Choose a reason for hiding this comment

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

Actually, lets make it to run when we update velox or setup-adapters.sh.
The job is one of the quicker ones. That way we don't get nasty surprises.

Copy link
Collaborator

Choose a reason for hiding this comment

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

But we don't need to install /velox/scripts/setup-adapters.sh since that is tested on the Velox CI.

Copy link
Collaborator

Choose a reason for hiding this comment

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

We also don't need this on a Velox update then.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I was thinking if we could have a situation that isn't tested in Velox but might be used in PrestoC++. But I guess we'd need a full adapters build and PrestoC++ build. Which was what one CircleCI job originally did.

.github/workflows/prestocpp-linux-build-and-unit-test.yml Outdated Show resolved Hide resolved
.github/workflows/prestocpp-macos-build.yml Show resolved Hide resolved
presto-native-execution/scripts/setup-centos.sh Outdated Show resolved Hide resolved
@czentgr czentgr force-pushed the cz_test_standard_runner_build branch 3 times, most recently from baa1163 to 6162673 Compare December 13, 2024 00:10
@majetideepak
Copy link
Collaborator

majetideepak commented Dec 13, 2024

@czentgr can we remove the CircleCI files in this PR as well?

@majetideepak
Copy link
Collaborator

I wonder why the Presto e2e tests are taking much longer in the github workflow (~39 minutes ) compared to the CI. (~5 minutes)

Copy link
Contributor Author

@czentgr czentgr left a comment

Choose a reason for hiding this comment

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

As for the E2E Presto test difference. I think it is the same as for Spark. I'm adding a comment about that in the PR. It is clear we are running many more tests based on the summary.

run: |
cd presto-native-execution
make submodules
- name: Build all adapter dependencies
Copy link
Contributor Author

Choose a reason for hiding this comment

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

I was thinking if we could have a situation that isn't tested in Velox but might be used in PrestoC++. But I guess we'd need a full adapters build and PrestoC++ build. Which was what one CircleCI job originally did.

.github/workflows/prestocpp-linux-build.yml Outdated Show resolved Hide resolved
@czentgr
Copy link
Contributor Author

czentgr commented Dec 13, 2024

I wonder why the Presto e2e tests are taking much longer in the github workflow (~39 minutes ) compared to the CI. (~5 minutes)

In an earlier comment we looked at the Spark failures and realized that CircleCI isn't actually running all the test classes that it could/that are found when simply looking at the names.
The same applies to Presto E2E tests. In CircleCI we can see only 133 tests are run
from https://app.circleci.com/pipelines/github/prestodb/presto/23370/workflows/96edda2e-37ec-410f-ac23-720b11722347/jobs/97390

[INFO] Tests run: 133, Failures: 0, Errors: 0, Skipped: 0

while the Github runners run every test:
from https://github.com/prestodb/presto/actions/runs/12307010027/job/34350125338?pr=24236

[INFO] Tests run: 594, Failures: 0, Errors: 0, Skipped: 0

For example, we can see that TestPrestoNativeTpchConnectorQueries is not run in CircleCI. This applies to a number of test classes.

@czentgr
Copy link
Contributor Author

czentgr commented Dec 13, 2024

@czentgr can we remove the CircleCI files in this PR as well?

After discussion we decided to remove them separately after a few days of having both pipelines run.

@czentgr czentgr force-pushed the cz_test_standard_runner_build branch 2 times, most recently from 7f08dbd to 0562187 Compare December 13, 2024 20:26
This pull request converts the CircleCI workflows to GitHub actions workflows.
The workflows use the standard runners with Ubuntu 22.04.

Some modifications were made to allow a build with the limited resources available:

|name|build type|comments|expected runtime (no cache)|unit tests|E2E tests|
|----|----------|--------|----------------|----------|---------|
| prestocpp-linux-build | debug | All adapters enabled | 45m | N | N |
| prestocpp-linux-build-and-unit-test | release | JWT, remote function, Parquet enabled | 90m | Y | Y |
| prestocpp-macos-build | debug | Setup script plus build | 160m | N | N |
| prestocpp-linux-adapters-build | release | Adapters and release build | 120m | N | N |

Caching is currently enabled for the prestocpp-linux-build-and-unit-test. If the cache can be used, the time to run tests drops to 50m.

Additional workflows are prestocpp-format-check and prestocpp-header-check
That run in a few seconds.

For the original conversion see: prestodb#21545

Co-authored-by: Rob Anderson <[email protected]>
@czentgr czentgr force-pushed the cz_test_standard_runner_build branch from 0562187 to 35816fd Compare December 13, 2024 21:32
Copy link
Collaborator

@majetideepak majetideepak left a comment

Choose a reason for hiding this comment

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

Thanks, @czentgr

@majetideepak
Copy link
Collaborator

@tdcmeehan can you please help merge this PR? Thanks.

@tdcmeehan tdcmeehan merged commit 17ac4c3 into prestodb:master Dec 14, 2024
63 of 64 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
from:IBM PR from IBM
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Migrate Presto C++ CI jobs off of CircleCI
4 participants