Skip to content

feat(cloud-sdk): Spring AI + LangChain4j auto-instrumentation + Spring Boot starter (Phase 1.8 + 1.9)#1

Merged
sunilp merged 17 commits intomainfrom
feat/cloud-sdk-auto-instrumentation
May 6, 2026
Merged

feat(cloud-sdk): Spring AI + LangChain4j auto-instrumentation + Spring Boot starter (Phase 1.8 + 1.9)#1
sunilp merged 17 commits intomainfrom
feat/cloud-sdk-auto-instrumentation

Conversation

@sunilp
Copy link
Copy Markdown
Member

@sunilp sunilp commented May 6, 2026

Summary

Implements Phase 1.8 + 1.9 of the JamJet Cloud roadmap — drop-in observability for Spring AI and LangChain4j via:

  • jamjet-cloud-sdkJamjetObservationHandler (Spring AI Micrometer hook), JamjetChatModelListener (LangChain4j hook), Span.payload(...) for prompt/response capture, shared FailureModeClassifier.
  • jamjet-cloud-spring-boot-starter (new module) — @AutoConfiguration gated on jamjet.cloud.api-key, registers both instrumentation beans, BPP that reflectively appends listener to ChatLanguageModel beans.
  • Build — GPG signing + Sonatype publish moved to release profile so local mvn verify works without GPG pinentry.
  • Docs — Apache 2.0 LICENSE + README install snippets.
  • Version — bumped to 0.2.0, tagged v0.2.0.

Tests

23/23 passing on mvn verify:

  • jamjet-cloud-sdk: 16 tests (5 existing + 1 Span.payload + 4 FailureModeClassifier + 3 ObservationHandler + 3 ChatModelListener + 1 LangChain4j WireMock E2E)
  • jamjet-cloud-spring-boot-starter: 7 tests (4 AutoConfiguration + 3 BPP)

Deferred

  • Spring AI E2E integration test (Spring AI 1.0.0 GA renamed spring-ai-openai-spring-boot-starterspring-ai-starter-model-openai; needs separate test infra). Unit test (JamjetObservationHandlerTest) covers the handler contract; full E2E will be validated by the Phase 1.10 demo app.

Companion change

Cloud-side cost-calc fallback (so Java/Go/TS SDKs can omit cost_usd) — separate PR in jamjet-cloud repo.

Test plan

  • CI green on mvn verify -B (no GPG required)
  • Spot-check the LangChain4j WireMock test: mvn -pl jamjet-cloud-sdk test -B -Dtest=LangChain4jIntegrationTest
  • Spot-check starter wiring: mvn -pl jamjet-cloud-spring-boot-starter test -B

@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented May 6, 2026

Warning

Rate limit exceeded

@sunilp has exceeded the limit for the number of commits that can be reviewed per hour. Please wait 55 minutes and 52 seconds before requesting another review.

To continue reviewing without waiting, purchase usage credits in the billing tab.

⌛ How to resolve this issue?

After the wait time has elapsed, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

We recommend that you space out your commits to avoid hitting the rate limit.

🚦 How do rate limits work?

CodeRabbit enforces hourly rate limits for each developer per organization.

Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout.

Please see our FAQ for further information.

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 1598d1e9-3fe2-419f-bf6e-76ab96ba374c

📥 Commits

Reviewing files that changed from the base of the PR and between e930f94 and 395a7a3.

📒 Files selected for processing (27)
  • LICENSE
  • README.md
  • jamjet-cloud-sdk/pom.xml
  • jamjet-cloud-sdk/src/main/java/dev/jamjet/cloud/FailureModeClassifier.java
  • jamjet-cloud-sdk/src/main/java/dev/jamjet/cloud/JamjetCloud.java
  • jamjet-cloud-sdk/src/main/java/dev/jamjet/cloud/Span.java
  • jamjet-cloud-sdk/src/main/java/dev/jamjet/cloud/instrumentation/langchain4j/JamjetChatModelListener.java
  • jamjet-cloud-sdk/src/main/java/dev/jamjet/cloud/instrumentation/spring/JamjetObservationHandler.java
  • jamjet-cloud-sdk/src/test/java/dev/jamjet/cloud/FailureModeClassifierTest.java
  • jamjet-cloud-sdk/src/test/java/dev/jamjet/cloud/JamjetCloudTest.java
  • jamjet-cloud-sdk/src/test/java/dev/jamjet/cloud/instrumentation/langchain4j/JamjetChatModelListenerTest.java
  • jamjet-cloud-sdk/src/test/java/dev/jamjet/cloud/instrumentation/langchain4j/LangChain4jIntegrationTest.java
  • jamjet-cloud-sdk/src/test/java/dev/jamjet/cloud/instrumentation/spring/JamjetObservationHandlerTest.java
  • jamjet-cloud-spring-boot-starter/pom.xml
  • jamjet-cloud-spring-boot-starter/src/main/java/dev/jamjet/cloud/spring/ChatModelListenerPostProcessor.java
  • jamjet-cloud-spring-boot-starter/src/main/java/dev/jamjet/cloud/spring/JamjetCloudAutoConfiguration.java
  • jamjet-cloud-spring-boot-starter/src/main/java/dev/jamjet/cloud/spring/JamjetCloudProperties.java
  • jamjet-cloud-spring-boot-starter/src/main/resources/META-INF/spring/org.springframework.boot.autoconfigure.AutoConfiguration.imports
  • jamjet-cloud-spring-boot-starter/src/test/java/dev/jamjet/cloud/spring/ChatModelListenerPostProcessorTest.java
  • jamjet-cloud-spring-boot-starter/src/test/java/dev/jamjet/cloud/spring/JamjetCloudAutoConfigurationTest.java
  • jamjet-runtime-core/pom.xml
  • jamjet-runtime-instrument/pom.xml
  • jamjet-runtime-plugins/pom.xml
  • jamjet-runtime-protocols/pom.xml
  • jamjet-runtime-server/pom.xml
  • jamjet-spring-boot-starter/pom.xml
  • pom.xml
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch feat/cloud-sdk-auto-instrumentation

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 and usage tips.

@sunilp sunilp merged commit ea0b82d into main May 6, 2026
2 checks passed
@sunilp sunilp deleted the feat/cloud-sdk-auto-instrumentation branch May 6, 2026 17:49
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