temporal-spring-ai: README expansion and default-model-name consolidation#2861
Merged
donald-pinckney merged 9 commits intomasterfrom Apr 24, 2026
Merged
temporal-spring-ai: README expansion and default-model-name consolidation#2861donald-pinckney merged 9 commits intomasterfrom
donald-pinckney merged 9 commits intomasterfrom
Conversation
…eanup Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
…tion Moves the "default" model-name constant from SpringAiPlugin to ChatModelTypes and uses it from both SpringAiPlugin and ChatModelActivityImpl. Removes the duplicate literal in the activity's single-arg constructor (which had drifted — the constant existed but the activity kept its own copy). ChatModelTypes is the logical home: the activity package already imports it, so hosting the constant there avoids the activity → plugin import direction that would otherwise be a package cycle. README gains four new sections: - Migrating from plain Spring AI: a three-row table showing which three substitutions get an existing ChatClient-based service onto Temporal. Matches the integration guide's "easy migration" goal. - Activity options and retry behavior: documents the default timeouts and non-retryable classification, and shows the forModel(name, ActivityOptions) escape hatch for custom knobs. - Known limitations: streaming, defaultToolContext, child-workflow stubs as tools, the media byte[] cap, and the ChatOptions.copy() constraint that affects ChatClient.defaultOptions users. - Observability: pointer to the Temporal Java SDK docs plus a note that TemporalChatClient accepts a Micrometer ObservationRegistry. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Planning scratchpad — not part of the shipped artifact. Removed before merge. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Co-authored-by: Brian Strauch <brian@brianstrauch.com>
Clarified the limitation regarding streaming support in chatClient.
brianstrauch
approved these changes
Apr 23, 2026
…d-naming # Conflicts: # temporal-spring-ai/README.md # temporal-spring-ai/src/main/java/io/temporal/springai/model/ChatModelTypes.java
maciejdudko
approved these changes
Apr 24, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What was changed
"default"model-name constant fromSpringAiPlugin.DEFAULT_MODEL_NAMEtoChatModelTypes.DEFAULT_MODEL_NAMEand replacedChatModelActivityImpl's hard-coded literals with the shared constant.ChatModelTypesis the right home — the activity package already imports it, so this avoids an activity → plugin import direction that would've been a package cycle.ChatClient-based service running on Temporal.forModel(name, ActivityOptions)escape hatch.defaultToolContext, child-workflow stubs as tools, the 1 MiB media byte[] cap, and theChatOptions.copy()constraint that affectsChatClient.defaultOptionsusers.TemporalChatClientaccepts a MicrometerObservationRegistry.Why?
The magic string had already drifted once:
SpringAiPlugin.DEFAULT_MODEL_NAMEexisted butChatModelActivityImplkept its own copy of the literal"default". Consolidating prevents the next drift, and moving it toChatModelTypeskeeps package directions sensible.The README covered quick-start and tool types but left adopters guessing about migration steps, failure modes, and what isn't supported. Each new section answers a question we've seen or anticipate from early users of the plugin.