Skip to content

build: skip javadoc publication for snapshots - #497

Merged
ndr-brt merged 1 commit into
mainfrom
fix/skip-javadoc-for-snapshots
Nov 13, 2026
Merged

ndr-brt merged 1 commit into
mainfrom
fix/skip-javadoc-for-snapshots

Conversation

@ndr-brt

@ndr-brt ndr-brt commented Nov 13, 2026

Copy link
Copy Markdown
Member

What this PR changes/adds

When the project version ends with -SNAPSHOT, MavenPublicationConvention now configures the vanniktech publication without a javadoc jar (configureBasedOnAppliedPlugins(true, false) → JavadocJar.None). Release publications are unchanged: they still get the javadoc jar, which Maven Central requires.

Why it does that

Since 2026-11-12, snapshot publication has been failing with 429 Too Many Requests from central.sonatype.com/repository/maven-snapshots (e.g. Connector and IdentityHub trigger_snapshot runs). A full Connector snapshot run publishes ~196 modules sequentially, with every file uploaded together with its .asc signature and md5/sha1/sha256/sha512 checksums.

Maven Central doesn't validate snapshots ("As with the legacy OSSRH -SNAPSHOT publishing, no validation is performed", docs), so the javadoc jar isn't needed there. Dropping it removes roughly 8–10 requests per module (the jar, its signature and their checksums), on the order of 1.5–2k fewer requests per Connector snapshot run. It also skips the javadoc generation, which saves build time.

Further notes

  • The convention calls configureBasedOnAppliedPlugins explicitly. The vanniktech plugin would otherwise call it itself after the project is evaluated; that call does nothing once a platform is already configured.
  • Verified on Connector with --include-build, using publishToMavenLocal --dry-run on :core:common:junit-base:
    • 1.0.0-SNAPSHOT: plainJavadocJar is no longer part of the task graph; sourcesJar and test fixtures are still there.
    • 1.0.0: plainJavadocJar is still executed.

Linked Issue(s)

Closes # <-- insert Issue number if one exists

Please be sure to take a look at the contributing guidelines and our etiquette for pull requests.

@ndr-brt
ndr-brt requested a review from a team as a code owner November 13, 2026 09:32
@ndr-brt ndr-brt added the build label Nov 13, 2026
@ndr-brt
ndr-brt merged commit 3bcb9d6 into main Nov 13, 2026
9 of 12 checks passed
@ndr-brt
ndr-brt deleted the fix/skip-javadoc-for-snapshots branch November 13, 2026 09:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants