Commit Graph

19 Commits

Author SHA1 Message Date
Abhijeet
7e339d419d
test: Enable server tests for the PRs with base PG branch (#33429)
## Description
1. PR to enable server tests on PRs with `pg` as the base branch. 
2. Replace the DB URI from `APPSMITH_MONGODB_URI` to `APPSMITH_DB_URL` 

## Automation

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

### 🔍 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/9174148396>
> Commit: 762b4255f654946a1a47a196df5a1afae5be09f2
> Cypress dashboard url: <a
href="https://internal.appsmith.com/app/cypress-dashboard/rundetails-65890b3c81d7400d08fa9ee5?branch=master&workflowId=9174148396&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

---------

Co-authored-by: Shrikant Sharat Kandula <shrikant@appsmith.com>
2024-05-22 15:55:20 +05:30
Shrikant Sharat Kandula
92993cccef
chore: Remove unused services (#30292)
I've been doing this in pieces bit by bit, not to rock the boat too much
too fast, but it's taking too long, and too much effort. Instead opting
for a rip-the-bandaid style, hopefully without the pain.
2024-01-23 05:43:16 +05:30
Nidhi
9d31458683
fix: Updated server set up docs to lower confusion from logs (#22926)
Documentation update for server side set up, and a change to default
value in env variables for Mongo to comply with the one we are using in
the set up docs, to allow for a quick start and lower chance of failure.
2023-05-03 10:17:34 +05:30
Abhijeet
9f6ef23f5a
feat: Support mongodb transactions for import application flow (#14939)
## Description

Import application flow is a multi-stage process where we touch all the
mongo DB collections required to store the application in DB, which
today includes pages, actions, JSObjects, etc. When the flow is complete
then only we can say the application is successfully imported and DB
won't have any stale objects stored. But in a negative scenario where
the flow might break because of some unknown exceptions, objects stored
earlier become stale and reside in DB forever. With this PR we are
establishing the infra for transactions to avoid saving stale DB
objects. This is achieved by a rollback mechanism in case an exception
is thrown in the middle of execution.

Note: Since transactions are built on concepts of logical sessions they
require mecahnics (like oplog) which are only available in replica set
environment.

You can always convert a standalone to a single noded replica set and
transactions will work with this one node.


[https://docs.mongodb.com/manual/tutorial/convert-standalone-to-replica-set/](https://docs.mongodb.com/manual/tutorial/convert-standalone-to-replica-set/?_ga=2.53712296.1453502529.1669195955-2065030687.1664009965)

```
For local dev earlier we used to run the single node without replica set. Henceforth if we want to take the advantage of transactions please follow the steps to run mongod single node in local with replica set:

- Upgrade the MongoDB version to 4.4 or higher if it’s 4.2 or lower (https://www.mongodb.com/docs/manual/release-notes/4.4/#std-label-4.4-upgrade)
- Close the mongoDB instance running in your local
- Start the mongoDB in replica set mode and initiate the replica set
    - mongod --port 27017 --dbpath <path/to/db> --replSet <replica-set-name> && mongo --eval “rs.initiate()”
- One can use following commands to check replica set status: 
    - mongo appsmith
    - rs.status()
- By this time you should have the mongo running with replica set
```
<img width="1788" alt="Screenshot 2022-07-01 at 10 31 27 PM"
src="https://user-images.githubusercontent.com/41686026/176944386-f9d94715-c0cf-4900-93b7-f73647132d60.png">

This also means mongodb connection string used in env file will now
include the replica-set name if one wants to leverage transactions:
`mongodb://localhost:27017/appsmith?replicaSet={replica-set-name}`

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

## Type of change

- Bug fix (non-breaking change which fixes an issue)
- This change requires a documentation update

## How Has This Been Tested?

> JUnit 
> Manual test

## Checklist:

- [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
- [ ] 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

---------

Co-authored-by: Anagh Hegde <anagh@appsmith.com>
Co-authored-by: Aishwarya UR <aishwarya@appsmith.com>
2023-02-09 14:50:04 +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
Trisha Anand
a7f1f365af
Revert "ci:update env variable" (#18607)
Revert "ci:update env variable (#18557)"

This reverts commit e0fe306503.
2022-12-01 16:08:02 +05:30
Parthvi
e0fe306503
ci:update env variable (#18557)
Co-authored-by: Shrikant Sharat Kandula <shrikant@appsmith.com>
2022-12-01 13:47:11 +05:30
Ankita Kinger
13fe125a0c
feat: Add disconnect button on auth config pages and form login callout banner (#11389)
* added form login callout banner

* form login config page changes

* form login config page changes

* added redirecturl and uneditable field components

* added disconnect button on auth pages

* Added env variables for form login auth page

* added disconnect button on auth pages

* updated docs link for dform login callout doc

* added condition for disconnect button

* added ce changes done on ee

* updated css

* suggested changes in PR review

* suggested changes in PR review

* suggested changes in PR review

* reverted gitignore files changes

* reverted gitignore files changes

* updated logic for saving admin settings

* removed unused imports

* added changes for taginput field

* removed console

* removed warning

* removed unwanted changes
2022-03-02 23:48:50 +05:30
Nidhi
5434d25735
fix: Added client side execution logic and on page load logic for js (#9392)
* fix: Added client side execution logic and on page load logic for js

* Revert dev env

* Revert dev env

* Updated tests expectation partly to break PR

* fix: Reverted test breakage for this PR
2021-12-01 22:02:43 +05:30
Abhijeet
51addbc963
Feature/import-export-application (#4553)
* Decryption for dbauth, basic and OAuth datasources added in exported file

* All authentications for datasources included while exporting as deserialization is done through json file otherwise cast is throwing error

* Content-Disposition header implemented 

* MongoEscapedWidget names segregated for published and unpublished layout, to prevent overwrite while exporting

* Published pages and actions explicitly handled in cases where unpublished resources are deleted
2021-06-01 17:38:26 +05:30
Confidence Okoghenun
639cba9095
Improve server setup experience documentation (#4441)
* fix: Updates appsmith server docker-compose

* fix: Updates server docker-compose

* fix: Removes exposed ports

* docs: Adds updates for server docker-compose

* docs: Adds updates for server docker-compose

* docs: Updates app/server/README.md

Co-authored-by: Arpit Mohan <mohanarpit@users.noreply.github.com>

* chore: Removes deprecated env vars

Co-authored-by: Arpit Mohan <mohanarpit@users.noreply.github.com>
2021-05-19 19:29:08 +05:30
Nidhi
53c2d815f6
Fixes refresh token flow (#4450)
* Fixes refresh token flow

* Review comments

* Reverting mistake with CI cs url
2021-05-12 17:07:59 +05:30
Nidhi
683176fc48
Increased default limit for webclient payload (#3718)
* Increased default limit for webclient payload
2021-03-26 21:34:10 +05:30
Abhishek
0b4adf198d
Add recaptcha verification for user signup on the server (#3383)
Co-authored-by: Abhishek <abhishek.ak@bytedance.com>
2021-03-11 07:25:01 +05:30
Sumit Kumar
b03e815952
Change Sentry log 'environment' tag value. (#1789)
* Change Sentry log 'environment' tag value.

1. Change Sentry log 'environment' tag value to 'Properties' from 'properties'.
2020-11-19 17:29:48 +05:30
Arpit Mohan
790ad71a2c
Adding more details to Contributing.md for server compilation (#582) 2020-09-19 12:56:42 +05:30
Trisha Anand
fd0f23b9cc
Database credentials encryption in MongoDB (#80)
* Encrypting the password stored in AuthenticationDTO for every db.

* Adding comment to the properties file to denote that adding encryption salt and password are mandatory to the server coming up.

* Added the encryption salt and password to server.yml to allow the github actions to succeed.

* Adding database migration to encrypt the existing passwords for authentication object (used for storing db connection username/password)

Changes to the installation script install.sh:

1. Instead of overwriting the existing encryption password or salt, giving the user an option to conserve the previous encryption credentials to ensure that the developer users do not lose access to their database configurations (passwords).
2. Added another file for writing encryption credentials (encryption.env) to ensure that we dont delete the encryption password and salt by mistake.
2020-07-14 14:45:08 +05:30
Trisha Anand
4a720b80e2
Removing the marketplace basic auth credentials which was hard coded into the code to environment variable. (#71) 2020-07-09 22:38:21 +05:30
Shrikant Sharat Kandula
56547ec02f
Move application configuration to be loaded from environment variables (#23)
* Move application configuration to be loaded from environment variables
* Remove unused sentry.properties
* Make missing value sentinel a constant and ignore all *.env files
* Removed now-used ACL properties
* Prefix RapidAPI environment variable with APPSMITH_
* Fix application properties not being loaded into static fields
* Remove application-test.properties file
* Add required env variables for test in GitHub
* Quote URLs for MongoDB and Redis in test config
* Change RAPIDAPI to RAPID_API in environment variable names
* Source .env file in the root of repo in start script
2020-07-06 14:35:56 +05:30