Skip to content

fix: we need to publish all three modules#382

Open
mkleene wants to merge 7 commits into
mainfrom
publish-all-modules
Open

fix: we need to publish all three modules#382
mkleene wants to merge 7 commits into
mainfrom
publish-all-modules

Conversation

@mkleene

@mkleene mkleene commented Jun 23, 2026

Copy link
Copy Markdown
Contributor
  • add artifacts necessary for publishing to sdk-fips-bc and sdk-pqc-bc
    • also clean up boilerplate
  • two consistency changes
    • rename sdk-fips-bouncycastle to sdk-fips-bc (this should be ok since we haven't succeeded in publishing since this module was created)
    • don't exclude the sdk-pqc-bc jar when using the FIPS profile. the provider modules need only be included/excluded by their consumers

Summary by CodeRabbit

Summary by CodeRabbit

  • New Features

    • Source code archives are now distributed with releases
    • Javadoc documentation is now included with release artifacts
    • Integrity checksums (MD5, SHA-1, SHA-256, SHA-512) are now generated for all JARs
    • Release builds now include the PQC BC module
  • Chores

    • Updated FIPS BC artifact/module naming from sdk-fips-bouncycastle to sdk-fips-bc across release and related documentation/messages

@mkleene mkleene requested review from a team as code owners June 23, 2026 15:25
@coderabbitai

coderabbitai Bot commented Jun 23, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

📝 Walkthrough

Walkthrough

The root pom.xml gains a pluginManagement block centralizing maven-source-plugin, dokka-maven-plugin, and checksum-maven-plugin configuration. Inline plugin config is removed from sdk/pom.xml. The sdk-fips-bc module is renamed from sdk-fips-bouncycastle with new build blocks added to both sdk-fips-bc and sdk-pqc-bc. A new fips profile is introduced, and module references are updated across profiles, dependencies, workflows, and documentation.

Changes

Maven Publishing Plugin Centralization and Module Renaming

Layer / File(s) Summary
Root pluginManagement: source, Dokka, and checksum plugins
pom.xml
Adds maven-source-plugin (attach-sources), dokka-maven-plugin (Javadoc JAR at package), and checksum-maven-plugin (MD5/SHA-1/SHA-256/SHA-512 for *.jar, failOnError) to the root pluginManagement block.
Remove inline plugin config from sdk/pom.xml
sdk/pom.xml
Removes the explicit maven-source-plugin version and attach-sources execution, and the detailed checksum-maven-plugin version and create-checksums execution, deferring to the new centralized declarations.
Add build blocks to sdk-fips-bc and sdk-pqc-bc
sdk-fips-bc/pom.xml, sdk-pqc-bc/pom.xml
Renames artifactId from sdk-fips-bouncycastle to sdk-fips-bc in sdk-fips-bc/pom.xml; adds <build> sections with maven-source-plugin, dokka-maven-plugin, and checksum-maven-plugin to both modules.
Update develop, fips, and release profile module lists
pom.xml
Introduces a fips profile that activates by default and includes only sdk-fips-bc; removes sdk-fips-bouncycastle from the develop profile; replaces the single sdk-fips-bouncycastle entry with sdk-pqc-bc and sdk-fips-bc in the release profile.
Propagate module name changes through dependencies and workflows
sdk/pom.xml, cmdline/pom.xml, .github/workflows/checks.yaml
Updates the FIPS test dependency in sdk/pom.xml surefire plugin, the fips profile runtime dependency in cmdline/pom.xml, and the GitHub workflow FIPS test setup to reference sdk-fips-bc instead of sdk-fips-bouncycastle.
Update documentation and error messages for sdk-fips-bc
sdk/src/main/java/io/opentdf/platform/sdk/ECKeyPair.java, sdk/src/main/java/io/opentdf/platform/sdk/HkdfProvider.java, sdk/src/test/java/io/opentdf/platform/sdk/ECKeyPairTest.java, sdk/src/test/java/io/opentdf/platform/sdk/FipsProviderVerificationTest.java
Updates Javadoc references and error/assertion message strings to reference sdk-fips-bc instead of sdk-fips-bouncycastle for FIPS-approved provider guidance and runtime classpath requirements.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~12 minutes

Possibly related PRs

  • opentdf/java-sdk#367: Both PRs touch the FIPS/non-FIPS build setup around Bouncy Castle (e.g., updating .github/workflows/checks.yaml and the fips-profile classpath/dependencies in sdk/pom.xml, plus references in ECKeyPair), so this PR's sdk-fips-bc rename changes are directly connected to that PR's broader FIPS-library cleanup.
  • opentdf/java-sdk#375: This PR is a follow-up to the FIPS "approved_only" work by renaming the FIPS HKDF module/artifact from sdk-fips-bouncycastle to sdk-fips-bc and updating the corresponding workflow/config and FIPS-related tests/assertion messages (e.g., checks.yaml, cmdline/pom.xml, FipsProviderVerificationTest, ECKeyPairTest, and ECKeyPair/HkdfProvider Javadocs).
  • opentdf/java-sdk#379: This PR's pom.xml release-profile reactor logic changes which FIPS module is built/published (replacing sdk-fips-bouncycastle with sdk-pqc-bc and sdk-fips-bc), which directly overlaps with PR #379's pom.xml release profile modifications.

Suggested reviewers

  • marythought
  • sujankota

Poem

🐇 Hop hop, the artifacts align,
Sources and checksums, oh so fine!
FIPS-BC renamed, PQC joins the pack,
No stray bouncycastle left in the stack.
The rabbit seals JARs with SHA-512 delight~ 🎉

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 33.33% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Title check ✅ Passed The title accurately reflects the main objective—consolidating publishing configuration to enable all three modules to be published. It directly aligns with the core changes in the PR.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch publish-all-modules

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Code Review

This pull request centralizes the configuration of several Maven plugins (maven-source-plugin, dokka-maven-plugin, and checksum-maven-plugin) into the parent pom.xml under plugin management, simplifying the child POMs. It also renames the module sdk-fips-bouncycastle to sdk-fips-bc and adds sdk-pqc-bc to the release profile. One issue was identified where the tag in sdk-fips-bc/pom.xml still references the old artifact name and should be updated for consistency.

Important

The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.

Comment thread sdk-fips-bc/pom.xml
@github-actions

Copy link
Copy Markdown
Contributor

X-Test Failure Report

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@pom.xml`:
- Line 351: The module rename from sdk-fips-bouncycastle to sdk-fips-bc in the
reactor modules is incomplete. Update all downstream dependency references in
cmdline/pom.xml that still use the artifact ID
io.opentdf.platform:sdk-fips-bouncycastle to reference the renamed artifact ID
sdk-fips-bc instead, ensuring consistent naming across all pom.xml files and
preventing dependency resolution failures.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 79f41870-4fd7-40e0-bfdf-be96494ce0f4

📥 Commits

Reviewing files that changed from the base of the PR and between 787039c and 8083768.

📒 Files selected for processing (7)
  • pom.xml
  • sdk-fips-bc/pom.xml
  • sdk-fips-bc/src/main/java/io/opentdf/platform/sdk/fips/bouncycastle/BouncyCastleFipsHkdfProvider.java
  • sdk-fips-bc/src/main/resources/META-INF/services/io.opentdf.platform.sdk.HkdfProvider
  • sdk-fips-bc/src/test/java/io/opentdf/platform/sdk/fips/bouncycastle/BouncyCastleFipsHkdfProviderTest.java
  • sdk-pqc-bc/pom.xml
  • sdk/pom.xml
💤 Files with no reviewable changes (1)
  • sdk/pom.xml

Comment thread pom.xml Outdated
@github-actions

Copy link
Copy Markdown
Contributor

@github-actions

Copy link
Copy Markdown
Contributor

X-Test Failure Report

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@pom.xml`:
- Around line 372-377: The fips profile in the pom.xml file is configured with
activeByDefault set to true, which conflicts with its documented intent to be
opt-in. Remove the activeByDefault element (currently set to true at line 376)
from the fips profile activation block to allow users to selectively enable FIPS
behavior only when explicitly requested, rather than having it activate
unconditionally by default.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 64bd2d34-0825-46a1-8656-da3e58bb0668

📥 Commits

Reviewing files that changed from the base of the PR and between 8083768 and 585cb16.

📒 Files selected for processing (9)
  • .github/workflows/checks.yaml
  • cmdline/pom.xml
  • pom.xml
  • sdk-fips-bc/pom.xml
  • sdk/pom.xml
  • sdk/src/main/java/io/opentdf/platform/sdk/ECKeyPair.java
  • sdk/src/main/java/io/opentdf/platform/sdk/HkdfProvider.java
  • sdk/src/test/java/io/opentdf/platform/sdk/ECKeyPairTest.java
  • sdk/src/test/java/io/opentdf/platform/sdk/FipsProviderVerificationTest.java
✅ Files skipped from review due to trivial changes (4)
  • sdk/src/test/java/io/opentdf/platform/sdk/ECKeyPairTest.java
  • sdk/src/main/java/io/opentdf/platform/sdk/HkdfProvider.java
  • sdk/src/test/java/io/opentdf/platform/sdk/FipsProviderVerificationTest.java
  • sdk/src/main/java/io/opentdf/platform/sdk/ECKeyPair.java
🚧 Files skipped from review as they are similar to previous changes (1)
  • sdk-fips-bc/pom.xml

Comment thread pom.xml Outdated
Comment on lines +372 to +377
<profile>
<!-- only include the FIPS implementations of things if using the FIPS profile -->
<id>fips</id>
<activation>
<activeByDefault>true</activeByDefault>
</activation>

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🎯 Functional Correctness | 🟠 Major

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
set -euo pipefail

python - <<'PY'
import xml.etree.ElementTree as ET

ns = {"m": "http://maven.apache.org/POM/4.0.0"}
root = ET.parse("pom.xml").getroot()

print("activeByDefault profiles in pom.xml:")
for profile in root.findall("./m:profiles/m:profile", ns):
    pid = profile.findtext("m:id", default="", namespaces=ns)
    abd = profile.findtext("m:activation/m:activeByDefault", default="false", namespaces=ns).strip().lower() == "true"
    if abd:
        modules = [m.text for m in profile.findall("./m:modules/m:module", ns)]
        print(f"- {pid}: {modules}")
PY

Repository: opentdf/java-sdk

Length of output: 284


fips profile is configured as default-active, which conflicts with opt-in intent.

The profile at lines 373–377 is documented as "only include the FIPS implementations of things if using the FIPS profile," but activeByDefault>true</activeByDefault> (line 376) makes it active unconditionally. Combined with develop and non-fips also being default-active, this prevents users from selecting FIPS behavior independently—all three profiles activate automatically, breaking selective opt-in control.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@pom.xml` around lines 372 - 377, The fips profile in the pom.xml file is
configured with activeByDefault set to true, which conflicts with its documented
intent to be opt-in. Remove the activeByDefault element (currently set to true
at line 376) from the fips profile activation block to allow users to
selectively enable FIPS behavior only when explicitly requested, rather than
having it activate unconditionally by default.

@github-actions

Copy link
Copy Markdown
Contributor

X-Test Failure Report

@sonarqubecloud

Copy link
Copy Markdown

Quality Gate Failed Quality Gate failed

Failed conditions
0.0% Coverage on New Code (required ≥ 33%)

See analysis details on SonarQube Cloud

@github-actions

Copy link
Copy Markdown
Contributor

@github-actions

Copy link
Copy Markdown
Contributor

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