-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
JNG-6148 Request Parameters Support #232
JNG-6148 Request Parameters Support #232
Conversation
WalkthroughThe changes introduce support for handling request parameters in the dispatching process. A new constant ( Changes
Sequence Diagram(s)sequenceDiagram
participant C as Client
participant D as DefaultDispatcher
participant CTX as Context
participant VP as RequestParametersVariableProvider
participant VR as VariableResolver
C->>D: Initiate operation call with exchange (contains request parameters)
D->>CTX: Check for REQUEST_PARAMETERS_KEY in exchange
D->>CTX: Store request parameters using REQUEST_PARAMETERS_KEY
Note over D,CTX: Request parameters are now available in context
C->>VR: Request variable resolution for "REQUEST"
VR->>VP: Invoke apply("parameterName")
VP->>CTX: Retrieve map using REQUEST_PARAMETERS_KEY
CTX-->>VP: Return request parameters map
VP-->>VR: Return value for parameter
VR-->>C: Return resolved value
Poem
Tip 🌐 Web search-backed reviews and chat
✨ Finishing Touches
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media? 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 3
🧹 Nitpick comments (1)
judo-runtime-core-dispatcher/src/main/java/hu/blackbelt/judo/runtime/core/dispatcher/environment/RequestParametersVariableProvider.java (1)
34-34
: Add type bounds to improve type safety.The generic type
T
is unbounded, which could lead to unsafe type casting. Consider adding bounds to restrict the type parameter.-public class RequestParametersVariableProvider<T> implements Function<String, T> { +public class RequestParametersVariableProvider<T extends String> implements Function<String, T> {
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (4)
judo-runtime-core-dispatcher/src/main/java/hu/blackbelt/judo/runtime/core/dispatcher/DefaultDispatcher.java
(2 hunks)judo-runtime-core-dispatcher/src/main/java/hu/blackbelt/judo/runtime/core/dispatcher/environment/RequestParametersVariableProvider.java
(1 hunks)judo-runtime-core-guice/src/main/java/hu/blackbelt/judo/runtime/core/guice/dispatcher/DefaultVariableResolverProvider.java
(1 hunks)judo-runtime-core-spring/src/main/java/hu/blackbelt/judo/runtime/core/spring/JudoDefaultSpringConfiguration.java
(1 hunks)
🔇 Additional comments (2)
judo-runtime-core-guice/src/main/java/hu/blackbelt/judo/runtime/core/guice/dispatcher/DefaultVariableResolverProvider.java (1)
52-52
: LGTM!The registration of the RequestParametersVariableProvider follows the established pattern and is consistent with other provider registrations.
judo-runtime-core-spring/src/main/java/hu/blackbelt/judo/runtime/core/spring/JudoDefaultSpringConfiguration.java (1)
406-406
: LGTM!The registration of the RequestParametersVariableProvider is consistent with both the Guice implementation and other provider registrations in this file.
JNG-6148 Request Parameters Support