Commit Graph

201 Commits

Author SHA1 Message Date
Ankita Kinger
2f7e4e5c96
chore: Updating the copy in the action settings pane (#37260)
## Description

Updating the copy in the action settings pane

Fixes [#37258](https://github.com/appsmithorg/appsmith/issues/37258)

## 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/11704084082>
> Commit: 723332f1a22047bbda149e5d77f9e4ddb0b84d3e
> <a
href="https://internal.appsmith.com/app/cypress-dashboard/rundetails-65890b3c81d7400d08fa9ee5?branch=master&workflowId=11704084082&attempt=2"
target="_blank">Cypress dashboard</a>.
> Tags: `@tag.All`
> Spec:
> <hr>Wed, 06 Nov 2024 15:09:44 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

## Release Notes

- **New Features**
- Enhanced testing coverage for promise handling in the Cypress
environment, improving validation of asynchronous operations.

- **Bug Fixes**
  - Updated labels in the settings tab of the query editor for clarity.
- Improved label consistency across various plugins and settings
configurations.

- **Documentation**
- Updated messaging in the `SettingsPopover` component for better user
guidance.

- **Chores**
- Standardized phrasing in multiple configuration files to enhance user
understanding across the application.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2024-11-07 00:20:52 +05:30
Hetu Nandu
ee02c0f17e
chore: Query Editor full width option (#37138) 2024-10-31 15:20:48 +05:30
Ankita Kinger
faed301e32
chore: Moving action settings from editor form to toolbar (#36894)
## Description

Moving action settings from editor form to toolbar to follow the new
designs under action redesign project.

Fixes [#35512](https://github.com/appsmithorg/appsmith/issues/35512)
[#34670](https://github.com/appsmithorg/appsmith/issues/34670)
[#35535](https://github.com/appsmithorg/appsmith/issues/35535)

## Automation

/ok-to-test tags="@tag.Sanity"

### 🔍 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/11384449381>
> Commit: 027e2a33685e50c2cb16e513993fff62b0d62e08
> <a
href="https://internal.appsmith.com/app/cypress-dashboard/rundetails-65890b3c81d7400d08fa9ee5?branch=master&workflowId=11384449381&attempt=1"
target="_blank">Cypress dashboard</a>.
> Tags: `@tag.Sanity`
> Spec:
> <hr>Thu, 17 Oct 2024 12:40:29 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

## Summary by CodeRabbit

## Release Notes

- **New Features**
- Introduced new components for managing API and query settings in the
Plugin Action Settings.
- Added functionality to open plugin action settings directly from the
toolbar.
- Implemented a settings popover interface for improved user
interaction.
- Added documentation links for QUERY_SETTINGS to enhance user guidance.

- **Improvements**
- Simplified rendering logic in the Plugin Action Form for better
performance.
- Updated form naming conventions for consistency across API and GraphQL
editors.
- Streamlined configuration settings by replacing `subtitle` with
`tooltipText` for clarity.
- Enhanced styling in Action Settings for better layout and user
experience.

- **Bug Fixes**
- Corrected the navigation logic to open plugin action settings instead
of debugger state.

These enhancements aim to improve user experience and streamline plugin
action management.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2024-10-18 11:18:08 +05:30
Anna Hariprasad
7aae152dee
fix: logger-not-working-in-plugins (#36231)
Fixes #36073 

Hi @NilanshBansal 

**Issue :**

**Missing Logging Implementation :**

- Without a logging implementation (such as SLF4J Simple or Logback) in
the project's classpath, the logging statements in the plugins cannot be
executed.
- As a result, no log output is being printed to the terminal.

**Solution :**

The solution is to add a logging implementation to the plugins parent
pom. In this case, you can add the slf4j-simple dependency to your
pom.xml file. This will provide a simple logging implementation that
will output log statements to the console.

```
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-api</artifactId>
<version>1.7.36</version>
</dependency>

<dependency>
    <groupId>org.slf4j</groupId>
    <artifactId>slf4j-simple</artifactId>
    <version>1.7.36</version> 
</dependency>
```
**Explanation:**

- slf4j-api provides the SLF4J API, which is the interface for logging.
  provides the SLF4J API, which is the interface for logging.
- slf4j-simple provides a simple implementation of the SLF4J API, which
is responsible for actually printing the log messages to the console.

**Screenshots :** 

Amazon S3 Plugin and Postgres Plugin 

![image](https://github.com/user-attachments/assets/d3e90b96-2b02-493d-8ffa-44e2aa348fc1)


<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

## Summary by CodeRabbit

- **New Features**
- Enhanced logging capabilities with the integration of SLF4J API and
SLF4J Simple implementations.

- **Improvements**
- Improved log management and output formatting for better monitoring
and debugging across various plugins, transitioning from standard output
to structured logging.
- Refined logging practices in multiple plugins to support better
maintainability and performance.
- Removed method for console logging from the Stopwatch class to
streamline logging practices.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2024-09-17 10:47:58 +01:00
albinAppsmith
66c815f1cb
feat: Migrate DBform to UQI config (#36168)
## Description

This PR migrates the plugins which were old DBForm config to UQI config.
Plugins that got affected,
1. Snowflake
2. ArangoDB
3. Oracle
4. PostgreSQL
5. MySQL
6. Elasticsearch
7. DynamoDB
8. Redis
9. MSSQL
10. Redshift


Fixes #35496
Fixes #35497
Fixes #35500
Fixes #35487 
Fixes #35490 
Fixes #35491
Fixes #35499
Fixes #35501 
Fixes #35502
Fixes #35506 
Fixes #35890

## Automation

/ok-to-test tags="@tag.Datasource"

### 🔍 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/10897087023>
> Commit: e8fe475a48aac1e2e1f3184181ae0bed154313ba
> <a
href="https://internal.appsmith.com/app/cypress-dashboard/rundetails-65890b3c81d7400d08fa9ee5?branch=master&workflowId=10897087023&attempt=1"
target="_blank">Cypress dashboard</a>.
> Tags: `@tag.Datasource`
> Spec:
> <hr>Tue, 17 Sep 2024 06:07:27 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**
- Enhanced rendering logic in the Query Editor to support additional UI
component types.
- Improved handling of form evaluations and query configurations across
various plugins, including ArangoDB, DynamoDB, Elasticsearch, and
others.
- Introduced structured layouts for editor configurations, enhancing
clarity and usability in multiple database plugins.

- **Bug Fixes**
- Adjusted control flow in sagas to ensure proper handling of UI
component types, improving user interactions.

- **Chores**
- Refined JSON configurations across multiple plugins for better
organization and maintainability.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2024-09-17 14:22:32 +05:30
Anna Hariprasad
1cf452fafa
feat: Improved-error-messages-for-postgres-connection (#35167)
Hi @appsmithorg/contributor-support, @rohan-arthur, @nidhi-nair 

Fixes #19723 

**What’s in this PR:**

1. In Postgres Plugin:

- Added two imports: PSQLException and PSQLState to identify the type of
exception and state of error.
- Added a condition to validate the empty port field.
- Removed the default port when the port is empty.
- Removed “Failed to initialize pool:” term in the error message.

2. In PostgresErrorMessages

- Added two constant value for Missing port and invalid host and port.

3. In PostgresPluginTest

- Added a test case to validate the missing port error message.

**Screenshots :**
1. If any of the field like host address, port, DB name etc is wrong -
There is a term in the error message along with the error message in the
toast "Failed to initialize pool: ". This is not required. - Fixed

![image](https://github.com/user-attachments/assets/a54ff455-7297-4356-bf81-656c1130977a)
2. If host address or port is wrong, there is no reference of that in
the error message. - Fixed

![image](https://github.com/user-attachments/assets/c48dabdc-9957-459a-9dde-d4b73960b9e2)
3. There is no error message when the port number is left empty. - Fixed

![image](https://github.com/user-attachments/assets/2c7967c8-b4e1-4bb2-a8e5-14e8022bca29)

**Test cases :**

![image](https://github.com/user-attachments/assets/329a7453-c1ba-4a85-b807-2cdf4569db3e)

**Why I didn’t provide test cases for invalid host and port :**

Those errors are triggered by the createConnectionPool method, which is
private, so we can’t access it in the test file.

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

- **New Features**
- Improved validation for PostgreSQL datasource configurations, ensuring
that a port is specified.
- Enhanced error messaging for connection issues related to missing or
invalid port and hostname.

- **Bug Fixes**
- Refined error handling during connection pool initialization for
clearer feedback on specific connection issues.

- **Tests**
- Added a test to validate behavior when the datasource configuration
has an empty port, improving coverage for validation logic.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2024-09-09 15:22:59 +01:00
Nilansh Bansal
d9a3090a82
Revert "chore: shadow PR for external contribution #ce-35167" (#36202)
Reverts appsmithorg/appsmith#36053

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

- **Bug Fixes**
- Improved formatting of error messages for invalid data sources to
enhance clarity.
- Simplified error handling in the Postgres plugin, which may affect the
specificity of connection error messages.
- Removed an outdated error message related to invalid hostname and port
configurations in the Postgres plugin, impacting how related errors are
reported to users.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2024-09-09 15:19:44 +01:00
Nilansh Bansal
b782bde2ee
chore: shadow PR for external contribution #ce-35167 (#36053)
## Description
- Shadow PR for https://github.com/appsmithorg/appsmith/pull/35167

Fixes #  

> [!WARNING]  
> _If no issue exists, please create an issue first, and check with the
maintainers if the issue is valid._

## Automation

/test 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/10769007798>
> Commit: 3c97f02af5401c84760425557b479b1cff13fdac
> <a
href="https://internal.appsmith.com/app/cypress-dashboard/rundetails-65890b3c81d7400d08fa9ee5?branch=master&workflowId=10769007798&attempt=2"
target="_blank">Cypress dashboard</a>.
> Tags: `@tag.All`
> Spec:
> <hr>Mon, 09 Sep 2024 10:29:27 UTC
<!-- end of auto-generated comment: Cypress test results  -->


## Communication
Should the DevRel and Marketing teams inform users about this change?
- [ ] Yes
- [x] No


<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit


- **New Features**
- Enhanced error handling for PostgreSQL connection issues with clearer
messages for missing ports and invalid hostnames.
- Improved readability of error messages in the application by
formatting them to display on separate lines.

- **Bug Fixes**
- Improved clarity in error reporting for connection pool creation
failures.

- **Tests**
- Introduced a test case to validate datasource configuration when the
port is not provided, ensuring robust validation checks.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->

---------

Co-authored-by: AnnaHariprasad5123 <hariprasad.anna@zemosolabs.com>
2024-09-09 15:06:31 +01:00
Nilansh Bansal
1c14d698f1
chore: added thread logging info for plugins (#36077) 2024-09-05 17:19:57 +05:30
Nilansh Bansal
4516129908
fix: postgres plugin blocking call (#36046)
## Description
This PR resolves the blockhound callout `Blocking call!
java.io.FileInputStream#readBytes` in the /v1/actions/execute (POST) API
call when used with Postgres Plugin.
This blocking call was present in the PostgresPlugin.java

Fixes #36008   

## Automation

/ok-to-test tags="@tag.Sanity"

### 🔍 Cypress test results
<!-- This is an auto-generated comment: Cypress test results  -->
> [!IMPORTANT]
> 🟣 🟣 🟣 Your tests are running.
> Tests running at:
<https://github.com/appsmithorg/appsmith/actions/runs/10666128697>
> Commit: 9224297c20722ebd5b2891e9e2f306f75e78ed1b
> Workflow: `PR Automation test suite`
> Tags: `@tag.Sanity`
> Spec: ``
> <hr>Mon, 02 Sep 2024 11:19:10 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


- **Chores**
- Improved the readability and conciseness of the connection pool
creation logic in the Postgres plugin, enhancing maintainability without
affecting functionality.
- Updated logging level from debug to info for better clarity on log
messages.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2024-09-02 11:45:28 +00:00
Anna Hariprasad
f3374bd5fd
feat: Added SSH Tunnel for Postgres (#35449)
@appsmithorg/contributor-support

Hi @rohan-arthur 

Fixes #30792 

[**Video
Demonstration**](https://drive.google.com/file/d/1IOGlTsPVgeBNOpq3vydO01lrcN10S8ZS/view?usp=sharing)

**What's in this pr :**

- Added connection mode option for SSH Tunnel.
- Added SSH Host, Port, SSH Username and SSH key fields.
- Added Validation logic for SSH fields.
- Added SSH connection logic.
- Added three test cases for SSH connection.

**Screenshots :**

![image](https://github.com/user-attachments/assets/8332a0f7-f184-401d-acea-b46aa07fe759)

![image](https://github.com/user-attachments/assets/37f8b372-5532-4133-8e3e-f41d5ad6e91f)

![image](https://github.com/user-attachments/assets/eee5a119-70e5-4ddb-bf13-8316ab9b160b)

![image](https://github.com/user-attachments/assets/a3cb0d12-9255-4b2e-b2c8-00c98227ca39)

![image](https://github.com/user-attachments/assets/6acd9b7f-f16e-48e4-8dfc-996ef62d2262)

Please review this pr. Let me know if any changes required.





<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

## Summary by CodeRabbit

- **New Features**
- Introduced SSH tunneling support for PostgreSQL connections, allowing
users to configure SSH settings for enhanced security.
- Added a new "Connection method" option in the configuration, enabling
selection between "Standard" and "SSH tunnel" connections, with relevant
fields for SSH details.

- **Bug Fixes**
- Improved error handling by adding specific error messages for missing
SSH configuration parameters, providing clearer feedback to users.
- Updated error messages for authentication issues to include missing
passwords.

- **Tests**
- Enhanced test coverage with new unit tests for validating the
configuration of PostgreSQL data sources, particularly for SSH
connections.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2024-08-29 11:09:08 +01:00
Naveen Goud
cbd7ccc4ec
fix: updated the regex expression to correctly identify the table nam… (#35361)
**Description**

When the user tries to add a postgres datasource and add any query, if
the table name has hyphens in it, then quotes get assigned to first word
after the schema and the dot. For example, public."counter"-with-db
The quotes should be applied to the whole table name. For example:
public."counter-with-db"

Fixes https://github.com/appsmithorg/appsmith/issues/10631
Fixes https://github.com/appsmithorg/appsmith/issues/30692

**changes in PR:**

1.updated the regec expression to idetify the table name properly with
table name consists of hypens.

2.added a test case for this scenario.

**snapshots:**
before:

![Screenshot from 2024-07-30
17-15-27](https://github.com/user-attachments/assets/98f969da-4cf1-4367-be29-1f3465179a9d)

After:

![Screenshot from 2024-08-01
10-46-53](https://github.com/user-attachments/assets/29411eb7-77af-4a10-9988-a0c076043945)


Hi @ajinkyakulkarni @rohan-arthur @Nikhil-Nandagopal ,Please review this
PR.

<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

## Summary by CodeRabbit

- **New Features**
- Enhanced handling of table names in the Postgres plugin to support a
wider variety of characters, including hyphens and special characters.
- Introduced multiple new database tables for improved testing coverage.

- **Bug Fixes**
- Adjusted table name processing to correctly format names containing a
broader range of characters.

- **Tests**
- Added new tests to verify the structure and integrity of tables with
various naming conventions.
	- Expanded existing tests to accommodate additional table structures.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2024-08-27 16:21:12 +05:30
Nilansh Bansal
fe7ca6b98e
chore: added prettier spotless plugin for json files (#35447)
## Description
This PR adds the spotless formatter and validator for the JSON files
present in the project. If there is any invalid JSON file, the formatter
fails and logs the file and the error LOC to be fixed.
It uses the `prettier JSON` formatted in spotless for the same.
Since Spotless is already added to the pre-commit hook it also makes it
necessary to fix the JSON and then commit the changes.

- The prettier JSON formattor preserves the order of the keys.
- Indendation of 2 spaces has been added in the config

Screenshot of the errors displayed for Invalid JSONs
<img width="1427" alt="image"
src="https://github.com/user-attachments/assets/00bbd61c-7414-4787-b9ac-2f0d392f6f33">

### Last attempt to resolve this issue
The formatted used was `simple JSON` which led to change in order of
JSON keys.
PR: https://github.com/appsmithorg/appsmith/pull/35395
Ref:
https://theappsmith.slack.com/archives/CGBPVEJ5C/p1722929754593669?thread_ts=1722916121.682699&cid=CGBPVEJ5C


Fixes #34969 

## 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/10264348935>
> Commit: 4957b647f3d5e0f9853e7f391411b62ee189547b
> <a
href="https://internal.appsmith.com/app/cypress-dashboard/rundetails-65890b3c81d7400d08fa9ee5?branch=master&workflowId=10264348935&attempt=2"
target="_blank">Cypress dashboard</a>.
> Tags: `@tag.All`
> Spec:
> <hr>Tue, 06 Aug 2024 12:40:47 UTC
<!-- end of auto-generated comment: Cypress test results  -->


## Communication
Should the DevRel and Marketing teams inform users about this change?
- [ ] Yes
- [ ] No
2024-08-08 09:16:03 +05:30
Nilansh Bansal
3b3f64f1c0
Revert "chore: added JSON files linting check" (#35445)
Reverts appsmithorg/appsmith#35395
Reverting this PR as the formatter changes the sorting order of the keys
of our JSONs which affects our UI.
Ref:
https://theappsmith.slack.com/archives/CGBPVEJ5C/p1722929754593669?thread_ts=1722916121.682699&cid=CGBPVEJ5C
2024-08-06 14:15:23 +05:30
Nilansh Bansal
486662a2ed
chore: added JSON files linting check (#35395)
## Description
This PR adds the spotless formatter and validator for the JSON files
present in the project. If there is any invalid JSON file, the formatter
fails and logs the file and the error LOC to be fixed.
Since Spotless is already added to the pre-commit hook it also makes it
necessary to fix the JSON and then commit the changes.

Screenshot of the errors displayed for Invalid JSONs

![image](https://github.com/user-attachments/assets/f1661a1e-50a6-4b20-88a5-b7cfe0cc691a)


### Why is this Important?
All of our datasource forms appear on the UI from the JSON configuration
files in the plugins. If an Invalid JSON is added, it can break the
datasource usage experience for the users.
One such instance happened in the past, where due to a JSON formatting
error, the users could not use Smart Substitution feature on production.

[Reference](https://theappsmith.slack.com/archives/C040LHZN03V/p1721124893238579)

Fixes #34969 

## Automation

/ok-to-test tags="@tag.Sanity"

### 🔍 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/10243164292>
> Commit: 08bc87acd2e44c4a2677d3eed1bad002f991050a
> <a
href="https://internal.appsmith.com/app/cypress-dashboard/rundetails-65890b3c81d7400d08fa9ee5?branch=master&workflowId=10243164292&attempt=1"
target="_blank">Cypress dashboard</a>.
> Tags: `@tag.Sanity`
> Spec:
> <hr>Mon, 05 Aug 2024 05:50:07 UTC
<!-- end of auto-generated comment: Cypress test results  -->


## Communication
Should the DevRel and Marketing teams inform users about this change?
- [ ] Yes
- [ ] No
2024-08-05 11:56:50 +05:30
Nidhi
dd73e8b91f
fix: Enable atomic pushes in git using an environment configuration (#33367)
Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
2024-05-14 10:24:21 +05:30
Hetu Nandu
1194bd5a57
fix: Api pane and settings responsiveness (#33297)
## Description

Various style and layout changes for side by side responsiveness

Fixes #33249 

## Automation

/ok-to-test tags="@tag.Datasource"

### 🔍 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/9006852734>
> Commit: de02d207d06524e3aace37647821ffd45ee17e64
> Cypress dashboard url: <a
href="https://internal.appsmith.com/app/cypress-dashboard/rundetails-65890b3c81d7400d08fa9ee5?branch=master&workflowId=9006852734&attempt=1"
target="_blank">Click here!</a>

<!-- end of auto-generated comment: Cypress test results  -->






## Communication
Should the DevRel and Marketing teams inform users about this change?
- [ ] Yes
- [ ] No
2024-05-09 17:02:48 +05:30
Aman Agarwal
796a4c8660
fix: default port numbers for the datasources (#32901) 2024-04-30 13:15:11 +05:30
Aman Agarwal
2a08e8ed52
fix: reverting the default port numbers for the datasources (#32726)
This PR is created to revert the changes from the PR #32592 due to
flakiness in the test specs.

Reverts appsmithorg/appsmith#32592


## Automation

/ok-to-test tags="@tag.Datasource"

### 🔍 Cypress test results
<!-- This is an auto-generated comment: Cypress test results  -->
> [!CAUTION]
> 🔴 🔴 🔴 Some tests have failed.
> Workflow run:
<https://github.com/appsmithorg/appsmith/actions/runs/8717847856>
> Commit: e6b4c320d893490c37bf4b4a2efa02fc4c4a2c4b
> Cypress dashboard: <a
href="https://internal.appsmith.com/app/cypress-dashboard/rundetails-65890b3c81d7400d08fa9ee5?branch=master&workflowId=8717847856&attempt=2&selectiontype=test&testsstatus=failed&specsstatus=fail"
target="_blank"> Click here!</a>
> The following are new failures, please fix them before merging the PR:
<ol>
> <li>cypress/e2e/Regression/ServerSide/ApiTests/API_MultiPart_Spec.ts
</ol>
> To know the list of identified flaky tests - <a
href="https://internal.appsmith.com/app/cypress-dashboard/identified-flaky-tests-65890b3c81d7400d08fa9ee3?branch=master"
target="_blank">Refer here</a>

<!-- end of auto-generated comment: Cypress test results  -->
2024-04-17 13:44:18 +05:30
Nidhi
c51e4b810d
chore: Introduce changes to minimize git footprint (#32595) 2024-04-16 21:34:24 +05:30
Aman Agarwal
ed1bb9273a
fix: default port numbers for the datasources (#32592) 2024-04-16 13:29:04 +05:30
Anagh Hegde
9b14d13af8
feat: add form config for reading certs for PG (#31895)
## Description
Form config changes for the PG datasource to support reading certs from
user

Fixes #31400 

## Automation

/ok-to-test tags="tag.Datasource"

### 🔍 Cypress test results
<!-- This is an auto-generated comment: Cypress test results  -->
> [!IMPORTANT]  
> Workflow run:
<https://github.com/appsmithorg/appsmith/actions/runs/8538007537>
> Commit: `0fb57fe78e973db8a3df5f2e407b85eef4adb4e2`
> Cypress dashboard url: <a
href="https://internal.appsmith.com/app/cypress-dashboard/rundetails-65890b3c81d7400d08fa9ee5?branch=master&workflowId=8538007537&attempt=1"
target="_blank">Click here!</a>
> All cypress tests have passed 🎉🎉🎉

<!-- end of auto-generated comment: Cypress test results  -->





<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

- **New Features**
- Enhanced SSL configuration options for database connections, including
support for client and server CA certificate files.
- **Refactor**
- Improved handling and encoding of SSL certificate content for database
connections, ensuring compatibility and security.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->

---------

Co-authored-by: Aman Agarwal <aman@appsmith.com>
Co-authored-by: Rishabh-Rathod <rishabh.rathod@appsmith.com>
2024-04-03 20:04:49 +05:30
Rishabh Rathod
5d47001dba
chore: Prepared statement description changes (#32042)
## Description



Fixes https://github.com/appsmithorg/appsmith/issues/32045

## Automation

/ok-to-test tags="@tag.Datasource"

### 🔍 Cypress test results
<!-- This is an auto-generated comment: Cypress test results  -->
> [!IMPORTANT]  
> Workflow run:
<https://github.com/appsmithorg/appsmith/actions/runs/8432564141>
> Commit: `120b0d79d5c4139a92bba228bdcb476cf1f7710c`
> Cypress dashboard url: <a
href="https://internal.appsmith.com/app/cypress-dashboard/rundetails-65890b3c81d7400d08fa9ee5?branch=master&workflowId=8432564141&attempt=1"
target="_blank">Click here!</a>
> All cypress tests have passed 🎉🎉🎉

<!-- end of auto-generated comment: Cypress test results  -->






<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

- **Documentation**
- Updated information text related to using Prepared Statements in
queries, emphasizing the prevention of SQL injections and highlighting
limitations on dynamic bindings.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2024-03-26 14:09:35 +05:30
Anagh Hegde
8d696f1c75
feat: PGSql MTLS support (#31067)
## Description
Mutual TLS, or mTLS for short, is a method for mutual authentication.
mTLS ensures that the parties at each end of a network connection are
who they claim to be by verifying that they both have the correct
private key.
This PR adds support for mTLS for postgres datasource. Unlike the
standard way of storing the certs in disk, we store them in the
database. This has been achieved via the custom implementation of SSL
Factory. The postgres driver support passing the custom ssl factory
while creating connection, which then will be used for handling and
establishing the connection.


#### PR fixes following issue(s)
Fixes #31326 

#### Type of change
- New feature (non-breaking change which adds functionality)

## Testing
#### How Has This Been Tested?
- [ ] Manual

#### Test Plan
> Add Testsmith test cases links that relate to this PR
>
>
#### Issues raised during DP testing
> Link issues raised during DP testing for better visiblity and tracking
(copy link from comments dropped on this PR)
>
>
>
## Checklist:
#### Dev activity
- [ ] My code follows the style guidelines of this project
- [ ] I have performed a self-review of my own code
- [ ] I have commented my code, particularly in hard-to-understand areas
- [ ] I have made corresponding changes to the documentation
- [ ] My changes generate no new warnings
- [ ] I have added tests that prove my fix is effective or that my
feature works
- [ ] New and existing unit tests pass locally with my changes
- [ ] PR is being merged under a feature flag


#### QA activity:
- [ ] [Speedbreak
features](https://github.com/appsmithorg/TestSmith/wiki/Guidelines-for-test-plans#speedbreakers-)
have been covered
- [ ] Test plan covers all impacted features and [areas of
interest](https://github.com/appsmithorg/TestSmith/wiki/Guidelines-for-test-plans#areas-of-interest-)
- [ ] Test plan has been peer reviewed by project stakeholders and other
QA members
- [ ] Manually tested functionality on DP
- [ ] We had an implementation alignment call with stakeholders post QA
Round 2
- [ ] Cypress test cases have been added and approved by SDET/manual QA
- [ ] Added `Test Plan Approved` label after Cypress tests were reviewed
- [ ] Added `Test Plan Approved` label after JUnit tests were reviewed


<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

- **New Features**
- Enhanced the Postgres plugin to support SSL certificate validation for
secure database connections. Users can now select between `VERIFY_CA`
and `VERIFY_FULL` modes for SSL verification, ensuring a higher level of
security for database communications.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2024-03-04 14:38:27 +05:30
Shrikant Sharat Kandula
21b0a5ebfb
chore: Fix for CVE-2024-1597 (#31301)
This should get rid of the vulnerable Postgres driver version.
2024-02-28 10:32:58 +05:30
Aman Agarwal
a6926a4fed
fix: sorting schema options alphabetically (#29460) 2023-12-13 13:21:23 +05:30
sneha122
f91dc4889e
chore: JUnit test cases added for rate limit functions (#28399)
## Description

This PR adds JUnit test cases for rate limit functionality implemented
for datasource test and datasource connections.

#### PR fixes following issue(s)
Fixes ##27742
#### Media
> A video or a GIF is preferred. when using Loom, don’t embed because it
looks like it’s a GIF. instead, just link to the video
>
>
#### Type of change
- Chore (housekeeping or task changes that don't impact user perception)
>
>
>
## Testing
>
#### How Has This Been Tested?
> Please describe the tests that you ran to verify your changes. Also
list any relevant details for your test configuration.
> Delete anything that is not relevant
- [ ] Manual
- [x] JUnit
- [ ] Jest
- [ ] Cypress
>
>
#### Test Plan
> Add Testsmith test cases links that relate to this PR
>
>
#### Issues raised during DP testing
> Link issues raised during DP testing for better visiblity and tracking
(copy link from comments dropped on this PR)
>
>
>
## Checklist:
#### Dev activity
- [x] My code follows the style guidelines of this project
- [x] I have performed a self-review of my own code
- [x] I have commented my code, particularly in hard-to-understand areas
- [ ] I have made corresponding changes to the documentation
- [x] My changes generate no new warnings
- [x] I have added tests that prove my fix is effective or that my
feature works
- [ ] New and existing unit tests pass locally with my changes
- [ ] PR is being merged under a feature flag


#### QA activity:
- [ ] [Speedbreak
features](https://github.com/appsmithorg/TestSmith/wiki/Guidelines-for-test-plans#speedbreakers-)
have been covered
- [ ] Test plan covers all impacted features and [areas of
interest](https://github.com/appsmithorg/TestSmith/wiki/Guidelines-for-test-plans#areas-of-interest-)
- [ ] Test plan has been peer reviewed by project stakeholders and other
QA members
- [ ] Manually tested functionality on DP
- [ ] We had an implementation alignment call with stakeholders post QA
Round 2
- [ ] Cypress test cases have been added and approved by SDET/manual QA
- [ ] Added `Test Plan Approved` label after Cypress tests were reviewed
- [ ] Added `Test Plan Approved` label after JUnit tests were reviewed

Co-authored-by: “sneha122” <“sneha@appsmith.com”>
2023-10-26 21:40:55 +05:30
sneha122
ff31d78ee9
chore: Rate limiting datasource test api is added (#27777)
## Description

This PR adds rate limiting functionality to datasource test API. The
rate limiting configuration is added in such a way that if test API
receives more than 3 failed authentication requests for the same host
name within 5 seconds, It will block this hostname for the next 5
minutes, so that brute force attack can be stopped.

Unit test for this will be covered in another PR. Refer #27742 

Currently this PR covers for postgres only, will need to extend the
implementation for all plugins. Refer #27737

#### PR fixes following issue(s)
Fixes #27736, #27739, #27744 
> if no issue exists, please create an issue and ask the maintainers
about this first
>
>
#### Media
> A video or a GIF is preferred. when using Loom, don’t embed because it
looks like it’s a GIF. instead, just link to the video
>
>
#### Type of change
- Chore (housekeeping or task changes that don't impact user perception)
>
>
>
## Testing
>
#### How Has This Been Tested?
> Please describe the tests that you ran to verify your changes. Also
list any relevant details for your test configuration.
> Delete anything that is not relevant
- [x] Manual
- [ ] JUnit
- [ ] Jest
- [ ] Cypress
>
>
#### Test Plan
> Add Testsmith test cases links that relate to this PR
>
>
#### Issues raised during DP testing
> Link issues raised during DP testing for better visiblity and tracking
(copy link from comments dropped on this PR)
>
>
>
## Checklist:
#### Dev activity
- [x] My code follows the style guidelines of this project
- [x] I have performed a self-review of my own code
- [x] I have commented my code, particularly in hard-to-understand areas
- [ ] I have made corresponding changes to the documentation
- [x] My changes generate no new warnings
- [ ] I have added tests that prove my fix is effective or that my
feature works
- [ ] New and existing unit tests pass locally with my changes
- [x] PR is being merged under a feature flag


#### QA activity:
- [ ] [Speedbreak
features](https://github.com/appsmithorg/TestSmith/wiki/Guidelines-for-test-plans#speedbreakers-)
have been covered
- [ ] Test plan covers all impacted features and [areas of
interest](https://github.com/appsmithorg/TestSmith/wiki/Guidelines-for-test-plans#areas-of-interest-)
- [ ] Test plan has been peer reviewed by project stakeholders and other
QA members
- [ ] Manually tested functionality on DP
- [ ] We had an implementation alignment call with stakeholders post QA
Round 2
- [ ] Cypress test cases have been added and approved by SDET/manual QA
- [ ] Added `Test Plan Approved` label after Cypress tests were reviewed
- [ ] Added `Test Plan Approved` label after JUnit tests were reviewed

---------

Co-authored-by: “sneha122” <“sneha@appsmith.com”>
2023-10-17 15:08:23 +05:30
Manish Kumar
8b2d2568b0
feat: CE support for connection pooling (#27859)
### Description
> This is a CE support PR for thie connection pooling issue

Ref: https://github.com/appsmithorg/appsmith-ee/pull/2143

Fixes https://github.com/appsmithorg/appsmith-ee/issues/2124
2023-10-10 23:12:20 +07:00
sneha122
778dd53f45
feat: schema preview API extended for movies mock DB (#26962)
## Description

This PR extends `/schema-preview` API for movies mock mongo DB. For this
experiment we will need to show schema along with preview of movies
mongo DB on the review page. This feature is currently implemented only
for mock mongo DB, if the experiment turns out to be a success, this
will be further extended for non mock mongo datasources as well.

More info on Activation experiments can be found
[here](https://www.notion.so/appsmith/User-Activation-Experiments-cecdd8af23ac4286968096da4a4fdc99)

#### PR fixes following issue(s)
Fixes #26936
> if no issue exists, please create an issue and ask the maintainers
about this first
>
>
#### Media
> A video or a GIF is preferred. when using Loom, don’t embed because it
looks like it’s a GIF. instead, just link to the video
>
>
#### Type of change
- New feature (non-breaking change which adds functionality)
>
>
>
## Testing
>
#### How Has This Been Tested?
> Please describe the tests that you ran to verify your changes. Also
list any relevant details for your test configuration.
> Delete anything that is not relevant
- [x] Manual
- [ ] JUnit
- [ ] Jest
- [ ] Cypress
>
>
#### Test Plan
> Add Testsmith test cases links that relate to this PR
>
>
#### Issues raised during DP testing
> Link issues raised during DP testing for better visiblity and tracking
(copy link from comments dropped on this PR)
>
>
>
## Checklist:
#### Dev activity
- [x] My code follows the style guidelines of this project
- [x] I have performed a self-review of my own code
- [x] I have commented my code, particularly in hard-to-understand areas
- [ ] I have made corresponding changes to the documentation
- [x] My changes generate no new warnings
- [ ] I have added tests that prove my fix is effective or that my
feature works
- [x] New and existing unit tests pass locally with my changes
- [ ] PR is being merged under a feature flag


#### QA activity:
- [ ] [Speedbreak
features](https://github.com/appsmithorg/TestSmith/wiki/Guidelines-for-test-plans#speedbreakers-)
have been covered
- [ ] Test plan covers all impacted features and [areas of
interest](https://github.com/appsmithorg/TestSmith/wiki/Guidelines-for-test-plans#areas-of-interest-)
- [ ] Test plan has been peer reviewed by project stakeholders and other
QA members
- [ ] Manually tested functionality on DP
- [ ] We had an implementation alignment call with stakeholders post QA
Round 2
- [ ] Cypress test cases have been added and approved by SDET/manual QA
- [ ] Added `Test Plan Approved` label after Cypress tests were reviewed
- [ ] Added `Test Plan Approved` label after JUnit tests were reviewed

---------

Co-authored-by: “sneha122” <“sneha@appsmith.com”>
2023-09-06 14:02:24 +05:30
Ayangade Adeoluwa
7dcff0d774
feat: Add isSuggested value to templates for all plugins (#26623)
This PR adds an isSuggested value to templates for all plugins that
support DatasourceStructure
2023-08-30 11:49:25 +01:00
sneha122
5b609e0e8f
feat: Added new api to fetch preview data (#26298) 2023-08-22 17:32:01 +05:30
Ayush Pahwa
75b297201a
chore: code splitting for multiple env feature (#25479)
code split for EE feature

---------

Co-authored-by: ChandanBalajiBP <104058110+ChandanBalajiBP@users.noreply.github.com>
Co-authored-by: Parthvi <80334441+Parthvi12@users.noreply.github.com>
2023-07-21 12:53:17 +07:00
Nidhi
d6e74bf012
chore: Applied Spotless formatter (#25173) 2023-07-07 00:43:11 +05:30
Sumit Kumar
98a509227f
fix: fix MySQL stale connection error (#24429)
## Description
- Add changes to address the`StaleConnection` exception caused by MySQL plugin.
- Update MySQL driver version.
- Other refactor changes not related to the main issue: 
  - Explicit empty constructor definition is replaced with Lombok annotation for all error messages class.
  - A base class is created for plugin error messages class to store all common error messages.
  - Fix Indentation.
2023-06-30 11:40:05 +05:30
sneha122
f36bcf2a6c
feat: query creation dumb templates replaced with smart templates (#24234)
## Description
 
This PR replaces dumb template that is shown on new query creation with
smart templates. With current implementation whenever we create a new DB
query, we see this template before writing the query, when we select any
of the template options, it shows us template query like `SELECT * FROM
users ORDER BY id LIMIT 10;` Since its a template query, users table may
not exist in user's actual database, thus leading them to error results.
<img width="1174" alt="Screenshot 2023-06-09 at 2 45 40 PM"
src="https://github.com/appsmithorg/appsmith/assets/30018882/4dede184-439f-4064-abe0-faf7b236748e">

With new implementation, we are removing this template page, instead if
we have the structure of the datasource available, we would simply get
the first table from the structure, and create select query using that.
This way we are populating query editor with user's actual table names
rather than dumb table name like `users`. Thus leading users to create
successful query

Note: This change is done only for sql plugins like MySQL, MSSQL,
PostgreSQL, Redshift, Oracle, Snowflake.

#### PR fixes following issue(s)
Fixes #23960 
> if no issue exists, please create an issue and ask the maintainers
about this first
>
>
#### Media
> A video or a GIF is preferred. when using Loom, don’t embed because it
looks like it’s a GIF. instead, just link to the video
>
>
#### Type of change
- New feature (non-breaking change which adds functionality)
>
>
>
## Testing
>
#### How Has This Been Tested?
> Please describe the tests that you ran to verify your changes. Also
list any relevant details for your test configuration.
> Delete anything that is not relevant
- [x] Manual
- [ ] Jest
- [x] Cypress
>
>
#### Test Plan
> Create a Connection on the DB 
> Create a Query from the established Query
> Ensure the 1st table data is placed when Add Query button is clicked
from the Review page
> If the query is created from Entity explorer ensure the right table
name is been added

#### Issues raised during DP testing
> Link issues raised during DP testing for better visibility and
tracking (copy link from comments dropped on this PR)
>
>
>
## Checklist:
#### Dev activity
- [x] My code follows the style guidelines of this project
- [x] I have performed a self-review of my own code
- [x] I have commented my code, particularly in hard-to-understand areas
- [ ] I have made corresponding changes to the documentation
- [x] My changes generate no new warnings
- [x] I have added tests that prove my fix is effective or that my
feature works
- [ ] New and existing unit tests pass locally with my changes
- [ ] PR is being merged under a feature flag


#### QA activity:
- [ ] [Speedbreak
features](https://github.com/appsmithorg/TestSmith/wiki/Test-plan-implementation#speedbreaker-features-to-consider-for-every-change)
have been covered
- [x] Test plan covers all impacted features and [areas of
interest](https://github.com/appsmithorg/TestSmith/wiki/Guidelines-for-test-plans/_edit#areas-of-interest)
- [ ] Test plan has been peer reviewed by project stakeholders and other
QA members
- [x] Manually tested functionality on DP
- [ ] We had an implementation alignment call with stakeholders post QA
Round 2
- [x] Cypress test cases have been added and approved by SDET/manual QA
- [x] Added `Test Plan Approved` label after Cypress tests were reviewed
- [ ] Added `Test Plan Approved` label after JUnit tests were reviewed

---------

Co-authored-by: “sneha122” <“sneha@appsmith.com”>
Co-authored-by: Aishwarya UR <aishwarya@appsmith.com>
2023-06-19 15:23:34 +05:30
Aman Agarwal
c49c42b0be
fix: functionality of placeholdertext in key value array control (#24483)
## Description
This PR fixes : 
- the functionality of placeholder for the key value array control which
was earlier accessing `placeholderText` key from a wrong path for host.
- Added placeholders for different datasources as well
2023-06-16 18:04:25 +05:30
ChandanBalajiBP
b5185ab8b5
fix: Update connection mode DropDown by Segmented Control (#23730)
## Description
> Update the Drop-Down component to Segemented Control as per the
designs in datasource configuration.
>Here is the FIGMA
[link](https://www.figma.com/file/xlYswIZx9noaldAPmv3ji4/Multiple-Environments-V2?type=design&node-id=79-36425&t=egGDXQsYmAFAWjBU-0)

>Current state 
><img width="393" alt="Screenshot 2023-05-25 at 3 08 38 PM"
src="https://github.com/appsmithorg/appsmith-ee/assets/104058110/5f623fee-5ba7-464d-be34-a106f0e7c438">

>Updated State 
><img width="393" alt="Screenshot 2023-05-25 at 3 08 38 PM"
src="https://user-images.githubusercontent.com/104058110/237018777-132f6607-a757-41c0-9d52-c00e70745f36.png">

#### PR fixes following issue(s)
Fixes #

#### Type of change
> Please delete options that are not relevant.
- Bug fix (non-breaking change which fixes an issue)
>
## Testing
>
#### How Has This Been Tested?
- [x] Manual
>
>
#### Test Plan
> Add Testsmith test cases links that relate to this PR
>
>
#### Issues raised during DP testing
> Link issues raised during DP testing for better visiblity and tracking
(copy link from comments dropped on this PR)
>
>
>
## Checklist:
#### Dev activity
- [x] My code follows the style guidelines of this project
- [x] I have performed a self-review of my own code
- [x] I have commented my code, particularly in hard-to-understand areas
- [ ] I have made corresponding changes to the documentation
- [x] My changes generate no new warnings
- [ ] I have added tests that prove my fix is effective or that my
feature works
- [x] New and existing unit tests pass locally with my changes
- [ ] PR is being merged under a feature flag


#### QA activity:
- [ ] [Speedbreak
features](https://github.com/appsmithorg/TestSmith/wiki/Test-plan-implementation#speedbreaker-features-to-consider-for-every-change)
have been covered
- [x] Test plan covers all impacted features and [areas of
interest](https://github.com/appsmithorg/TestSmith/wiki/Guidelines-for-test-plans/_edit#areas-of-interest)
- [x] Test plan has been peer reviewed by project stakeholders and other
QA members
- [x] Manually tested functionality on DP
- [ ] We had an implementation alignment call with stakeholders post QA
Round 2
- [ ] Cypress test cases have been added and approved by SDET/manual QA
- [ ] Added `Test Plan Approved` label after Cypress tests were reviewed
- [ ] Added `Test Plan Approved` label after JUnit tests were reviewed
2023-05-29 16:45:52 +05:30
albinAppsmith
629999f124
feat: [epic] appsmith design system version 2 deduplication (#22030)
## Description

### Fixes
- [x] https://github.com/appsmithorg/appsmith/issues/19383
- [x] https://github.com/appsmithorg/appsmith/issues/19384
- [x] https://github.com/appsmithorg/appsmith/issues/19385
- [x] https://github.com/appsmithorg/appsmith/issues/19386
- [x] https://github.com/appsmithorg/appsmith/issues/19387
- [x] https://github.com/appsmithorg/appsmith/issues/19388
- [x] https://github.com/appsmithorg/appsmith/issues/19389
- [x] https://github.com/appsmithorg/appsmith/issues/19390
- [x] https://github.com/appsmithorg/appsmith/issues/19391
- [x] https://github.com/appsmithorg/appsmith/issues/19392
- [x] https://github.com/appsmithorg/appsmith/issues/19393
- [x] https://github.com/appsmithorg/appsmith/issues/19394
- [x] https://github.com/appsmithorg/appsmith/issues/19395
- [x] https://github.com/appsmithorg/appsmith/issues/19396
- [x] https://github.com/appsmithorg/appsmith/issues/19397
- [x] https://github.com/appsmithorg/appsmith/issues/19398
- [x] https://github.com/appsmithorg/appsmith/issues/19399
- [x] https://github.com/appsmithorg/appsmith/issues/19400
- [x] https://github.com/appsmithorg/appsmith/issues/19401
- [x] https://github.com/appsmithorg/appsmith/issues/19402
- [x] https://github.com/appsmithorg/appsmith/issues/19403
- [x] https://github.com/appsmithorg/appsmith/issues/19404
- [x] https://github.com/appsmithorg/appsmith/issues/19405
- [x] https://github.com/appsmithorg/appsmith/issues/19406
- [x] https://github.com/appsmithorg/appsmith/issues/19407
- [x] https://github.com/appsmithorg/appsmith/issues/19408
- [x] https://github.com/appsmithorg/appsmith/issues/19409

Fixes # (issue)
> if no issue exists, please create an issue and ask the maintainers
about this first


Media
> A video or a GIF is preferred. when using Loom, don’t embed because it
looks like it’s a GIF. instead, just link to the video


## Type of change

> Please delete options that are not relevant.

- Bug fix (non-breaking change which fixes an issue)
- New feature (non-breaking change which adds functionality)
- Breaking change (fix or feature that would cause existing
functionality to not work as expected)
- Chore (housekeeping or task changes that don't impact user perception)
- This change requires a documentation update


## How Has This Been Tested?
> Please describe the tests that you ran to verify your changes. Provide
instructions, so we can reproduce.
> Please also list any relevant details for your test configuration.
> Delete anything that is not important

- Manual
- Jest
- Cypress

### Test Plan
> Add Testsmith test cases links that relate to this PR

### Issues raised during DP testing
> Link issues raised during DP testing for better visiblity and tracking
(copy link from comments dropped on this PR)


## Checklist:
### Dev activity
- [ ] My code follows the style guidelines of this project
- [ ] I have performed a self-review of my own code
- [ ] I have commented my code, particularly in hard-to-understand areas
- [ ] I have made corresponding changes to the documentation
- [ ] My changes generate no new warnings
- [ ] I have added tests that prove my fix is effective or that my
feature works
- [ ] New and existing unit tests pass locally with my changes
- [ ] PR is being merged under a feature flag


### QA activity:
- [ ] Test plan has been approved by relevant developers
- [ ] Test plan has been peer reviewed by QA
- [ ] Cypress test cases have been added and approved by either SDET or
manual QA
- [ ] Organized project review call with relevant stakeholders after
Round 1/2 of QA
- [ ] Added Test Plan Approved label after reveiwing all Cypress test

---------

Co-authored-by: Ankita Kinger <ankita@appsmith.com>
Co-authored-by: akash-codemonk <67054171+akash-codemonk@users.noreply.github.com>
Co-authored-by: Tanvi Bhakta <tanvi@appsmith.com>
Co-authored-by: Arsalan <arsalanyaldram0211@outlook.com>
Co-authored-by: Aman Agarwal <aman@appsmith.com>
Co-authored-by: Rohit Agarwal <rohit_agarwal@live.in>
Co-authored-by: Nilesh Sarupriya <nilesh@appsmith.com>
Co-authored-by: Nilesh Sarupriya <20905988+nsarupr@users.noreply.github.com>
Co-authored-by: Tanvi Bhakta <tanvibhakta@gmail.com>
Co-authored-by: Aishwarya UR <aishwarya@appsmith.com>
Co-authored-by: Parthvi Goswami <parthvigoswami@Parthvis-MacBook-Pro.local>
Co-authored-by: Vijetha-Kaja <vijetha@appsmith.com>
Co-authored-by: Parthvi <80334441+Parthvi12@users.noreply.github.com>
Co-authored-by: Apple <nandan@thinkify.io>
Co-authored-by: Saroj <43822041+sarojsarab@users.noreply.github.com>
Co-authored-by: Sangeeth Sivan <74818788+berzerkeer@users.noreply.github.com>
Co-authored-by: Ashok Kumar M <35134347+marks0351@users.noreply.github.com>
Co-authored-by: Aishwarya-U-R <91450662+Aishwarya-U-R@users.noreply.github.com>
Co-authored-by: rahulramesha <rahul@appsmith.com>
Co-authored-by: Aswath K <aswath.sana@gmail.com>
Co-authored-by: Preet Sidhu <preetsidhu.bits@gmail.com>
Co-authored-by: Vijetha-Kaja <119562824+Vijetha-Kaja@users.noreply.github.com>
Co-authored-by: Shrikant Sharat Kandula <shrikant@appsmith.com>
2023-05-20 00:07:06 +05:30
subratadeypappu
094d0a917f
fix: Allow empty password in PostgreSQL trust authentication login (#22186)
This PR reclaims the changes introduced in this
[PR](https://github.com/appsmithorg/appsmith/pull/19265) later which got
reverted by this
[PR](https://github.com/appsmithorg/appsmith/pull/20629)

## Description
- The PR removes the empty password validation check for PostgreSQL
while creating a new data source.
- The JUnit test case is added for the same. Implemented using a
separate PostgreSQL container with Trust Authentication enabled for the
Same.
- Please note for testing from UI perspective we have to create a user
with Trust auth enabled to validate the above changes.



Fixes #14003


Media
> A video or a GIF is preferred. when using Loom, don’t embed because it
looks like it’s a GIF. instead, just link to the video


## Type of change

> Please delete options that are not relevant.

- Bug fix (non-breaking change which fixes an issue)


## How Has This Been Tested?

- JUnit

### Test Plan
> Add Testsmith test cases links that relate to this PR

### Issues raised during DP testing
> Link issues raised during DP testing for better visiblity and tracking
(copy link from comments dropped on this PR)


## Checklist:
### Dev activity
- [ ] My code follows the style guidelines of this project
- [ ] I have performed a self-review of my own code
- [ ] I have commented my code, particularly in hard-to-understand areas
- [ ] I have made corresponding changes to the documentation
- [ ] My changes generate no new warnings
- [ ] I have added tests that prove my fix is effective or that my
feature works
- [ ] New and existing unit tests pass locally with my changes
- [ ] PR is being merged under a feature flag


### QA activity:
- [ ] Test plan has been approved by relevant developers
- [ ] Test plan has been peer reviewed by QA
- [ ] Cypress test cases have been added and approved by either SDET or
manual QA
- [ ] Organized project review call with relevant stakeholders after
Round 1/2 of QA
- [ ] Added Test Plan Approved label after reveiwing all Cypress test
2023-04-13 16:20:46 +06:00
SatVeer Singh
9dd1ef6ff0
fix: Hint text in create query (sql based datasources) (#22190)
## Description
Improve hint text in SQL type queries. 

Fixes #22011
Fixes #22117
2023-04-10 17:50:09 +05:30
Shrikant Sharat Kandula
4280ded88e
chore: Fix unnecessary re-shading of jars (#21994)
Solves a single thing in the build configurations, resulting in a few
wins.

1. Reduced number of warnings in the output.
   1. In release branch:
      ```
mvn clean package -DskipTests | grep --fixed-strings --count '[WARNING]'
      3233
      ```
   1. In this PR's branch:
      ```
mvn clean package -DskipTests | grep --fixed-strings --count '[WARNING]'
      172
      ```

2. All uber-jar files are shaded twice, currently. Once with the default
execution of `maven-shade-plugin`, and again with the `shade-plugin-jar`
execution in these `pom.xml` files. This is double-work, and is the
cause of most of the warnings we see.
1. This `shade-plugin-jar` was added to have the plugin information
included in the `/META-INF/MANIFEST.MF` file, since we can't configure
the default execution of the shade plugin (it comes to us from Spring
Boot).
2. Instead, we switch to configuring plugin information in a
`/plugin.properties` file.
3. Previously, we used `/plugin.properities` for plugin information in
dev time, and `/META-INF/MANIFEST.MF` in production. This PR will change
it so that we use `/plugin.properties` all the time. We configure PF4J
with a custom plugin manager to achieve this.

3. Moved all `plugin.properties` into `src/main/resources`, so that they
land up in the root of the final jar files. But this means, during
development, loading the plugin fails since it looks for a
`plugin.properties` at the root of the plugin module, i.e., next to the
`src` folder.
1. For this, in the custom plugin manager class, we change where we look
for the `plugin.properties` file during development mode. In this mode,
we look at the `target/classes/plugin.properties` file, which is where
maven saves this file, taken from
`src/main/resources/plugin.properties`.
2. This also solves the duplication of the plugin properties that's
currently present, between `plugin.properties` and the `<properties>`
section of `pom.xml` files.


Here's the shade plugin's default execution and configuration, from
Spring Boot:
https://github.com/spring-projects/spring-boot/blob/v3.0.1/spring-boot-project/spring-boot-starters/spring-boot-starter-parent/build.gradle#L174.
2023-04-03 17:49:21 +05:30
Nidhi
c8c80cfbbd
fix: Avoid HikariCP creating idle connection on Postgres DB (#21780)
## Description

A few users noticed that Appsmith was creating surplus connections in
their database even when connected through a single datasource. Ideally,
this number should start from 5 and not exceed beyond total concurrent
requests in the app/workspace. However, it seems like HikariCP tends to
send the following query outside of the connection pool size for every
query that we try to run.
```
SET application_name = 'PostreSQL JDBC Driver'
```

This PR has introduced a custom set application name to all connections
to avoid sending this set query along with every execution request,
according to this
[post](https://seethawenner.medium.com/improve-the-performance-of-your-aws-rds-postgres-database-by-avoiding-session-pinning-a4f010109bed).

Unfortunately, while this solution has lowered the number of such set
queries, they have not disappeared entirely. There is another
alternative [here](https://github.com/appsmithorg/appsmith/pull/21780)
that requires us to let users know about minimum version support for PG
so we will not be opting for that solution at this time.

Fixes #14117

## Type of change
- Bug fix (non-breaking change which fixes an issue)

## How Has This Been Tested?
- Manual
- JUnit

### Test Plan
> Add Testsmith test cases links that relate to this PR

### Issues raised during DP testing
> Link issues raised during DP testing for better visiblity and tracking
(copy link from comments dropped on this PR)


## Checklist:
### Dev activity
- [ ] My code follows the style guidelines of this project
- [ ] I have performed a self-review of my own code
- [ ] I have commented my code, particularly in hard-to-understand areas
- [ ] I have made corresponding changes to the documentation
- [ ] My changes generate no new warnings
- [ ] I have added tests that prove my fix is effective or that my
feature works
- [ ] New and existing unit tests pass locally with my changes
- [ ] PR is being merged under a feature flag


### QA activity:
- [ ] Test plan has been approved by relevant developers
- [ ] Test plan has been peer reviewed by QA
- [ ] Cypress test cases have been added and approved by either SDET or
manual QA
- [ ] Organized project review call with relevant stakeholders after
Round 1/2 of QA
- [ ] Added Test Plan Approved label after reveiwing all Cypress test
2023-04-03 09:48:53 +05:30
Manish Kumar
60626a14cf
fix: Ensure backward compatibility w.r.t. statusCode and response.body in case of errors (#21052)
## Description
Since we have introduced the error handling framework, each plugin
produces error messages specific to the plugin execution exception. This
Pr is just about standardising these error messages.
In this PR we are handling only five plugins as mentioned:
- Rest API
- MongoDB
- Postgres
- MySql
- Google Sheets

> Modifying error messages for five plugins Rest API, Mongo, Postgres,
MySQL, and Google Sheets for improving consistency.

In addition it also takes care of the following issues
- If the downstream error message is available response.body will hold
that value and it will hold the appsmith error message otherwise
- Don't override the actual http status code with Appsmith error code in
case of RestAPI and GraphQL plugins

Fixes #20438 #21022

## Type of change
- Chore (housekeeping or task changes that don't impact user perception)

## How Has This Been Tested?
- Manual


## Checklist:
### Dev activity
- [x] My code follows the style guidelines of this project
- [ ] I have performed a self-review of my own code
- [ ] I have commented my code, particularly in hard-to-understand areas
- [ ] I have made corresponding changes to the documentation
- [ ] My changes generate no new warnings
- [ ] I have added tests that prove my fix is effective or that my
feature works
- [ ] New and existing unit tests pass locally with my changes
- [ ] PR is being merged under a feature flag

---------

Co-authored-by: subrata <subrata@appsmith.com>
Co-authored-by: ChandanBalajiBP <104058110+ChandanBalajiBP@users.noreply.github.com>
2023-03-03 21:18:01 +07:00
ChandanBalajiBP
b72dea33f3
feat: Error handling phase 1 (#20629)
## Description
This PR updates the error logs 
- Establishing a consistent format for all error messages.
- Revising error titles and details for improved understanding.
- Compiling internal documentation of all error categories,
subcategories, and error descriptions.

Updated Error Interface:
https://www.notion.so/appsmith/Error-Interface-for-Plugin-Execution-Error-7b3f5323ba4c40bfad281ae717ccf79b

PRD:
https://www.notion.so/appsmith/PRD-Error-Handling-Framework-4ac9747057fd4105a9d52cb8b42f4452?pvs=4#008e9c79ff3c484abf0250a5416cf052

>TL;DR 

Fixes # 


Media
> A video or a GIF is preferred. when using Loom, don’t embed because it
looks like it’s a GIF. instead, just link to the video


## Type of change

- New feature (non-breaking change which adds functionality)


## How Has This Been Tested?

- Manual
- Jest
- Cypress

### Test Plan


### Issues raised during DP testing


## Checklist:
### Dev activity
- [x] My code follows the style guidelines of this project
- [x] I have performed a self-review of my own code
- [x] I have commented my code, particularly in hard-to-understand areas
- [ ] I have made corresponding changes to the documentation
- [x] My changes generate no new warnings
- [x] I have added tests that prove my fix is effective or that my
feature works
- [x] New and existing unit tests pass locally with my changes
- [x] PR is being merged under a feature flag


### QA activity:
- [ ] Test plan has been approved by relevant developers
- [ ] Test plan has been peer reviewed by QA
- [ ] Cypress test cases have been added and approved by either SDET or
manual QA
- [ ] Organized project review call with relevant stakeholders after
Round 1/2 of QA
- [ ] Added Test Plan Approved label after reveiwing all Cypress test

---------

Co-authored-by: subrata <subrata@appsmith.com>
2023-02-18 18:25:46 +05:30
PiyushPushkar02
c40bdc6142
fix: PostgreSQL Trust Authentication Login (#19265)
### **Description**

- The PR removes the empty password validation check for PostgreSQL
while creating a new data source.
- The JUnit test case is added for the same. Implemented using a
separate PostgreSQL container with Trust Authentication enabled for the
Same.
- Please note for testing from UI perspective we have to create a user
with Trust auth enabled to validate the above changes.

Fixes  #14003

### **Type of Change**

- Bug Fix(non-breaking change which adds functionality)

### **How Has This Been Tested?**
- Manual
- JUnit TC added 

### **Checklist**:

- [x]  My code follows the style guidelines of this project
- [x]  I have performed a self-review of my own code
- [ ] I have commented my code, particularly in hard-to-understand areas
- [ ]  I have made corresponding changes to the documentation
- [ ]  My changes generate no new warnings
- [x] I have added tests that prove my fix is effective or that my
feature works
- [x]  New and existing unit tests pass locally with my changes
- [ ]  PR is being merged under a feature flag

### **QA activity:**

- [ ]  Test plan has been approved by relevant developers
- [ ]  Test plan has been peer reviewed by QA
- [ ] Cypress test cases have been added and approved by either SDET or
manual QA
- [ ] Organized project review call with relevant stakeholders after
Round 1/2 of QA
- [ ]  Added Test Plan Approved label after reveiwing all Cypress test
2023-01-13 11:27:27 +05:30
Nidhi
dfccd5a058
chore: Upgrade to Spring Boot 3.0.1 (#19044)
This upgrade takes care of our move to JDK 17, Spring Boot 3.0.1 and a
few other security upgrades along the way.

Fixes #18993 

TODO:

- [x] Check CI changes for Java 17
- [x] Check vulnerability report
- [x] Mongock needs an upgrade
- [x] Add JVM args at all possible places for exposing java.time module
- [x] Add type adapters everywhere / use the same config for type
adapters everywhere
2023-01-02 19:40:59 +07:00
Nidhi
5329010415
fix: Refactor entities based on AST parsing logic (#18517)
* feat: Refactor entities based on AST parsing logic

* Deleted jmh file

* rts updates for the edge cases

* adding jest test cases

* update review comments

* Fixed issue with references outside of bindings and some other stuff

* Added tests for DSLUtils

* bug fix 18699

* Test fixes

* Test fixes

* Review comments

* Changed type to boxed

Co-authored-by: ChandanBalajiBP <chandan@appsmith.com>
Co-authored-by: ChandanBalajiBP <104058110+ChandanBalajiBP@users.noreply.github.com>
2022-12-12 08:12:21 +03:00
dependabot[bot]
8e9ce96565
chore: bump postgresql from 42.4.1 to 42.4.3 in /app/server/appsmith-plugins/postgresPlugin (#18407)
chore: bump postgresql in /app/server/appsmith-plugins/postgresPlugin

Bumps [postgresql](https://github.com/pgjdbc/pgjdbc) from 42.4.1 to 42.4.3.
- [Release notes](https://github.com/pgjdbc/pgjdbc/releases)
- [Changelog](https://github.com/pgjdbc/pgjdbc/blob/master/CHANGELOG.md)
- [Commits](https://github.com/pgjdbc/pgjdbc/compare/REL42.4.1...REL42.4.3)

---
updated-dependencies:
- dependency-name: org.postgresql:postgresql
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-11-25 11:19:24 +05:30
Sumit Kumar
68b7f16932
fix: update HikariCP package version (#17806)
update HikariCP package version
2022-10-27 14:07:37 +05:30