Repository navigation
build(java): make the Java SDK modules publishable to the ASF Nexus - #980
Conversation
The SDK modules declare their version through ${graphar.version} and
inherit from an unpublished root, so an installed POM cannot be resolved
by a consumer. Flatten the SDK module POMs and the root POM so published
POMs carry concrete versions and no parent, add the project SCM, issue
tracker and developers that the repository metadata needs, and bundle the
incubator DISCLAIMER into every jar next to LICENSE and NOTICE.
Add a snapshot workflow that tests and deploys the SDK modules to the ASF
snapshot repository on pushes to main, with a dry-run dispatch. It uses
the NEXUS_USER and NEXUS_PW secrets that ASF Infra provisions per
repository.
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #980 +/- ##
=========================================
Coverage 77.59% 77.59%
Complexity 682 682
=========================================
Files 85 85
Lines 9091 9091
Branches 1098 1098
=========================================
Hits 7054 7054
Misses 1780 1780
Partials 257 257
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
|
@SemyonSinchenko gentle ping: this PR has been fully green since Sept 24 and is still waiting for a first review. Two more Java PRs are also up: #982 (fixes #981, io-parquet partial row ranges without an Offset Index) and #983 (reader facade for #978), both rebased onto current main with the #985 fix. And whenever you have a moment, the INFRA-ticket question for Maven Central in #979 still needs your input. Thanks! |
|
Let's see is it working :) |
|
It reached Nexus but got a 401: the job env ran with empty |
Reason for this PR
Part of #979: consumers cannot depend on the pure-Java SDK today. No
org.apache.grapharartifact exists on Maven Central or in the ASF snapshot repository, and the modules are not publishable as they stand: every SDK POM uses${graphar.version}for its own and its parent's version, and the parentgraphar-rootis never published, so an installed POM cannot be resolved outside this reactor.This PR prepares the build side only. It does not change the version, cut a release, or publish anything by itself.
What changes are included in this PR?
flatten-maven-plugin(oss mode) ongraphar-info,graphar-storage-api,graphar-storage-local,graphar-storage-s3,graphar-io-api,graphar-core, and on the root POM itself (not inherited). Installed and deployed POMs carry concrete versions and no parent. The FastFFIjavamodule andsparkare untouched.apache/incubator-grapharURLs, plus adevelopersentry pointing at dev@. These are required repository metadata.apache-incubator-disclaimer-resource-bundleadded to the Apache parent's remote resources, so every jar carriesMETA-INF/DISCLAIMERnext toLICENSEandNOTICE..github/workflows/java-sdk-snapshot.yml: on pushes to main that touch the SDK, runs the SDK tests andmvn deploytoapache.snapshots.https(distribution management comes from the Apache parent). It refuses non-SNAPSHOT versions, runs only inapache/incubator-graphar, and has aworkflow_dispatchdry run that stops atinstall. The same pattern is used by apache/datafusion-comet.When #975 and the reader/writer land, their modules get the same one-line plugin entry and join
SDK_MODULES.What maintainers need to do outside this PR
org.apache.graphargroupId in the ASF Nexus and provision theNEXUS_USER/NEXUS_PWsecrets on this repository. Until then the deploy step fails with 401; the dry run works.0.13.0-SNAPSHOTalthough v0.13.0 is released. I left the bump to the release manager since it also affectsspark.Are these changes tested?
Locally:
spotless:check,clean verify, andpackage javadoc:javadocforinfo,storage-api,storage-local,io-api,storage-s3,core: green.graphar-info,graphar-core,graphar-storage-apiandgraphar-storage-local(nographar-root). It resolves and loadsorg.apache.graphar.info.GraphInfo.graphar-corejar containsMETA-INF/DISCLAIMER,LICENSE,NOTICE.mvn -pl spark/graphar,java -am validatesucceeds.Are there any user-facing changes?
No API changes. Once the secrets are provisioned, SDK snapshots appear at
https://repository.apache.org/content/repositories/snapshots/org/apache/graphar/.Checklist
make cpplintbefore submitting when changed files are in thecppdirectory.pre-commit runbefore commit the changed files.