Conversation
…f the action's execution result and also optimised analystics to execute the application mono concurrently
WalkthroughThis update adds three new constants in the action span definitions to support additional identifiers. It refines the reactive execution in the datasource context service by scheduling blocking calls on a bounded elastic thread. In the action execution solution, the control flow is modified to enhance observability and error handling by integrating new reactive operations, including asynchronous analytics event sending. Changes
Sequence Diagram(s)sequenceDiagram
participant Client as Client
participant DSContext as DatasourceContextServiceCEImpl
participant Config as configService
Client->>DSContext: getRemoteDatasourceContext()
DSContext->>Config: getInstanceId()
Config-->>DSContext: Instance ID
DSContext->>DSContext: subscribeOn(Schedulers.boundedElastic())
DSContext-->>Client: DatasourceContext
sequenceDiagram
participant Client as Client
participant ActionExec as ActionExecutionSolutionCEImpl
participant Analytics as sendExecuteAnalyticsEvent (Async)
Client->>ActionExec: executeAction(...)
ActionExec->>ActionExec: Process reactive chain with map & doOnSuccess
ActionExec-->>Analytics: Trigger analytics event asynchronously
Analytics-->>ActionExec: Event processed
ActionExec-->>Client: ActionExecutionResult
Possibly related PRs
Suggested labels
Suggested reviewers
Poem
Tip ⚡🧪 Multi-step agentic review comment chat (experimental)
📜 Recent review detailsConfiguration used: .coderabbit.yaml 📒 Files selected for processing (3)
⏰ Context from checks skipped due to timeout of 90000ms (5)
🔇 Additional comments (8)
✨ Finishing Touches
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. 🪧 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
Documentation and Community
|
| }); | ||
| return configService | ||
| .getInstanceId() | ||
| .subscribeOn(Schedulers.boundedElastic()) |
There was a problem hiding this comment.
@vsvamsi1 why did you introduced new thread here?
There was a problem hiding this comment.
Because this is a configService.getInstanceId() a db call, Schedulers.boundedElastic() threads are designed blocking/longer execution tasks.
There was a problem hiding this comment.
@NilanshBansal then why here? here as well only datasourceContext getting returned
There was a problem hiding this comment.
@vsvamsi1 we can avoid subscribing this on a scheduler as the ReactiveCrudRepository is already non blocking and handling the database calls. Also, the instanceId is already cached and it is only the first time that a database call is made
cc: @ApekshaBhosale
There was a problem hiding this comment.
@NilanshBansal Cool i will remove the scheduler part of it but can you point me to where the instanceId is cached?
...ith-server/src/main/java/com/appsmith/server/solutions/ce/ActionExecutionSolutionCEImpl.java
Show resolved
Hide resolved
| }); | ||
| return configService | ||
| .getInstanceId() | ||
| .subscribeOn(Schedulers.boundedElastic()) |
There was a problem hiding this comment.
@NilanshBansal then why here? here as well only datasourceContext getting returned
)" This reverts commit 20317c5.
…#39757) ## Description - Pushed out the sendExecuteAnalyticsEvent from the critical path of returning action's execution result. - Improved the critical Path of sendExecuteAnalyticsEvent by running the application mono concurrent to other events. - Added more telemetry code around the execution flow. Fixes #`Issue Number` _or_ Fixes `Issue URL` > [!WARNING] > _If no issue exists, please create an issue first, and check with the maintainers if the issue is valid._ ## Automation /ok-to-test tags="@tag.All" ### 🔍 Cypress test results <!-- This is an auto-generated comment: Cypress test results --> > [!TIP] > 🟢 🟢 🟢 All cypress tests have passed! 🎉 🎉 🎉 > Workflow run: <https://github.com/appsmithorg/appsmith/actions/runs/13919689126> > Commit: ddf93dd > <a href="https://internal.appsmith.com/app/cypress-dashboard/rundetails-65890b3c81d7400d08fa9ee5?branch=master&workflowId=13919689126&attempt=1" target="_blank">Cypress dashboard</a>. > Tags: `@tag.All` > Spec: > <hr>Tue, 18 Mar 2025 10:28:52 UTC <!-- end of auto-generated comment: Cypress test results --> ## Communication Should the DevRel and Marketing teams inform users about this change? - [ ] Yes - [ ] No <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit - **New Features** - Introduced additional action tracking identifiers to support enhanced analytics and authentication validation. - **Refactor** - Optimized asynchronous operations for data retrieval to improve responsiveness. - Enhanced the flow and error handling of action execution, ensuring smoother and more reliable performance. <!-- end of auto-generated comment: release notes by coderabbit.ai -->
Description
Fixes #
Issue Numberor
Fixes
Issue URLWarning
If no issue exists, please create an issue first, and check with the maintainers if the issue is valid.
Automation
/ok-to-test tags="@tag.All"
🔍 Cypress test results
Tip
🟢 🟢 🟢 All cypress tests have passed! 🎉 🎉 🎉
Workflow run: https://github.com/appsmithorg/appsmith/actions/runs/13919689126
Commit: ddf93dd
Cypress dashboard.
Tags:
@tag.AllSpec:
Tue, 18 Mar 2025 10:28:52 UTC
Communication
Should the DevRel and Marketing teams inform users about this change?
Summary by CodeRabbit