-
Notifications
You must be signed in to change notification settings - Fork 3.7k
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
fix: updated the max connection pool size and datasourceDestroy method #36631
Conversation
WalkthroughThe pull request introduces modifications to the Changes
Assessment against linked issues
Possibly related PRs
Suggested labels
Suggested reviewers
Poem
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
Documentation and Community
|
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: 1
🧹 Outside diff range and nitpick comments (1)
app/server/appsmith-plugins/mysqlPlugin/src/main/java/com/external/plugins/MySqlPlugin.java (1)
695-695
: Class, pay attention to this important change!The modification in the
datasourceDestroy
method is a significant improvement in how we handle the SSH tunnel thread. Instead of using the deprecatedstop()
method, we're now usinginterrupt()
. This is a much safer way to terminate a thread.Let's break it down:
- The old way (
stop()
) was like abruptly unplugging a computer - it could leave things in an inconsistent state.- The new way (
interrupt()
) is like politely asking the thread to finish up its work - it's safer and allows for proper cleanup.This change aligns with best practices in concurrent programming. Well done! However, remember that the thread should be designed to respond to interrupts for this to work effectively.
As a follow-up, consider reviewing the implementation of the SSH tunnel thread to ensure it properly handles interrupts. This might involve checking for
Thread.interrupted()
in any long-running operations within the thread.
📜 Review details
Configuration used: .coderabbit.yaml
Review profile: CHILL
📒 Files selected for processing (2)
- app/server/appsmith-plugins/mysqlPlugin/src/main/java/com/external/plugins/MySqlPlugin.java (1 hunks)
- app/server/appsmith-plugins/mysqlPlugin/src/main/java/com/external/utils/MySqlDatasourceUtils.java (1 hunks)
...rver/appsmith-plugins/mysqlPlugin/src/main/java/com/external/utils/MySqlDatasourceUtils.java
Show resolved
Hide resolved
This comment was marked as outdated.
This comment was marked as outdated.
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: 1
📜 Review details
Configuration used: .coderabbit.yaml
Review profile: CHILL
📒 Files selected for processing (1)
- app/server/appsmith-server/src/test/java/com/appsmith/server/connectionpoolconfig/configurations/ConnectionPoolConfigCETest.java (1 hunks)
...java/com/appsmith/server/connectionpoolconfig/configurations/ConnectionPoolConfigCETest.java
Show resolved
Hide resolved
This comment was marked as outdated.
This comment was marked as outdated.
app/server/appsmith-plugins/mysqlPlugin/src/main/java/com/external/plugins/MySqlPlugin.java
Show resolved
Hide resolved
...rver/appsmith-plugins/mysqlPlugin/src/main/java/com/external/utils/MySqlDatasourceUtils.java
Show resolved
Hide resolved
@NilanshBansal Are there any test cases that I need to test on DP? |
/build-deploy-preview skip-tests=true |
Deploying Your Preview: https://github.com/appsmithorg/appsmith/actions/runs/11125505971. |
Deploy-Preview-URL: https://ce-36631.dp.appsmith.com |
@sneha122 @manish535 please check the performance of the same application when imported in appsmith production VS the DP (containing these changes). It is very evident that the above change fixes the problem at hand and improves the performance of the application thereby ensuring early release of memory. Screen.Recording.2024-10-01.at.7.00.05.PM.mov |
@sneha122 I have already verified this on the DP compared with Appsmith prod as of now. We don't need any more testing on this. |
The PR looks good to go! waiting for the Cypress to pass |
The failing test is unrelated to the changes in this PR, it is also failing in an empty commit PR. Ref: #36637 Hence updating the Tag to let the cypress pass |
Description
Fixes #34028
Automation
/ok-to-test tags="@tag.Datasource"
🔍 Cypress test results
Tip
🟢 🟢 🟢 All cypress tests have passed! 🎉 🎉 🎉
Workflow run: https://github.com/appsmithorg/appsmith/actions/runs/11129233985
Commit: 04617ce
Cypress dashboard.
Tags:
@tag.Datasource
Spec:
Tue, 01 Oct 2024 16:44:48 UTC
Communication
Should the DevRel and Marketing teams inform users about this change?
Summary by CodeRabbit
New Features
Bug Fixes