10000 [CI] Enable Java test in CI workflow by rhdong · Pull Request #805 · rapidsai/cuvs · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

[CI] Enable Java test in CI workflow #805

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

Merged
merged 69 commits into from
May 8, 2025

Conversation

rhdong
Copy link
Member
@rhdong rhdong commented Apr 3, 2025

This PR adds changes for Java CI.

Some scripts modified here also appear in PR #831. Once 831 is merged, I’ll rebase and make sure everything stays consistent.

@rhdong rhdong requested review from a team as code owners April 3, 2025 22:04
@rhdong rhdong requested a review from jameslamb April 3, 2025 22:04
@github-actions github-actions bot added the ci label Apr 3, 2025
@rhdong rhdong added feature request New feature or request non-breaking Introduces a non-breaking change labels Apr 3, 2025
@rhdong rhdong requested a review from cjnolet April 3, 2025 22:04
@rhdong rhdong requested a review from raydouglass April 3, 2025 22:07
8000
@jameslamb
Copy link
Member

@rhdong could you please put this PR into draft until you're ready for reviews? That'd reduce the notifications reviewers are getting, and help them understand when it's time to come review.

@rhdong
Copy link
Member Author
rhdong commented Apr 4, 2025

@rhdong could you please put this PR into draft until you're ready for reviews? That'd reduce the notifications reviewers are getting, and help them understand when it's time to come review.

Thanks for the reminder! I’ve marked the PR as draft now.

@rhdong rhdong closed this Apr 4, 2025
@rhdong rhdong reopened this Apr 4, 2025
@rhdong rhdong marked this pull request as draft April 4, 2025 15:02
Copy link
copy-pr-bot bot commented Apr 4, 2025

Auto-sync is disabled for draft pull requests in this repository. Workflows must be run manually.

Contributors can view more details about this message here.

@rhdong
Copy link
Member Author
rhdong commented Apr 4, 2025

/ok to test

@rhdong
Copy link
Member Author
rhdong commented Apr 7, 2025

/ok to test

@rhdong
Copy link
Member Author
rhdong commented Apr 7, 2025

/ok to test

@rhdong
Copy link
Member Author
rhdong commented May 5, 2025

I just tested it locally and it works! Here's a patch for fixing the javadocs plugin issue. We can fix it in a subsequent PR as well, if you think that's better. javadocs-plugin-fix.txt

It fixes these warnings in the build for me:

[WARNING] 
[WARNING] Some problems were encountered while building the effective model for com.nvidia.cuvs:cuvs-java:jar:25.06.0
[WARNING] 'build.plugins.plugin.(groupId:artifactId)' must be unique but found duplicate declaration of plugin org.apache.maven.plugins:maven-javadoc-plugin @ line 257, column 17
[WARNING] 
[WARNING] It is highly recommended to fix these problems because they threaten the stability of your build.
[WARNING] 
[WARNING] For this reason, future Maven versions might no longer support building such malformed projects.
[WARNING] 

@chatman thank you! Done the patch!

@rhdong
Copy link
Member Author
rhdong commented May 5, 2025

/ok to test 0f90041

Copy link
Member
@jameslamb jameslamb left a comment

Choose a reason for hiding this comment

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

I left some suggestions for your consideration. There are enough of them that I'm leaving a blocking review... please @ me when this is ready for another review.

If you'd prefer that I just push these changes directly to the PR instead, please let me know and I'd be happy to.

Also (not blocking this PR), I think it would be very helpful to reduce the duplication of the Java version across these builds. The assumption of Java 22 is hard-coded in many places right now, and it'd be easy to accidentally miss mentions like this during updates:

https://github.com/rapidsai/cuvs/blob/4a4d86363fd700f487593e65dd9e9ceb321a9c12/java/cuvs-java/pom.xml#L61-L622

If you agree with me about that, that could be a followup PR.

@rhdong
Copy link
Member Author
rhdong commented May 6, 2025

I left some suggestions for your consideration. There are enough of them that I'm leaving a blocking review... please @ me when this is ready for another review.

If you'd prefer that I just push these changes directly to the PR instead, please let me know and I'd be happy to.

Also (not blocking this PR), I think it would be very helpful to reduce the duplication of the Java version across these builds. The assumption of Java 22 is hard-coded in many places right now, and it'd be easy to accidentally miss mentions like this during updates:

https://github.com/rapidsai/cuvs/blob/4a4d86363fd700f487593e65dd9e9ceb321a9c12/java/cuvs-java/pom.xml#L61-L622

If you agree with me about that, that could be a followup PR.

