Skip to content

feat: MetadataService + ScriptService, Java 17, Maven Central (v1.1.0) - #6

Merged
edridudi merged 9 commits into
mainfrom
feat/metadata-script-java17
Aug 8, 2026
Merged

edridudi merged 9 commits into
mainfrom
feat/metadata-script-java17

Conversation

@edridudi

@edridudi edridudi commented Aug 7, 2026

Copy link
Copy Markdown
Member

What

Adds MetadataService + ScriptService to the SDK, retargets to Java 17, and configures Maven Central publishing. Version 1.0.4 → 1.1.0.

This is Layer 2 of adding a Nexus provider to cardano-client-lib (bloxbean). L3 (the bloxbean backend-modules/nexus module) wraps this SDK to implement bloxbean's MetadataService/ScriptService — hence the two new verticals + the Java 17 retarget (cardano-client-lib's baseline) + Maven Central (so L3's Gradle build resolves this without GitHub-Packages auth).

Services (mirror the existing transaction vertical exactly)

MetadataService → Nexus metadata endpoints (Gero-Labs/nexus#772):

  • getTxMetadata / getTxMetadataCbor → GET api/transactions/{txHash}/metadata[/cbor]
  • getMetadataLabels → GET api/metadata/txs/labels
  • getMetadataByLabel / getMetadataCborByLabel → GET api/metadata/txs/labels/{label}[/cbor]

ScriptService → existing /api/scripts:

  • getScriptByHash → GET api/scripts/{scriptHash}
  • getDatumByHash → GET api/scripts/datum/{datumHash}

Both wired into BackendService (getMetadataService() / getScriptService()).

Build & publish

  • Java 21 → 17 (maven.compiler.release=17, bytecode major 61); build.yml JDK 17.
  • Maven Central: Apache-2.0 LICENSE, POM metadata (url/licenses/developers/scm), a profile-isolated release build (central-publishing 0.11.0 + gpg/source/javadoc — normal mvn test needs no GPG), publish.yml Central flow, README runbook. Coordinates io.github.gero-labs:nexus-java-client:1.1.0.
  • Also added the Lombok annotationProcessorPaths the modern JDK/Maven toolchain requires.

Tests

MockWebServer tests per method (exact request path/query + JSON→model mapping) for all 7 new methods, model round-trip tests, factory wiring, non-2xx error cases. 37 tests green; mvn -Prelease produces main + sources + javadoc jars.

Not in this PR (maintainer steps)

  • The actual Maven Central release is manual: Sonatype token in ~/.m2/settings.xml + GPG key, then mvn -Prelease deploy and Publish in the Central Portal (autoPublish=false). Runbook in the README. The tag-triggered publish.yml needs CENTRAL_TOKEN_* + GPG_* repo secrets configured.
  • L3 (bloxbean module) is a separate follow-up.

Design + plan: docs/superpowers/specs/…metadata-script-design.md, docs/superpowers/plans/…metadata-script.md.

🤖 Generated with Claude Code

dudiedri and others added 9 commits August 7, 2026 20:16
Adds two SDK service verticals wrapping the Nexus metadata endpoints
(Gero-Labs/nexus#772) + existing script/datum endpoints, retargets the
build to Java 17 for cardano-client-lib compatibility, and moves publishing
to Maven Central. Enables the cardano-client-lib Nexus backend module (L3).

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
7-task TDD plan: metadata models + service vertical, script vertical,
BackendService wiring, Java 17 retarget, Maven Central publish config
(LICENSE + POM metadata + release profile + CI + README runbook), final
build/push.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Add MetadataApi/MetadataService/MetadataServiceImpl wrapping the 5
Nexus metadata endpoints, mirroring the transaction vertical. TDD:
MockWebServer path+mapping tests for all 5 methods plus a non-2xx
error case.
Add script vertical (ScriptDetail/Datum models, ScriptApi, ScriptService,
ScriptServiceImpl) wrapping Nexus /api/scripts endpoints, mirroring the
metadata vertical's structure and annotation conventions.
… manual)

Adds Apache-2.0 LICENSE, POM metadata Central requires (name, url,
licenses, developers, scm), and a `release` Maven profile
(central-publishing-maven-plugin 0.11.0, maven-source-plugin 3.4.0,
maven-javadoc-plugin 3.12.0, maven-gpg-plugin 3.2.8) so signing/upload
stay out of the default test/package build. Replaces the GitHub
Packages publish.yml deploy step with the Central flow (server-id
central, GPG import, CENTRAL_TOKEN_* + GPG_* secrets — must be
configured by a maintainer). README documents the release runbook and
drops the GitHub Packages install snippet in favor of plain Central
coordinates.
Remove dead GPG_PASSPHRASE env var (maven-gpg-plugin 3.2.8 only reads
MAVEN_GPG_PASSPHRASE). Restore comment explaining why maven.test.skip=true
is used instead of -DskipTests (drifted test sources shouldn't block releases).
Fill Apache-2.0 LICENSE copyright placeholder: Copyright 2026 Gero Labs.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@edridudi
edridudi merged commit c8eaf4b into main Aug 8, 2026
1 check failed
edridudi pushed a commit that referenced this pull request Aug 8, 2026
The gero-plain self-hosted runner stopped picking up jobs (PR #6 build
queued ~18h). gero-dind is up (nexus prod deploy uses it), and runs the
maven build/test fine. Unblocks CI + the tag-triggered Central publish.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant