Skip to content

Commit 63ebb6c

Browse files
authored
ci: wire lib/sdk/server-ai into release and publish workflows (#201)
## Summary Wires `lib/sdk/server-ai` into the repo's release and publish plumbing. Release-please already tracks the module (`release-please-config.json` + `.release-please-manifest.json` at `0.2.0`) and has cut `launchdarkly-java-server-sdk-ai-0.1.0` and `-0.2.0` tags and GitHub Releases — but nothing was listening for the baton afterward, so `.github/actions/full-release` (Publish → Publish Docs) has never run for the module. Consequences today: - `com.launchdarkly:launchdarkly-java-server-sdk-ai` has **zero versions on Maven Central**, despite the module README advertising the coordinate as published. - `https://launchdarkly.github.io/java-core/lib/sdk/server-ai/` returns **404**; `gh-pages` contains `lib/sdk/server`, `lib/shared/*`, `lib/java-server-sdk-otel`, and `lib/java-server-sdk-redis-store` but no `server-ai`. - There was no manual escape hatch either — the module was missing from both `workflow_dispatch` choice lists. This is config-only. No build or source changes are needed: `lib/sdk/server-ai/build.gradle` already applies `maven-publish`, `signing`, and `nexusPublishing`, sets `archivesBaseName = 'launchdarkly-java-server-sdk-ai'`, declares full POM metadata, and produces `withJavadocJar()` / `withSourcesJar()` (both excluding `com.launchdarkly.sdk.server.ai.internal`). ## What changed `.github/workflows/release-please.yml`: - New job output `package-server-sdk-ai-released` from `steps.release.outputs['lib/sdk/server-ai--release_created']`. - New `release-server-sdk-ai` job, identical in shape to the existing per-module release jobs, gated on that output and calling `./.github/actions/full-release` with `workspace_path: lib/sdk/server-ai`, `dry_run: false`, `prerelease: false`. `.github/workflows/manual-publish.yml` and `.github/workflows/manual-publish-docs.yml`: - Added `lib/sdk/server-ai` to the `workspace_path` choice lists so the module can be published — and, importantly, so its Javadoc can be pushed to `gh-pages` — on demand. ## Follow-up (not in this PR) 1. **Backfill the Javadoc site immediately** after merge: dispatch **Publish Docs** with `workspace_path: lib/sdk/server-ai`, `dry_run: false`. `publish-pages` writes to `output_path: lib/sdk/server-ai`, and `gh-pages` docs are overwritten in place rather than versioned, so this is safe to run from `main` and makes the GitHub Pages URL work without publishing a jar. 2. **First Central release should be a fresh version, not a back-publish of `0.2.0`.** `main` carries unreleased changes on top of the `0.2.0` tag — including a breaking one (#199, `fix!: Make AgentGraph traversal topological`) — while `gradle.properties` still reads `version=0.2.0`. Merging this PR and letting the open release-please PR cut the next version gets the artifact published from a matching tree. 3. **Docs links** become referenceable once released: `https://launchdarkly.github.io/java-core/lib/sdk/server-ai/` (Javadoc, the analogue of the .NET `launchdarkly.github.io/dotnet-core/pkgs/sdk/server-ai/` page) and `https://central.sonatype.com/artifact/com.launchdarkly/launchdarkly-java-server-sdk-ai` (package page, the analogue of the NuGet listing). ## Verification - [ ] `release-please` workflow parses and the new job appears in the run graph (skipped when no server-ai release is cut). - [ ] **Publish Docs** dispatch offers `lib/sdk/server-ai` and, after running, `gh-pages` contains `lib/sdk/server-ai/index.html` and the Pages URL renders the `LDAIClient` Javadoc. - [ ] After the next release, `https://repo1.maven.org/maven2/com/launchdarkly/launchdarkly-java-server-sdk-ai/maven-metadata.xml` lists the version (allow ~30 min for Central sync) and a scratch Gradle project resolves the coordinate. - [ ] Published sources/javadoc jars exclude `com.launchdarkly.sdk.server.ai.internal` — the build already enforces this, but it's worth confirming on the first artifacts ever produced for real. <!-- CURSOR_SUMMARY --> --- > [!NOTE] > <sup>[Cursor Bugbot](https://cursor.com/bugbot) is generating a summary for commit eab1c4d. Configure [here](https://www.cursor.com/dashboard/bugbot).</sup> <!-- /CURSOR_SUMMARY -->
1 parent a100712 commit 63ebb6c

3 files changed

Lines changed: 36 additions & 0 deletions

File tree

‎.github/workflows/manual-publish-docs.yml‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ on:
1010
- lib/shared/internal
1111
- lib/shared/test-helpers
1212
- lib/sdk/server
13+
- lib/sdk/server-ai
1314
- lib/java-server-sdk-otel
1415
- lib/java-server-sdk-redis-store
1516
dry_run:

‎.github/workflows/manual-publish.yml‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ on:
1111
- lib/shared/internal
1212
- lib/shared/test-helpers
1313
- lib/sdk/server
14+
- lib/sdk/server-ai
1415
- lib/java-server-sdk-otel
1516
- lib/java-server-sdk-redis-store
1617
prerelease:

‎.github/workflows/release-please.yml‎

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ jobs:
1717
package-sdk-internal-released: ${{ steps.release.outputs['lib/shared/internal--release_created'] }}
1818
package-test-helpers-released: ${{ steps.release.outputs['lib/shared/test-helpers--release_created'] }}
1919
package-server-sdk-released: ${{ steps.release.outputs['lib/sdk/server--release_created'] }}
20+
package-server-sdk-ai-released: ${{ steps.release.outputs['lib/sdk/server-ai--release_created'] }}
2021
package-server-sdk-otel-released: ${{ steps.release.outputs['lib/java-server-sdk-otel--release_created'] }}
2122
package-server-sdk-redis-store-released: ${{ steps.release.outputs['lib/java-server-sdk-redis-store--release_created'] }}
2223

@@ -60,6 +61,39 @@ jobs:
6061
aws_role: ${{ vars.AWS_ROLE_ARN }}
6162
token: ${{ secrets.GITHUB_TOKEN }}
6263

64+
release-server-sdk-ai:
65+
runs-on: ubuntu-latest
66+
needs: release-please
67+
permissions:
68+
id-token: write
69+
contents: write
70+
pull-requests: write
71+
if: ${{ needs.release-please.outputs.package-server-sdk-ai-released == 'true'}}
72+
steps:
73+
- uses: actions/checkout@v4
74+
75+
- uses: launchdarkly/gh-actions/actions/release-secrets@release-secrets-v1.1.0
76+
name: Get secrets
77+
with:
78+
aws_assume_role: ${{ vars.AWS_ROLE_ARN }}
79+
ssm_parameter_pairs: '/production/common/releasing/sonatype/central/username = SONATYPE_USER_NAME,
80+
/production/common/releasing/sonatype/central/password = SONATYPE_PASSWORD,
81+
/production/common/releasing/java/keyId = SIGNING_KEY_ID'
82+
s3_path_pairs: 'launchdarkly-releaser/java/code-signing-keyring.gpg = code-signing-keyring.gpg'
83+
84+
- uses: ./.github/actions/full-release
85+
with:
86+
workspace_path: lib/sdk/server-ai
87+
dry_run: false
88+
prerelease: false
89+
code_signing_keyring: ${{ github.workspace }}/code-signing-keyring.gpg
90+
signing_key_id: ${{ env.SIGNING_KEY_ID }}
91+
signing_key_passphrase: ''
92+
sonatype_username: ${{ env.SONATYPE_USER_NAME }}
93+
sonatype_password: ${{ env.SONATYPE_PASSWORD }}
94+
aws_role: ${{ vars.AWS_ROLE_ARN }}
95+
token: ${{ secrets.GITHUB_TOKEN }}
96+
6397
release-server-sdk-otel:
6498
runs-on: ubuntu-latest
6599
needs: release-please

0 commit comments

Comments
 (0)