Sure, thank you so much for your suggestions, which are super helpful! For this time, I will submit by myself to avoid duplicate commits, and pls feel free to push directly in next round.

@rhdong
Copy link
Member Author
rhdong commented May 6, 2025

/ok to test 88165ad

@rhdong rhdong requested a review from jameslamb May 7, 2025 04:19
@rhdong
Copy link
Member Author
rhdong commented May 7, 2025

I left some suggestions for your consideration. There are enough of them that I'm leaving a blocking review... please @ me when this is ready for another review.

If you'd prefer that I just push these changes directly to the PR instead, please let me know and I'd be happy to.

Also (not blocking this PR), I think it would be very helpful to reduce the duplication of the Java version across these builds. The assumption of Java 22 is hard-coded in many places right now, and it'd be easy to accidentally miss mentions like this during updates:

https://github.com/rapidsai/cuvs/blob/4a4d86363fd700f487593e65dd9e9ceb321a9c12/java/cuvs-java/pom.xml#L61-L622

If you agree with me about that, that could be a followup PR.

Hi @chatman , per James’s comment regarding the Java version, do you have any suggestions or guidance on what the best practice typically is in this case? Thanks!

Copy link
Member
@jameslamb jameslamb left a comment

Choose a reason for hiding this comment

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

Thanks for all the changes! I have one more important comment for your consideration. Sorry for not mentioning it earlier.

ci/build_java.sh Outdated
Comment on lines 23 to 24
export CMAKE_GENERATOR=Ninja

Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
export CMAKE_GENERATOR=Ninja

This can probably be removed here as well, as it was in ci/test_java.sh as part of #805 (comment).

And I see another issue... the change to add libraft and NCCL was not also applied to the test_java group in dependency-file-generator: #805 (comment).

These types of issues are direct result of the high amount of duplication here... I think we should consolidate things.

test_java.sh only differs from build_java.sh in 2 ways:

  • passes --run-java-tests to java/build.sh
  • uses the test_java dependency group for rapids-dependency-file-generator (which would be identical to the java group there if libraft and NCCL were correctly added)

I think we should do the following:

  • remove test_java group in dependencies.yaml
  • consolidate all of the duplicated stuff in build_java.sh and test_java.sh
    • for example, by having build_java.sh accept a --run-java-tests argument
    • that would also ensure build_java.sh is getting tested on PRs (currently it'd only run on nightly builds)

Could I push changes like that to this branch?

Copy link
Member

Choose a reason for hiding this comment

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

I've pushed these changes in 1303422

Let's see how CI goes.

@jameslamb
Copy link
Member

/ok to test 1303422

@jameslamb
Copy link
Member

/ok to test 53f5002

@jameslamb jameslamb self-requested a review May 7, 2025 22:19
Copy link
Member
@jameslamb jameslamb left a comment

Choose a reason for hiding this comment

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

From my perspective, this is ready to merge! The stuff I mentioned about reducing hard-coding of the Java version could come in a later PR (or not at all, if you choose not to pursue it).

Just check the conda-java-tests logs to be sure the tests are running after the most recent fix, otherwise I am ok with merging any time.

@rhdong
Copy link
Member Author
rhdong commented May 7, 2025

/ok to test e69d623

@cjnolet
Copy link
Member
cjnolet commented May 8, 2025

/merge

@rapids-bot rapids-bot bot merged commit d14552a into rapidsai:branch-25.06 May 8, 2025
75 checks passed
rapids-bot bot pushed a commit that referenced this pull request May 12, 2025
…only modify update-version.sh (#875)

While reviewing #805, I found an issue with this project's `update-version.sh`... it refers to a script `examples/cmake/thirdparty/fetch_rapids.cmake` which no long exists (removed in #824).

This proposes the following:

* removing that reference from `update-version.sh`
* skipping most CI on PRs that only modify `update-version.sh`

## Notes for Reviewers

`ci/release/update-version.sh` is standardized (same filepath, same usage) across almost all RAPIDS repos. I cannot think of a situation where a PR that only changes that file would need to have any CI re-run (other than linting, e.g. for `shellcheck`).

If folks agree, I'll roll out a change like that more broadly across RAPIDS.

Authors:
  - James Lamb (https://github.com/jameslamb)
  - Ben Frederickson (https://github.com/benfred)

Approvers:
  - Ben Frederickson (https://github.com/benfred)
  - Corey J. Nolet (https://github.com/cjnolet)
  - Gil Forsyth (https://github.com/gforsyth)

URL: #875
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ci feature request New feature or request non-breaking Introduces a non-breaking change
Development

Successfully merging this pull request may close these issues.

6 participants
0