Skip to content

chore: scaffold LaunchDarkly Java AI SDK module foundation (AIC-2661)#170

Open
ctawiah wants to merge 3 commits into
mainfrom
feat/AIC-2661/ai-sdk-module-foundation
Open

chore: scaffold LaunchDarkly Java AI SDK module foundation (AIC-2661)#170
ctawiah wants to merge 3 commits into
mainfrom
feat/AIC-2661/ai-sdk-module-foundation

Conversation

@ctawiah
Copy link
Copy Markdown

@ctawiah ctawiah commented Jun 4, 2026

Requirements

  • I have added test coverage for new or changed functionality
  • I have followed the repository's pull request submission guidelines
  • I have validated my changes against all supported platform versions

Note on test coverage: this is the foundation step (AIC-2661) and intentionally ships no SDK behavior, so there is nothing to unit test yet. The module is validated by ./gradlew build (compile + checkstyle + javadoc + jacoco) and ./gradlew publishToMavenLocal. Test coverage begins in Step 2 (AIC-2662). Validated locally on Temurin/OpenJDK 17; CI exercises the full JDK 8/11/17 matrix.

Related issues

Describe the solution you've provided

Stands up the new lib/sdk/server-ai Gradle module from scratch with the same build, quality-gate, and release machinery as sibling modules (lib/sdk/server, lib/java-server-sdk-otel, lib/java-server-sdk-redis-store), so every later step in the epic lands on a solid, CI-enforced base.

  • Module setup: build.gradle (java-library, Java 8 source/target), settings.gradle, gradle.properties (release-please version=0.1.0 markers), checkstyle.xml, .gitignore, .gitattributes, CHANGELOG.md, README.md, Gradle wrapper, and a documented package-info.java.
  • Dependencies: api 'com.launchdarkly:launchdarkly-java-server-sdk:7.14.0' (it appears in the public signature via LDClientInterface). A Mustache templating dependency is not added in this PR — it will be introduced in a later step (AIC-2662) once its audit (license / maintenance / transitive deps) is complete. The published POM therefore declares only the base SDK dependency.
  • Quality gates: checkstyle + jacoco, matching the actual repo standard. Signing is skipped for local/CI builds via LD_SKIP_SIGNING.
  • Internal-visibility convention: non-API code will live under com.launchdarkly.sdk.server.ai.internal, which is excluded from the published Javadoc and sources jars (configured in build.gradle, documented in README.md / package-info.java).
  • CI: .github/workflows/java-server-sdk-ai.yml runs the shared CI composite over a JDK 8 / 11 / 17 matrix.
  • Release: registered in .release-please-manifest.json (0.1.0) and release-please-config.json (launchdarkly-java-server-sdk-ai, extra-files: [gradle.properties]).

Verified locally: ./gradlew clean build → BUILD SUCCESSFUL; ./gradlew publishToMavenLocalcom.launchdarkly:launchdarkly-java-server-sdk-ai:0.1.0 (jar/sources/javadoc/pom).

Describe alternatives you've considered

  • Module placement: placed under lib/sdk/ next to the core SDK (lib/sdk/server), mirroring the JS reference layout (packages/sdk/server-ai), rather than the flat lib/java-server-sdk-* add-on pattern used by the otel/redis integrations.
  • Quality gates: the ticket text mentioned error-prone/spotbugs, but no sibling module enforces them; aligned with the repo standard (checkstyle + jacoco) instead to avoid inconsistent CI friction.
  • CI scope: siblings run Java 8 only; opted for an 8/11/17 matrix to match the ticket's intent and genuinely test forward compatibility.

Additional context

  • This is the first of six PRs in the epic. No SDK behavior is implemented here — data model, client, tracker, and evaluation land in AIC-2662 through AIC-2666.
  • The Mustache dependency and its audit are deferred to AIC-2662.
  • javadoc { failOnError = false } is a temporary shim because an otherwise-empty module trips javadoc's "no classes to document" error; there is a TODO(AIC-2662) to restore failOnError = true once the first public types land.

