[LIVY-972] Add GitHub Action for CI image - #393
Conversation
ksumit
left a comment
There was a problem hiding this comment.
Thanks for taking this up.
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #393 +/- ##
============================================
- Coverage 68.37% 68.25% -0.12%
+ Complexity 849 847 -2
============================================
Files 103 103
Lines 5989 5989
Branches 911 911
============================================
- Hits 4095 4088 -7
- Misses 1330 1340 +10
+ Partials 564 561 -3 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
ksumit
left a comment
There was a problem hiding this comment.
Would it make sense to merge integration-tests.yaml and unit-tests.yaml and use some sort of flag to use one vs the other. We could also avoid building the repository two times (though I don't think that's a big problem since the builds are happening in parallel and probably not adding to the runtime of the overall pipelines). Thoughts?
| id: docker_build | ||
| uses: docker/build-push-action@v4 | ||
| with: | ||
| push: true |
There was a problem hiding this comment.
this is where we could change the logic to false if it's a PR build?
| container: ghcr.io/${{ github.repository_owner }}/livy-ci:latest | ||
| strategy: | ||
| matrix: | ||
| spark_version: ["2.4", "3.0"] |
There was a problem hiding this comment.
I think we can add the unit-test vs integration-test logic here.
There was a problem hiding this comment.
@dacort I wouldn't want to hold this PR for minor things. If you feel comfortable with the current state, I would push it as it is (something better than nothing) and then iterate on the improvements later on. Let me know what you think.
I wasn't quite sure if there was an easy way to do that. Can definitely look more into it, but ideas welcome. |
Here is an example that i found on https://docs.github.com/en/actions/learn-github-actions/contexts |
|
Thanks a lot for working on this @dacort! I agree with @ksumit's points and if you feel like this is good to go as is, we could merge it to restore CI functionality for the project. |
|
Thanks @gyogal - Yea, @ksumit I think for now we should merge this. I imagine the PR workflow and unit-test workflow will diverge in the future so would rather get this merged and iterate. @gyogal re: run the checks retroactively, I don't think it'll happen automatically but if folks push another commit it should. |
|
@dacort Thank you for your work on this! I have merged your commit and pre-commit checks are looking good now. There are two minor issues I noticed (maybe these are just temporary and will go away after a few builds):
Again, many thanks for adding these workflows because it unblocks PRs and is of great help for the project! |
|
@gyogal Yep I noticed that too as I work on #392. I initially thought it was related to my changes, but then noticed the failures on the main branch after this PR got merged in. I'm not quite sure what's going on as the unit tests ran fine in the PR. I'm also guessing the codecov might be related to the unit tests not running but that's just a theory at this point. |
* Add GitHub Action for CI image * Update push action * Add sample unit test * Add matrix based on spark version * Update spark version to be strings for proper comparison * Fix syntax * Add maven cache and integration tests * Just use actions/cache * Be more explicty with pom locations because container build is running as root. actions/runner#449 * Add MAVEN_OPTS to avoid timeouts[1] and ignore livy in m2 cache [1] apache/iotdb#3121 * Update cache paths * Add codecov
What changes were proposed in this pull request?
git pushHow was this patch tested?
Manual validation in the course of the pull request and new GitHub Actions workflows.