Commit Graph

489 Commits

Author SHA1 Message Date
Rishabh Rathod
2b8f49930f
chore: Add unit test for RequestCaptureFilter (#33819)
## Description

Add unit test for RequestCaptureField

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

## Automation

/test 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/9283183535>
> Commit: 7814315bab793ff7c2b1c92cbf1d5020fd574988
> Cypress dashboard url: <a
href="https://internal.appsmith.com/app/cypress-dashboard/rundetails-65890b3c81d7400d08fa9ee5?branch=master&workflowId=9283183535&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
- [x] No
2024-05-29 15:58:29 +05:30
Shrikant Sharat Kandula
4a317603fe
chore: Remove unused eventData (#33730)
For action creation, client sends this in `eventData` field of the
request body:

![shot-2024-05-26-04-50-46](https://github.com/appsmithorg/appsmith/assets/120119/b876b27f-47ec-4a00-8598-33cb92120c49)

But the class defined for `eventData` is this:

![shot-2024-05-26-04-51-03](https://github.com/appsmithorg/appsmith/assets/120119/18bf46b7-597a-4b2f-8355-1b8fad30e4ce)

Clearly isn't used, or working.


/test sanity datasource

⚠️ Note that `eventData` is actually used in the analytics data sent by
client, and that's not being removed here. We're only removing the
unused server-side support here.

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

<!-- end of auto-generated comment: Cypress test results  -->
2024-05-28 09:50:12 +05:30
Shrikant Sharat Kandula
b968c4cbf3
chore: Remove @JsonView on hasExpired method (#33765)
The `hasExpired` method has a `@JsonView` annotation, that causes it to
be included in JSON responses. But the return type of this method is
`Mono<Boolean>`, so obviously, it doesn't produce anything useful in the
resulting JSON:

This is from the response of updating an authenticated API with basic
auth.


![shot-2024-05-27-13-43-26](https://github.com/appsmithorg/appsmith/assets/120119/6ab47d3e-5911-45d6-840a-1e37c41a415a)

Client doesn't care for this field in the response.

This is failing to be serialized at all, when saving to database in
Postgres.

**/test sanity datasource**

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

<!-- end of auto-generated comment: Cypress test results  -->
2024-05-28 07:31:25 +05:30
Rishabh Rathod
43bd03214f
fix: encode queryParam value and fix parsing logic for queryParams (#33720)
## Description

- Add encoding for Api key secret value before storing it as query param
to avoid incorrect parsing.
- Remove hardcoded "api_key" check to mask headers.
- Used standard URL parsing APIs instead of custom
- Added unit test to cover the case 

Fixes https://github.com/appsmithorg/appsmith/issues/33742
flaws in the implementation
[here](https://github.com/appsmithorg/appsmith/pull/33528)

## Automation

/test datasource

### 🔍 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/9256269257>
> Commit: 602b0f599ff17ac7530b25336eae6a0523c90977
> Workflow: `PR Automation test suite`
> Tags: `@tag.Datasource`

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






## Communication
Should the DevRel and Marketing teams inform users about this change?
- [ ] Yes
- [x] No
2024-05-27 14:43:59 +00:00
Manish Kumar
849d97ecd3
feat: feature branch for server side autocommit (#32572)
## Description
- Feature branch for server side AutoCommit.
Fixes #32888 
## Automation

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

### 🔍 Cypress test results

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


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

<!-- end of auto-generated comment: Cypress test results  -->
2024-05-24 10:29:58 +05:30
Rishabh Rathod
b59838c03a
fix: apiKey security issue (#33528)
## Description
Fixes #30009

### Summary:
This PR addresses the issue of masking sensitive information in query
parameters or headers based on the authentication type selected by the
user. The changes ensure that sensitive data is properly masked before
sending back as response.

### Changes:
- RequestCaptureFilter.java
Added logic to check the authentication type and mask the appropriate
query parameters or headers.

### Testing:
Verified that the masking functionality works as expected for API_KEY
authentication types.

## Automation

/test 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/9203547387>
> Commit: 9a7fc9cc1942ddc61c54f6ae9451706ad527f49c
> Cypress dashboard url: <a
href="https://internal.appsmith.com/app/cypress-dashboard/rundetails-65890b3c81d7400d08fa9ee5?branch=master&workflowId=9203547387&attempt=2"
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
- [x] No

---------

Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
2024-05-23 13:45:16 +05:30
Shrikant Sharat Kandula
36eaf3bd57
chore: Remove unused method 2024-05-14 20:18:37 +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
Shrikant Sharat Kandula
f71bdc8b23
fix: Fix OAuth2 client secret showing up in UI (#33281)
/ok-to-test tags="@tag.Sanity"
2024-05-08 15:47:47 +05:30
Nidhi
e8c47cdaa2
fix: Start using SHA2 instead of SHA1 algorithms for signing during git operations (#33166) 2024-05-06 18:25:32 +05:30
Nilansh Bansal
a5edfb025a
fix: authenticationType field saved to database (#33196)
## Description
With the introduction of FromRequest for the create datasource API in
[this](https://github.com/appsmithorg/appsmith/pull/33039) PR, we have
restricted the fields that will be accepted from the client in the
request body. Due to this the `authenticationType` field was not getting
accepted from the client in the create datasource API, which lead to the
failure of airtable queries.

This PR allows the acceptance of `authenticationType` field from the
client.
Discussions
[here](https://theappsmith.slack.com/archives/CTHN8GX5Y/p1714974437746959).

Fixes #33184   

## 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/8966382606>
> Commit: a292aa075d3598389410b5c201f58c489fd2dfc2
> Cypress dashboard: <a
href="https://internal.appsmith.com/app/cypress-dashboard/rundetails-65890b3c81d7400d08fa9ee5?branch=master&workflowId=8966382606&attempt=3&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/QueryPane/DSDocs_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  -->






## Communication
Should the DevRel and Marketing teams inform users about this change?
- [ ] Yes
- [ ] No
2024-05-06 16:30:29 +05:30
Shrikant Sharat Kandula
1a4a08e673
chore: Fix warnings in ConsolidatedAPIServiceImpl (#33114)
This is an effort to reduce warnings from `javac`, towards adding a
linter to the backend.

I recently had to troubleshoot some code in this class and the array
based zipping of 10+ Monos was very hard to parse and debug. This PR
simplifies that implementation as well as fixes all/most warnings in
this class.

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

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

<!-- end of auto-generated comment: Cypress test results  -->
2024-05-02 16:16:51 +05:30
Shrikant Sharat Kandula
258e92e368
chore: Use FromRequest for datasource APIs (#33039)
This PR removes use of `@JsonProperty` in Datasource entity so that it
encrypted fields can be stored to the database in Postgres version.

EE Unit and Cypress `All` pass.

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

<!-- This is an auto-generated comment: Cypress test results  -->
> [!TIP]
> 🟢 🟢 🟢 All cypress tests have passed! 🎉 🎉 🎉
> Workflow run:
<https://github.com/appsmithorg/appsmith/actions/runs/8904366086>
> Commit: 1546722f4248b95f624960fe4d888d6082c60ce0
> Cypress dashboard url: <a
href="https://internal.appsmith.com/app/cypress-dashboard/rundetails-65890b3c81d7400d08fa9ee5?branch=master&workflowId=8904366086&attempt=2"
target="_blank">Click here!</a>

<!-- end of auto-generated comment: Cypress test results  -->
2024-05-02 16:16:25 +05:30
Shrikant Sharat Kandula
809710245d
chore: Add an internal request ID for logging (#33086)
/ok-to-test tags="@tag.All"

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

<!-- end of auto-generated comment: Cypress test results  -->
2024-05-02 13:00:23 +05:30
sneha122
5f2a9ef387
fix: REST API multimedia file upload issue fixed (#32921)
## Description
If we use REST API action and file picker widget to upload any
multimedia files (image, audio, video, pdf, xlsx), The file upload would
be successful but file would get corrupted upon uploading. This was
happening because file picker widget encodes this file to base64 format,
and we were uploading this same base64 string using REST API url.
Instead we should have decoded this base64 and then uploaded the file to
retain the original contents of the file.

This PR fixes that issue by adding a new tab in body of the REST API
action called `binary`, once we select this tab, we get autogenerated
header for `Content-Type: application/octet-stream`, in this binary
input field we can then provide base64 encoded file contents, the server
then decodes the contents before triggering the respective REST API and
uploading the file.

### Steps to test the issue
1. Add a file picker widget on canvas
2. Select data format as `Base64`
3. Upload any of pdf, image, audio, video, xlsx in file picker
4. Create a REST API action using [Dropbox upload
API](https://www.dropbox.com/developers/documentation/http/documentation#files-upload)
5. Configure the API headers as mentioned in the documentation, also
configure file name in the header correctly
6. Go to body tab, select binary and file contents in input box using
binding like {{Filepicker1.files[0].data}}
7. Execute this API
8. Now go to your dropbox account and check the uploaded file, you
should be able to successfully preview it


Fixes #32378  
_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.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/8844375718>
> Commit: 3316290a4d7d77ae3f9d8969245c5f470ef1ab5c
> Cypress dashboard url: <a
href="https://internal.appsmith.com/app/cypress-dashboard/rundetails-65890b3c81d7400d08fa9ee5?branch=master&workflowId=8844375718&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
- [x] No


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

## Summary by CodeRabbit

- **New Features**
- Added support for binary file uploads in API requests, including
handling of base64-encoded files.
- Expanded content type options to include a new "BINARY" type for API
requests.

- **Tests**
- Implemented new tests to verify the functionality of binary file
uploads with dynamic data binding.

- **Bug Fixes**
- Ensured correct handling and auto-generation of headers for binary
file types and form urlencoded data formats.

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

---------

Co-authored-by: “sneha122” <“sneha@appsmith.com”>
2024-04-29 17:08:33 +05:30
Shrikant Sharat Kandula
b4bc7f00b7
chore: remove unused DatasourceDTO (#33020) 2024-04-29 15:11:26 +05:30
Nidhi
7edd5c5a2f
Revert "chore: GitSynced and BranchAware are two different types (#32… (#32965) 2024-04-25 17:26:52 +05:30
Nidhi
b69de462b9
chore: GitSynced and BranchAware are two different types (#32932) 2024-04-25 11:22:17 +05:30
Shrikant Sharat Kandula
3d5e240a3f
chore: Remove PEMCertificate and fix @Document annotations (#32705)
/ok-to-test tags="@tag.Sanity"<!-- This is an auto-generated comment:
Cypress test results -->
> [!TIP]
> 🟢 🟢 🟢 All cypress tests have passed! 🎉 🎉 🎉
> Workflow run:
<https://github.com/appsmithorg/appsmith/actions/runs/8748422171>
> Commit: 5e44cffe2a66b8bb932162f4292ac0957c28d89f
> Cypress dashboard url: <a
href="https://internal.appsmith.com/app/cypress-dashboard/rundetails-65890b3c81d7400d08fa9ee5?branch=master&workflowId=8748422171&attempt=1"
target="_blank">Click here!</a>

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





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


- **Refactor**
- Improved maintainability of the PEMCertificate class by streamlining
annotations.
- **New Features**
	- Enhanced database integration for Git deployment keys.
- **Bug Fixes**
- Removed redundant fields from SSLDetails class, improving logic
related to PEM certificates.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2024-04-19 16:29:17 +05:30
Manish Kumar
8749cf1f92
chore: added CE changes for second set of apis (#31898) 2024-04-19 12:48:53 +05:30
sneha122
d664a81b6a
fix: graphQL bindings issue resolved (#32760)
## Description
This PR resolved issue with graphQL, where if we create a graphQL with a
binding and run such query, it returns with error response saying the
query execution has timed out. A user had raised this issue
[here](https://discord.com/channels/725602949748752515/1230134890704539709).

### Root cause:
The issue was not at all reproducible on local, but It was continuously
erroring out on production, release and even DPs. From the logs, we can
see that issue was with `GraphQLDataTypeUtils.java` class. This class
was somehow not getting initialised. This was due to recent changes made
in [PR](https://github.com/appsmithorg/appsmith/pull/32595), where the
version for package was updated to v2.17.0, on local it was compiling
properly but on release, production and other builds, it still seems to
be referencing to the older version of it, we do not know the reason of
it right now, we should further investigate this. But since this was a
critical issue and we need to get user unblocked, we are going ahead
with an alternate fix where we have moved the initialisation of
objectMapper to serialisationUtils.java file.

![Screenshot 2024-04-18 at 11 22 55
AM](https://github.com/appsmithorg/appsmith/assets/30018882/9735aaed-07c2-402b-a798-d7a4c1b67a19)

### Steps to reproduce the issue:
1. Drag and drop a text widget on canvas, change text value to `US`
2. Create a new graphQL query with url as
`https://countries.trevorblades.com/`
3. Add following in the query body and execute the API

```
{
  country(code: {{Text1.text}}) {
    name
	}
}
```


Fixes #32748
_or_  
Fixes [`Issue
URL`](https://github.com/appsmithorg/appsmith/issues/32748)
> [!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/8735651316>
> Commit: a03f29f8078398a4c317e852667270c0810bddea
> Cypress dashboard url: <a
href="https://internal.appsmith.com/app/cypress-dashboard/rundetails-65890b3c81d7400d08fa9ee5?branch=master&workflowId=8735651316&attempt=2"
target="_blank">Click here!</a>

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





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

- **Refactor**
- Updated serialization configuration across various data types and
plugins to enhance functionality and compatibility using a centralized
utility method.
- **New Features**
- Introduced a new method to standardize object mapper configurations,
improving serialization processes across the application.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->

---------

Co-authored-by: “sneha122” <“sneha@appsmith.com”>
2024-04-18 17:36:54 +05:30
Nidhi
c51e4b810d
chore: Introduce changes to minimize git footprint (#32595) 2024-04-16 21:34:24 +05:30
sneha122
520cfa10a6
fix: Revert "feat: suggest queries query type added in action DTO" (#32711)
Reverts appsmithorg/appsmith#32593

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

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

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




## Summary by CodeRabbit

- **Refactor**
- Removed unused `DatasourceQueryType` field and associated methods to
streamline backend services, enhancing overall system performance.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2024-04-16 19:07:45 +05:30
Nidhi
e6c9efce50
chore: Move feature flag annotation and enum to interfaces (#32694) 2024-04-16 13:15:53 +05:30
Shrikant Sharat Kandula
f910a528e3
chore: Add separate request/response views (#32448)
This PR gets finer control into what fields are allowed in
request-body-only, vs what's allowed in response-body-only. This leaves
the fields to separately controlled regarding what can go into the
database and what can't.

[Slack thread](https://theappsmith.slack.com/archives/CPQNLFHTN/p1710125307810949).
2024-04-16 12:47:16 +05:30
Nilansh Bansal
11ef1fcf70
feat: added updatedAt in actions (#32650)
## Description
> This PR introduces the updatedAt field in the consolidated api
response, `unpublishedActions` list.
The value of updatedAt will be consumed by the client to sort the
actions based on the recently updated ones in the suggested fetch
queries for widgets learnability task.

Fixes #32553 

## Automation

/ok-to-test tags="@tag.ImportExport, @tag.Datasource, @tag.Fork,
@tag.Git"

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

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














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

- **New Features**
- Updated the display of the "Last Updated" timestamp with a specific
format and timezone across the application.
- **Bug Fixes**
- Ensured the "Last Updated" timestamp is accurately updated and
displayed when actions are modified.
- **Tests**
- Added and modified tests to verify the correct handling and display of
the "Last Updated" timestamp for actions.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2024-04-16 11:45:06 +05:30
Shrikant Sharat Kandula
f2013bd386
chore: Remove @Document on non-entity classes (#32571)
These few classes have the `@Document` annotation, but aren't mapped to
collections in the database, and don't have corresponding `*Repository`
interfaces either. They're not database entities, and shouldn't have
this annotation.


Sanity passed on both CE and EE.

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

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

<!-- end of auto-generated comment: Cypress test results  -->
2024-04-15 17:00:40 +05:30
Abhijeet
4848805364
chore: Use update clause from Bridge API (#32411)
PR to update Field usage and adding a UpdateBridge API while saving the
datasource structure.

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

<!-- 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 the data model to support default resources for pages and
actions, improving the management and organization of these elements.
- **Refactor**
- Improved code quality and maintainability by utilizing static
references and utility methods for field access in database queries,
leading to more robust and error-resistant code.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2024-04-12 16:39:16 +05:30
sneha122
76266d808a
feat: suggest queries query type added in action DTO (#32593)
## Description
This PR adds query_type to actionDTO, when fetching queries, query type
indicates whether it is a fetch query or any other query, this
information can be further used to suggest queries to user when they
bind data to widgets. This way we can suggest relevant queries to users
first and their chances of success with Appsmith are higher.

Note: This PR only introduces the field in actionDTO and returns
UNKNOWN, in subsequent PRs we will be adding plugin specific
implementation to return relevant query_type. I have not added any unit
tests as of now, we can add those once plugin specific implementations
are done.

Fixes #`Issue Number`  
_or_  
Fixes [`Issue
URL`](https://github.com/appsmithorg/appsmith/issues/32554)
> [!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.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/8643950238>
> Commit: 08e28bca9e4054ae78d4f4188cfecfc708a62608
> Cypress dashboard url: <a
href="https://internal.appsmith.com/app/cypress-dashboard/rundetails-65890b3c81d7400d08fa9ee5?branch=master&workflowId=8643950238&attempt=1"
target="_blank">Click here!</a>

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

Co-authored-by: “sneha122” <“sneha@appsmith.com”>
2024-04-12 13:04:16 +05:30
Rudraprasad Das
f7118422c6
feat: granular git status (#31619)
## Description
Lists down changes in entity with level 1 granularity

Fixes #31644 

## Automation

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

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

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









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

- **New Features**
- Introduced granular tracking of Git changes, including added,
modified, and removed pages, datasources, queries, JS objects, and JS
libraries.
- Implemented a new feature flag `release_git_status_granular_enabled`
to toggle granular Git status tracking.
- Added new components to display detailed Git changes with expandable
views for different types of entities.

- **Enhancements**
- Simplified the logic for determining if a commit is required by
enhancing the Git status checks.
- Enhanced Git status display to include specific messages and icons for
various types of changes.
- Improved the Git sync feature's user interface with updated components
and styling for displaying Git changes.
	
- **Bug Fixes**
- Corrected the display logic to accurately reflect when a JS library is
added instead of modified.

- **Refactor**
- Refactored Git status handling logic on both client and server sides
for improved performance and readability.
- Updated test suites to align with the new Git status tracking and
display functionalities.

- **Tests**
- Added and updated tests to cover new Git status functionalities and
components.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2024-04-11 18:26:09 +05:30
Nidhi
6339b05670
chore: Added metrics on File I/O wrt git (#32433) 2024-04-09 21:16:10 +05:30
Manish Kumar
807f5606f0
chore: Git spans changed from enum to string (#32454) 2024-04-09 19:59:21 +05:30
Shrikant Sharat Kandula
e8c24d4fd8 Revert "chore: Add separate request/response views (#31781)"
This reverts commit 261700076e.
2024-04-05 11:08:26 +05:30
Manish Kumar
fbae2dc83c
chore: server autocommit (#32387)
## Description
The purpose of this test file is to detect if code in Appsmith has
changed in a way which would reflect as uncommitted changes in
git-connected applications.

This test case would fail if we have added new domains, changed the
underlying structure of the domains, or how it's represented in domains.

It is intentionally kept to fail so that developers could identify if
their code has brought about these changes.

In order to make the test case pass, we would need to add the following
steps:

Once the test starts failing, that would mean that we need to increment
the serverSchemaVersion which is a constant in JsonSchemaVersions.java
by 1 count. After that, do the needful in JsonSchemaMigrations to update
the version number in incoming imports.
This is important so that the server code could detect that an
auto-commit is required for git-connected applications for a seamless
experience.

After step 1, this test case would still fail. In order to make the test
case work again, please replace the respective JSON with the updated
application JSON. Please take note that the Serialisation Objective
should be VERSION_CONTROL. In order to retrieve the updated JSON, one
could simply copy the serialized files from the test case itself.

After this there would be one issue left to deal with:
https://github.com/appsmithorg/appsmith/issues/32401

Fixes #32416
## Automation

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

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

- **New Features**
- Added functionality to reconstruct metadata from a Git repository for
workspace, application, repository, and branch information.
<!-- end of auto-generated comment: release notes by coderabbit.ai
--><!-- This is an auto-generated comment: Cypress test results -->
> [!IMPORTANT]  
> Workflow run:
<https://github.com/appsmithorg/appsmith/actions/runs/8552624183>
> Commit: `48c393eb726f8ecc32b9b5fe01a0e4d4606f6333`
> Cypress dashboard url: <a
href="https://internal.appsmith.com/app/cypress-dashboard/rundetails-65890b3c81d7400d08fa9ee5?branch=master&workflowId=8552624183&attempt=1"
target="_blank">Click here!</a>
> All cypress tests have passed 🎉🎉🎉

<!-- end of auto-generated comment: Cypress test results  -->
2024-04-05 01:15:24 +05:30
Anagh Hegde
8471ea6037
chore: add analytics events (#32385)
## Description
Add analytics event

Fixes https://github.com/appsmithorg/appsmith/issues/32018
## Automation

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

### 🔍 Cypress test results
<!-- This is an auto-generated comment: Cypress test results  -->
> [!IMPORTANT]  
> Workflow run:
<https://github.com/appsmithorg/appsmith/actions/runs/8540471637>
> Commit: `0a121e609363c33955d6abd36260ac13bcf7ae10`
> Cypress dashboard url: <a
href="https://internal.appsmith.com/app/cypress-dashboard/rundetails-65890b3c81d7400d08fa9ee5?branch=master&workflowId=8540471637&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**
- Introduced a new analytics event `TEMPLATE_FORK` to better track
template forking activities.
- **Refactor**
- Updated the event tracking in template forking processes to use the
new `TEMPLATE_FORK` event for enhanced clarity and specificity.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
2024-04-04 15:38:59 +05:30
Shrikant Sharat Kandula
261700076e
chore: Add separate request/response views (#31781)
This PR gets finer control into what fields are allowed in
request-body-only, vs what's allowed in response-body-only. This leaves
the fields to separately controlled regarding what can go into the
database and what can't.

[Slack
thread](https://theappsmith.slack.com/archives/CPQNLFHTN/p1710125307810949).

 Server and Cypress **Sanity** tests pass on EE.
2024-04-04 15:10:38 +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
Shrikant Sharat Kandula
5767501060
chore: Refactor API for hiding logs (#32358)
Sorry for quickly changing the signature(s) of this.

1. The generic method in the super class just wasn't working well. The
generic return type needs to be set explicitly in some places, and is
inferred in some, and is just too volatile. So we replicate the method
definition in both the subclasses for better API usage code.
2. The field already has a getter with Lombok, I didn't need to write a
new one. 🤦
2024-04-03 13:08:29 +05:30
Shrikant Sharat Kandula
bfb424743a
chore: Get control over what stack traces show up in logs (#32352)
This should give us control over what exceptions print a stack trace and
what exceptions don't need to. Should help us get more control over our
logs and reduce noice.


![shot-2024-04-02-12-33-05](https://github.com/appsmithorg/appsmith/assets/120119/26214102-373a-452f-baa9-7c6492604e83)
2024-04-03 11:33:29 +05:30
Shrikant Sharat Kandula
2cb6b1cd59
chore: Don't use MongoDB API for random string (#32344) 2024-04-03 10:39:19 +05:30
Manish Kumar
d0162013f6
chore: analytics for GIT FS (#32302) 2024-04-02 20:55:19 +05:30
Shrikant Sharat Kandula
a38f7fbb5f
chore: Reduce test logging noise (#32312)
Removes log lines about downloading the Docker images by Testcontainers.

Taken from [recommended configuration by
Testcontainers](https://java.testcontainers.org/supported_docker_environment/logging_config/).
2024-04-02 09:16:03 +05:30
Shrikant Sharat Kandula
adc999f542
chore: Remove varargs and List signatures for .criteria() (#32208)
These signatures don't translate very to the Postgres branch.

Server and Cypress tests verified on EE.
2024-03-29 09:20:47 +05:30
Shrikant Sharat Kandula
eba60585ab
chore: Move StringUtils to interfaces module (#32129)
This is a utility class with static methods, and we need them in domain
classes in the `interfaces` module as well.
2024-03-28 10:53:41 +05:30
Shrikant Sharat Kandula
36577ad7cc
chore: Remove QueryDSL (#32074)
Another attempt at removing QueryDSL. This time, it seems to be working
without very many shenanigans, which throws question on what the hell I
was doing in the previous attempt. 😭

All tests and Sanity Cypress passes on EE at
https://github.com/appsmithorg/appsmith-ee/pull/3805.
2024-03-26 21:28:16 +05:30
Shrikant Sharat Kandula
66a24c692a Revert "chore: Remove QueryDSL and add Errorprone (#31754)"
This reverts commit 7f9d31adbc.
2024-03-25 19:20:22 +05:30
Shrikant Sharat Kandula
7f9d31adbc
chore: Remove QueryDSL and add Errorprone (#31754)
Two things happening in this PR.

1. We're removing QueryDSL.
2. We're adding [Errorprone](http://errorprone.info/).

Why both together? Because I can't get the build to work, if I remove
QueryDSL, and not add any other annotation processor. Lombok is refusing
to do its thing, unless there is at least one other annotation
processor, which QueryDSL was filling in for. I wanted to add Errorprone
anyway in a separate task, so didn't investigate further and just added
it here.

But adding Errorprone is not the idea for now. So all lint rules are
disable, and it has no affect on build time either. We'll slowly roll
out some of the checks and lint rules in the coming weeks.
2024-03-25 17:05:34 +05:30
Nilesh Sarupriya
819d414e7a
chore: extend the update recently used workspaces to workflows and packages (#31738)
## Description
> [!TIP]  
> Code split the recently used workspaces code to other workspace
children

Fixes [[Task]: Workflows to get sorted based on recently used objects
per user in a
workspace](https://github.com/appsmithorg/appsmith/issues/30841)

## Automation

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

### 🔍 Cypress test results
<!-- This is an auto-generated comment: Cypress test results  -->
> [!IMPORTANT]  
> Workflow run:
<https://github.com/appsmithorg/appsmith/actions/runs/8323719016>
> Commit: `af46466b7d88662d656fcaf8034ccda9dd72f657`
> Cypress dashboard url: <a
href="https://internal.appsmith.com/app/cypress-dashboard/rundetails-65890b3c81d7400d08fa9ee5?branch=master&workflowId=8323719016&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


## Summary by CodeRabbit

- **New Features**
- Enhanced tracking for user interactions across applications,
workflows, and packages to improve the user experience.
- **Refactor**
- Updated user data service to support the new tracking feature,
ensuring a more personalized and efficient user interface.

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

---------

Co-authored-by: Nilesh Sarupriya <20905988+nsarupr@users.noreply.github.com>
2024-03-19 02:37:56 -05:00
Nirmal Sarswat
997326774b
chore: Add after delete hook for Appsmith AI datasource (#31466)
## Description
Created a pre delete hook to delete datasource files on Appsmith AI
server when datasource is deleted in Appsmith instance.

#### PR fixes following issue(s)
Fixes https://github.com/appsmithorg/appsmith-ee/issues/3617

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

## Automation

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

## 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
- [x] 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
- [ ] 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**
- Introduced a new method `preDeleteHook` in the `PluginExecutor`
interface to serve as a hook after deleting a datasource.
- Added a new method `disassociateDatasource` in the AI plugin to notify
the AI server about datasource deletion and provide file context if
available.
- **Refactor**
- Enhanced the AI plugin by refactoring methods to use a new
`createAssociateDTO` method for generating `AssociateDTO` instances,
improving code readability and maintainability.
- **Chores**
- Updated the `archiveById` method in DatasourceServiceCEImpl to include
a `flatMap` operation that triggers a `preDeleteHook` method on the
plugin executor before archiving the datasource. Also added a new
private method `findPluginExecutor` for retrieving the plugin executor.
<!-- end of auto-generated comment: release notes by coderabbit.ai
--><!-- This is an auto-generated comment: Cypress test results -->
> [!IMPORTANT]  
> Workflow run:
<https://github.com/appsmithorg/appsmith/actions/runs/8338230830>
> Commit: `800915ea99c93663af34d08e8bcf4a14ad1356d0`
> Cypress dashboard url: <a
href="https://internal.appsmith.com/app/cypress-dashboard/rundetails-65890b3c81d7400d08fa9ee5?branch=master&workflowId=8338230830&attempt=2"
target="_blank">Click here!</a>
> All cypress tests have passed 🎉🎉🎉

<!-- end of auto-generated comment: Cypress test results  -->
2024-03-19 12:52:32 +05:30
Shrikant Sharat Kandula
89f3107621 Revert "chore: Add separate request/response views (#31640)"
This reverts commit 4cdbe89586.
2024-03-14 11:56:59 +05:30