Note

Low Risk
Infrastructure-only scaffolding with no product logic; only adds a new publishable module and CI/release wiring.

Overview
Adds a new lib/sdk/server-ai Gradle module for launchdarkly-java-server-sdk-ai (v0.1.0) as the foundation for the Server-Side AI SDK—no AI Config APIs or runtime behavior yet, only package-info.java under com.launchdarkly.sdk.server.ai.

The build mirrors sibling libraries: Java 8 target, api dependency on launchdarkly-java-server-sdk:7.14.0, checkstyle/jacoco, Maven publish/signing (with LD_SKIP_SIGNING), and exclusion of com.launchdarkly.sdk.server.ai.internal from published Javadoc/sources. Javadoc failOnError is temporarily disabled until public types land.

CI is wired via .github/workflows/java-server-sdk-ai.yml, running the shared composite action against lib/sdk/server-ai on a JDK 8 / 11 / 17 matrix. Release Please entries were added in .release-please-manifest.json and release-please-config.json.

Reviewed by Cursor Bugbot for commit 1800281. Bugbot is set up for automated code reviews on this repo. Configure here.

ctawiah and others added 2 commits June 4, 2026 12:05
Stand up the new lib/java-server-sdk-ai Gradle module with the same build,
quality-gate, and release machinery as sibling modules, so later steps land
on a CI-enforced base. No SDK behavior yet.

- java-library module, Java 8 source/target, checkstyle + jacoco quality gates
- api dependency on launchdarkly-java-server-sdk; jmustache for interpolation
- internal package excluded from published Javadoc/sources jars
- CI workflow over JDK 8/11/17 matrix via shared composite action
- registered in release-please manifest/config at 0.1.0

jmustache audit: com.samskivert:jmustache:1.16, BSD 2-Clause, no transitive
runtime deps, actively maintained -> approved.

Co-authored-by: Cursor <cursoragent@cursor.com>
Place the module under lib/sdk/ alongside the core SDK (lib/sdk/server),
mirroring the JS reference layout (packages/sdk/server-ai), instead of the
flat lib/java-server-sdk-* add-on pattern. Maven coordinates are unchanged
(com.launchdarkly:launchdarkly-java-server-sdk-ai). Updates CI workspace_path
and release-please manifest/config keys to the new path.

Co-authored-by: Cursor <cursoragent@cursor.com>
@ctawiah ctawiah changed the title feat: scaffold LaunchDarkly Java AI SDK module foundation (AIC-2661) chore: scaffold LaunchDarkly Java AI SDK module foundation (AIC-2661) Jun 4, 2026
Remove the Mustache templating dependency from the foundation module. It will
be added in a later step (AIC-2662) once the license / maintenance / transitive
-dependency audit is complete. The module's published POM now declares only the
base SDK dependency.

Co-authored-by: Cursor <cursoragent@cursor.com>
@ctawiah ctawiah marked this pull request as ready for review June 4, 2026 19:55
@ctawiah ctawiah requested a review from a team as a code owner June 4, 2026 19:55
Copy link
Copy Markdown

@cursor cursor Bot left a comment

Choose a reason for hiding this comment

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

Cursor Bugbot has reviewed your changes using default effort and found 1 potential issue.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, have a team admin enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit 1800281. Configure here.

"extra-files": [
"gradle.properties"
]
},
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Release Please publish job missing

Medium Severity

This change registers lib/sdk/server-ai in release-please, but release-please.yml has no output for lib/sdk/server-ai--release_created and no full-release job targeting lib/sdk/server-ai. When release-please marks a release for this component, nothing will publish the artifact to Sonatype/Maven Central.

Additional Locations (1)
Fix in Cursor Fix in Web

Reviewed by Cursor Bugbot for commit 1800281. Configure here.

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