Commit Graph

608 Commits

Author SHA1 Message Date
Nidhi
1741e61ba0
Added user roles list to application fetcher (#1624)
* Added user roles list to application fetcher

* Fixed blanket import
2020-11-09 11:54:30 +05:30
Nidhi
62e4e28c8e
Fixed upload logo payload limit and added delete logo API (#1574)
Also changed name of default organization to xyz's apps
2020-11-09 07:52:08 +05:30
Trisha Anand
24582a2e58
Adding server side performance tooling using spring metrics. (#1562)
* Experimenting with spring metrics, prometheus

* Added prometheus config in application.properties.

* Added a few more configurations for spring metrics to improve performance tooling.

* Added basic authentication to allow prometheus to scrape our monitoring data in an authenticated fashion.

* Only exposing prometheus end point at this junction instead of other metric endpoints as well.

* Fixed test case which failed because of actuator instantiating bean.
2020-11-05 14:33:40 +05:30
Sumit Kumar
6db7101662
Report selective errors to rollbar. (#1516)
* Report selective errors to rollbar.

1. Assign an action attribute to each AppsmithError enum item. Take action based on the action attribute.

* Fixing the condition for organization name being empty

* Report selective errors to rollbar.

1. Assign an action attribute to each AppsmithError enum item. Take action based on the action attribute.

Co-authored-by: Sumit Kumar <sumitsum@Sumits-MacBook-Pro.local>
Co-authored-by: Arpit Mohan <arpit@appsmith.com>
2020-11-04 17:32:43 +05:30
Nidhi
fc4fca8bf0
Added fallback email to new organization from user email (#1536) 2020-11-04 12:57:17 +05:30
Nidhi
c7efe55c9c
Fixed timeout error message, added new type of error for plugin timeout (#1519)
* Fixed timeout error message, added new type of error for plugin timeouts

* Switched error code and added test for a secondary StaleConnectionException
2020-11-04 12:56:52 +05:30
Trisha Anand
936ddc4fa0
Added indexes on NewPage and NewAction. Also made changes to the sorting order of actions when read in view and edit mode. (#1527) 2020-11-03 13:15:51 +05:30
Arpit Mohan
d087b8152d Fixing the condition for organization name being empty 2020-11-03 07:58:22 +05:30
Dmitriy Danilov
26da9ce60b
fix(organization-service): add check that organization is not empty (#1120)
Fixes ##774
2020-11-02 20:35:12 +05:30
imgbot[bot]
f5924c6895
[ImgBot] Optimize images (#1513)
*Total -- 1,942.96kb -> 1,638.83kb (15.65%)

/app/client/src/assets/icons/header/save-loading.gif -- 14.17kb -> 5.67kb (59.99%)
/app/client/src/assets/images/Postman.png -- 10.34kb -> 4.63kb (55.24%)
/app/client/src/assets/images/Google.png -- 11.18kb -> 5.62kb (49.76%)
/static/appsmith_logo_primary.png -- 8.02kb -> 4.06kb (49.34%)
/app/client/src/assets/images/appsmith_logo.png -- 8.02kb -> 4.06kb (49.34%)
/static/logo.png -- 13.20kb -> 7.77kb (41.11%)
/app/client/src/assets/images/no_image.png -- 4.94kb -> 2.97kb (39.97%)
/app/client/src/assets/images/query-image-outline.png -- 1.65kb -> 1.01kb (38.71%)
/app/client/src/assets/images/404-image.png -- 141.37kb -> 94.81kb (32.93%)
/app/server/appsmith-server/src/test/resources/test_assets/OrganizationServiceTest/my_organization_logo.png -- 1.77kb -> 1.20kb (32.41%)
/app/client/src/assets/images/appsmith_logo_white.png -- 1.88kb -> 1.29kb (31.17%)
/app/client/src/assets/icons/control/play-icon.png -- 2.00kb -> 1.39kb (30.15%)
/Query.png -- 219.82kb -> 155.18kb (29.41%)
/app/client/src/assets/images/Github.png -- 4.17kb -> 2.94kb (29.36%)
/API.png -- 332.87kb -> 239.07kb (28.18%)
/static/logo-no-padding.png -- 17.63kb -> 12.84kb (27.16%)
/app/client/src/assets/images/Curl.png -- 40.68kb -> 32.55kb (19.99%)
/app/client/src/assets/icons/ads/logout.svg -- 0.94kb -> 0.76kb (19.38%)
/app/client/src/assets/icons/menu/datasource-column.svg -- 0.64kb -> 0.52kb (19.15%)
/static/API2.png -- 167.58kb -> 140.36kb (16.24%)
/static/Query2.png -- 118.59kb -> 102.85kb (13.27%)
/app/client/src/assets/icons/ads/context-menu.svg -- 0.52kb -> 0.45kb (12.99%)
/app/client/src/assets/icons/help/github-icon.svg -- 2.63kb -> 2.34kb (10.85%)
/app/client/src/assets/icons/ads/search.svg -- 0.26kb -> 0.25kb (3.73%)
/app/client/src/assets/icons/widget/slash.svg -- 0.19kb -> 0.18kb (3.59%)
/app/client/src/assets/icons/widget/plus.svg -- 0.30kb -> 0.29kb (3.58%)
/app/client/src/assets/icons/widget/modal.svg -- 0.20kb -> 0.19kb (2.99%)
/app/client/src/assets/icons/ads/frame.svg -- 0.50kb -> 0.48kb (2.96%)
/app/client/src/assets/icons/menu/explorer.svg -- 0.19kb -> 0.18kb (2.11%)
/app/client/src/assets/icons/control/lightning.svg -- 0.23kb -> 0.23kb (2.1%)
/app/client/src/assets/icons/ads/product.svg -- 0.34kb -> 0.33kb (2.03%)
/app/client/src/assets/icons/widget/container.svg -- 0.20kb -> 0.19kb (1.99%)
/app/client/src/assets/images/placeholder-image.svg -- 0.15kb -> 0.14kb (1.99%)
/static/Share5.png -- 143.35kb -> 140.55kb (1.95%)
/app/client/src/assets/icons/form/info-outline.svg -- 1.77kb -> 1.73kb (1.93%)
/app/client/src/assets/icons/ads/file.svg -- 0.36kb -> 0.35kb (1.89%)
/app/client/src/assets/icons/ads/success.svg -- 0.26kb -> 0.25kb (1.88%)
/app/client/src/assets/icons/widget/input.svg -- 0.32kb -> 0.31kb (1.84%)
/app/client/src/assets/icons/ads/create-new.svg -- 0.23kb -> 0.22kb (1.73%)
/app/client/src/assets/icons/ads/book.svg -- 0.52kb -> 0.51kb (1.69%)
/app/client/src/assets/icons/control/email.svg -- 0.17kb -> 0.17kb (1.69%)
/app/client/src/assets/icons/ads/down_arrow.svg -- 0.18kb -> 0.18kb (1.63%)
/app/client/src/assets/icons/ads/upper_arrow.svg -- 0.18kb -> 0.18kb (1.63%)
/app/client/src/assets/icons/ads/bag.svg -- 0.42kb -> 0.42kb (1.61%)
/app/client/src/assets/icons/control/compact.svg -- 0.55kb -> 0.54kb (1.59%)
/app/client/src/assets/icons/help/openlink.svg -- 0.70kb -> 0.69kb (1.53%)
/app/client/src/assets/icons/help/document.svg -- 0.80kb -> 0.79kb (1.47%)
/app/client/src/assets/images/logo.svg -- 2.61kb -> 2.57kb (1.46%)
/app/client/src/assets/icons/ads/manage.svg -- 0.27kb -> 0.27kb (1.42%)
/app/client/src/assets/icons/ads/error.svg -- 0.35kb -> 0.34kb (1.4%)
/app/client/src/assets/icons/ads/view-all.svg -- 0.21kb -> 0.21kb (1.39%)
/app/client/src/assets/icons/control/pick-location-initial.svg -- 0.50kb -> 0.49kb (1.38%)
/app/client/src/assets/icons/menu/storage.svg -- 0.21kb -> 0.21kb (1.36%)
/app/client/src/assets/icons/ads/calender.svg -- 0.51kb -> 0.50kb (1.35%)
/app/client/src/assets/icons/menu/widgets-colored.svg -- 0.22kb -> 0.22kb (1.32%)
/app/client/src/assets/icons/control/input.svg -- 0.31kb -> 0.30kb (1.27%)
/app/client/src/assets/icons/header/share-white.svg -- 0.47kb -> 0.46kb (1.26%)
/app/client/src/assets/icons/control/pick-location-onclick.svg -- 0.48kb -> 0.48kb (1.21%)
/app/client/src/assets/icons/menu/datasource-table.svg -- 0.25kb -> 0.24kb (1.2%)
/app/client/src/assets/icons/form/add-new.svg -- 0.34kb -> 0.34kb (1.15%)
/app/client/src/assets/icons/ads/camera.svg -- 0.86kb -> 0.85kb (1.14%)
/app/client/src/assets/icons/widget/image.svg -- 0.35kb -> 0.35kb (1.11%)
/app/client/src/assets/icons/ads/shopper.svg -- 0.62kb -> 0.61kb (1.11%)
/app/client/src/assets/icons/control/sort-icon.svg -- 0.27kb -> 0.27kb (1.09%)
/app/client/src/assets/icons/menu/pages.svg -- 0.37kb -> 0.36kb (1.07%)
/app/client/src/assets/icons/ads/delete.svg -- 0.28kb -> 0.27kb (1.06%)
/app/client/src/assets/icons/menu/page.svg -- 0.37kb -> 0.37kb (1.06%)
/app/client/src/assets/icons/ads/workspace.svg -- 0.28kb -> 0.28kb (1.05%)
/app/client/src/assets/icons/control/download-table.svg -- 0.47kb -> 0.47kb (1.03%)
/app/client/src/assets/icons/control/help.svg -- 0.47kb -> 0.47kb (1.03%)
/app/client/src/assets/icons/control/close.svg -- 0.29kb -> 0.29kb (1.01%)
/app/client/src/assets/icons/control/move.svg -- 0.39kb -> 0.39kb (1%)
/app/client/src/assets/icons/ads/general.svg -- 0.29kb -> 0.29kb (1%)
/app/client/src/assets/icons/ads/duplicate.svg -- 0.30kb -> 0.30kb (0.96%)
/app/client/src/assets/icons/control/edit-white.svg -- 0.41kb -> 0.40kb (0.96%)
/app/client/src/assets/icons/control/view.svg -- 0.32kb -> 0.32kb (0.92%)
/app/client/src/assets/icons/header/feedback.svg -- 0.43kb -> 0.42kb (0.91%)
/app/client/src/assets/icons/control/remove.svg -- 0.33kb -> 0.33kb (0.89%)
/app/client/src/assets/icons/ads/heart.svg -- 0.79kb -> 0.79kb (0.86%)
/app/client/src/assets/icons/control/more-vertical.svg -- 1.02kb -> 1.01kb (0.86%)
/app/client/src/assets/icons/widget/rich-text.svg -- 1.60kb -> 1.58kb (0.86%)
/app/client/src/assets/icons/control/info.svg -- 0.34kb -> 0.34kb (0.85%)
/app/client/src/assets/icons/control/draggable.svg -- 0.47kb -> 0.47kb (0.83%)
/app/client/src/assets/images/API.svg -- 4.92kb -> 4.88kb (0.81%)
/app/client/src/assets/icons/widget/radio.svg -- 0.50kb -> 0.49kb (0.79%)
/app/client/src/assets/icons/ads/share.svg -- 0.37kb -> 0.37kb (0.79%)
/app/client/src/assets/images/EditPen.svg -- 0.38kb -> 0.37kb (0.78%)
/app/client/src/assets/icons/widget/collapse.svg -- 0.50kb -> 0.50kb (0.78%)
/app/client/src/assets/icons/control/edit.svg -- 0.65kb -> 0.65kb (0.75%)
/app/client/src/assets/icons/ads/user.svg -- 0.54kb -> 0.53kb (0.73%)
/app/client/src/assets/icons/widget/checkbox.svg -- 0.54kb -> 0.53kb (0.73%)
/app/client/src/assets/icons/ads/edit.svg -- 0.40kb -> 0.40kb (0.73%)
/app/client/src/assets/icons/control/collapse.svg -- 0.55kb -> 0.54kb (0.71%)
/app/client/src/assets/icons/menu/queries.svg -- 0.41kb -> 0.41kb (0.71%)
/app/client/src/assets/icons/ads/close.svg -- 0.42kb -> 0.42kb (0.7%)
/app/client/src/assets/images/NoSearchResult.svg -- 8.61kb -> 8.55kb (0.69%)
/app/client/src/assets/icons/widget/chart.svg -- 0.43kb -> 0.43kb (0.68%)
/app/client/src/assets/icons/control/decrease.svg -- 0.45kb -> 0.45kb (0.65%)
/app/client/src/assets/icons/menu/api.svg -- 1.51kb -> 1.50kb (0.65%)
/app/client/src/assets/icons/widget/filepicker.svg -- 0.61kb -> 0.60kb (0.64%)
/app/client/src/assets/icons/ads/launch.svg -- 0.61kb -> 0.61kb (0.64%)
/app/client/src/assets/icons/menu/homepage.svg -- 0.92kb -> 0.92kb (0.64%)
/app/client/src/assets/icons/control/launch.svg -- 0.62kb -> 0.61kb (0.63%)
/app/client/src/assets/icons/control/pick-location-selected.svg -- 0.48kb -> 0.48kb (0.61%)
/app/client/src/assets/icons/widget/video.svg -- 0.49kb -> 0.49kb (0.6%)
/app/client/src/assets/icons/control/currency.svg -- 0.50kb -> 0.49kb (0.59%)
/app/client/src/assets/icons/control/filter-icon.svg -- 0.84kb -> 0.84kb (0.58%)
/app/client/src/assets/icons/control/search.svg -- 0.55kb -> 0.54kb (0.54%)
/app/client/src/assets/icons/control/zoomout.svg -- 0.55kb -> 0.55kb (0.53%)
/app/client/src/assets/icons/form/lock.svg -- 0.56kb -> 0.56kb (0.52%)
/app/client/src/assets/icons/control/multiline.svg -- 1.51kb -> 1.50kb (0.52%)
/app/client/src/assets/icons/ads/flight.svg -- 1.33kb -> 1.32kb (0.51%)
/app/client/src/assets/icons/control/pick-my-location.svg -- 1.16kb -> 1.16kb (0.5%)
/app/client/src/assets/icons/ads/chat.svg -- 1.36kb -> 1.35kb (0.5%)
/app/client/src/assets/icons/widget/table.svg -- 0.78kb -> 0.78kb (0.5%)
/app/client/src/assets/icons/control/delete.svg -- 0.59kb -> 0.59kb (0.5%)
/app/client/src/assets/icons/control/phone.svg -- 0.59kb -> 0.59kb (0.5%)
/app/client/src/assets/icons/control/password.svg -- 1.97kb -> 1.96kb (0.49%)
/app/client/src/assets/icons/widget/alert.svg -- 0.81kb -> 0.81kb (0.48%)
/app/client/src/assets/icons/control/right-align.svg -- 0.62kb -> 0.61kb (0.48%)
/app/client/src/assets/icons/ads/invite-users.svg -- 0.64kb -> 0.64kb (0.46%)
/app/client/src/assets/icons/widget/tabs.svg -- 0.86kb -> 0.85kb (0.46%)
/app/client/src/assets/icons/control/columns-visibility.svg -- 1.08kb -> 1.07kb (0.45%)
/app/client/src/assets/icons/control/zoomin.svg -- 0.65kb -> 0.65kb (0.45%)
/app/client/src/assets/icons/control/left-align.svg -- 0.67kb -> 0.67kb (0.44%)
/app/client/src/assets/icons/control/underline.svg -- 0.68kb -> 0.68kb (0.43%)
/app/client/src/assets/icons/ads/globe.svg -- 1.60kb -> 1.59kb (0.43%)
/app/client/src/assets/icons/menu/widgets.svg -- 0.97kb -> 0.97kb (0.4%)
/app/client/src/assets/icons/widget/text.svg -- 0.99kb -> 0.98kb (0.4%)
/app/client/src/assets/icons/control/center-align.svg -- 0.76kb -> 0.76kb (0.38%)
/app/client/src/assets/icons/widget/location-picker.svg -- 1.02kb -> 1.02kb (0.38%)
/app/client/src/assets/icons/menu/overflow-menu.svg -- 1.05kb -> 1.05kb (0.37%)
/app/client/src/assets/icons/header/deploy.svg -- 1.59kb -> 1.59kb (0.37%)
/app/client/src/assets/icons/control/italics.svg -- 0.80kb -> 0.80kb (0.36%)
/app/client/src/assets/icons/control/increase.svg -- 0.81kb -> 0.81kb (0.36%)
/app/client/src/assets/icons/help/discord.svg -- 1.08kb -> 1.08kb (0.36%)
/app/client/src/assets/icons/widget/map.svg -- 1.10kb -> 1.09kb (0.36%)
/app/client/src/assets/images/email-not-configured.svg -- 28.71kb -> 28.61kb (0.35%)
/app/client/src/assets/icons/help/help.svg -- 1.15kb -> 1.15kb (0.34%)
/app/client/src/assets/icons/control/copy.svg -- 0.87kb -> 0.86kb (0.34%)
/app/client/src/assets/icons/control/bold.svg -- 0.88kb -> 0.88kb (0.33%)
/app/client/src/assets/icons/widget/dropdown.svg -- 1.21kb -> 1.21kb (0.32%)
/app/client/src/assets/icons/ads/billing.svg -- 0.96kb -> 0.95kb (0.31%)
/app/client/src/assets/icons/control/decimal.svg -- 0.98kb -> 0.97kb (0.3%)
/app/client/src/assets/icons/control/settings.svg -- 1.33kb -> 1.32kb (0.29%)
/app/client/src/assets/icons/control/chevron-down.svg -- 1.02kb -> 1.02kb (0.29%)
/app/client/src/assets/icons/widget/switch.svg -- 1.38kb -> 1.37kb (0.28%)
/app/client/src/assets/images/secure.svg -- 1.07kb -> 1.07kb (0.27%)
/app/client/src/assets/icons/menu/datasource-colored.svg -- 1.12kb -> 1.12kb (0.26%)
/app/client/src/assets/icons/menu/api-colored.svg -- 1.13kb -> 1.12kb (0.26%)
/app/client/src/assets/icons/menu/foreign-key.svg -- 1.15kb -> 1.15kb (0.26%)
/app/client/src/assets/icons/menu/org.svg -- 1.15kb -> 1.15kb (0.25%)
/app/client/src/assets/icons/control/redo.svg -- 1.17kb -> 1.16kb (0.25%)
/app/client/src/assets/icons/menu/primary-key.svg -- 1.17kb -> 1.17kb (0.25%)
/app/client/src/assets/icons/control/undo.svg -- 1.17kb -> 1.17kb (0.25%)
/app/client/src/assets/icons/form/trash.svg -- 2.75kb -> 2.74kb (0.25%)
/app/client/src/assets/icons/control/integer.svg -- 1.25kb -> 1.25kb (0.23%)
/app/client/src/assets/icons/widget/form.svg -- 1.32kb -> 1.32kb (0.22%)
/app/client/src/assets/icons/control/drag.svg -- 1.33kb -> 1.33kb (0.22%)
/app/client/src/assets/icons/header/save-failure.svg -- 1.45kb -> 1.44kb (0.2%)
/app/client/src/assets/icons/control/js-toggle.svg -- 1.97kb -> 1.96kb (0.2%)
/app/client/src/assets/images/Curl-logo.svg -- 5.33kb -> 5.32kb (0.18%)
/app/client/src/assets/icons/alert/info.svg -- 1.60kb -> 1.60kb (0.18%)
/app/client/src/assets/icons/alert/warning.svg -- 1.63kb -> 1.63kb (0.18%)
/app/client/src/assets/icons/header/save-success.svg -- 1.67kb -> 1.66kb (0.18%)
/app/client/src/assets/icons/alert/success.svg -- 1.67kb -> 1.67kb (0.18%)
/app/client/src/assets/icons/menu/data-sources.svg -- 1.74kb -> 1.73kb (0.17%)
/app/client/src/assets/icons/alert/error.svg -- 1.95kb -> 1.95kb (0.15%)
/app/client/src/assets/icons/widget/datepicker.svg -- 3.23kb -> 3.22kb (0.12%)
/app/client/src/assets/icons/widget/button.svg -- 3.75kb -> 3.75kb (0.1%)
/app/client/src/assets/icons/control/address.svg -- 3.37kb -> 3.37kb (0.09%)
/app/client/src/assets/icons/control/datepicker.svg -- 3.75kb -> 3.75kb (0.08%)
/app/client/src/assets/images/appsmith-datasource.svg -- 505.60kb -> 505.43kb (0.03%)

Signed-off-by: ImgBotApp <ImgBotHelp@gmail.com>

Co-authored-by: ImgBotApp <ImgBotHelp@gmail.com>
2020-11-02 19:44:01 +05:30
Trisha Anand
32301ae3b4
Printing the invalid messages of the action properly. (#1507) 2020-11-02 14:15:29 +05:30
Trisha Anand
13e2cc2a63
[Do Not Merge]Brought down cloud migration time from 122 minutes to 9.5 minutes (#1441)
* [Do Not Merge]Brought down cloud migration time from 122 minutes to 9.5 minutes

* Removed commented code.
TODO : Figure out if we want to change the migration order numbers once the release environment is reverted back to pre original migration data.

* Added plugin id for the migrated action.

* Renamed the createIndex functions for new action and new page and added a drop collection command before creating the index. This ensures that if any developer has pulled code in the last two days, this migration does not negatively impact them
2020-10-29 15:03:41 +05:30
Nikhil Nandagopal
2d7ccdc515
flipped user id and instance id so that the ping can be correlated with the email from the install script (#1461) 2020-10-29 14:17:45 +05:30
Arpit Mohan
470f2fafcd
Adding support for https endpoints for ES plugin (#1445)
* Adding host:port validation checks to ES plugin & Redis plugin

Also correcting the assertions in the RedisPluginTest so that the error message on test failure is accurate.

* Removing the endpoint validation from datasourceServiceImpl

Moving the endpoint validation to the plugin implementation classes because there are databases that require complete HTTP URL in their configuration. Checking for http/https at the platform level affects the UX for the user & plugin developer when using a new integration. Hence, all plugins must implement their own client/server validations in their own implementations

* Adding tests to assert hostname validation in mysql & postgres plugins
2020-10-28 19:06:10 +05:30
Trisha Anand
5197b17d8c
Bug Fix : Reading the datasource configuration incorrectly from actionDTO instead of datasource object. (#1415)
* Bug Fix : Reading the datasource configuration incorrectly from actionDTO instead of datasource object.

* Added test case to assert that datasource configuration and action configurations are not null when action execute is called.
2020-10-27 15:23:25 +05:30
Trisha Anand
230126ebcf
Remove unnecessary database migration (#1406) 2020-10-26 22:50:36 +05:30
Trisha Anand
fc9ea45e3b
[API breaking change : Automated Tests Will Fail] Page And Action Refactor (#549)
* Introduced new page which stores the published and unpublished pages as separate.

* Mid level commit to save the state.

* Parity of new page repository with old page repository (custom functions)

* WIP : Delete a page. This requires changes across application structure as well.

* Added publishedPages construct inside application to store the pages in the deployed view as well as isDefault so that the same changes (delete or isDefault) in unpublished view doesn't alter these fields for the published application

* Parity reached with PageService.

* Minor ActionService refactor to remove unnecessary code.
ApplicationPageService, LayoutActionService, LayoutService use the new page service to fetch the pages
Minor corrections in fetching the page from new page service in tests

* New save function which sets the PageDTO for unpublished page and then saves the new page into repository.

* Migration of page service functions to new page service functions across other services/tests/controller

* Finished migrating all the page service functions to the new page service functions

* Application Service Tests have been fixed.

* All the existing test cases are working now.

* Publish application implemented to store published pages as well. Added a basic test case to check that published pages is being set and that page's publishedPageDTO is being set accordingly.

* Minor TODOs added to add test cases for published application.

* A few tests to ascertain that published application page fields (deleted, isDefault) does not get changed when these statuses are changed for a page in edit mode.

* Added a new controller end point to fetch application in view mode.

* Added new endpoint for fetching an application in view mode on the client.

* Bug fix where get application in view mode API was not getting called.

* Fixed the get page names by application & archive pages which have been deleted in edit mode during publishing of application.

* During delete page, if a page was never published and it was deleted during edit, delete the entire page instead of just deleting the unpublished PageDTO

* Minor formatting.

* Non working client side code to fetch page list using view mode.

* revert unnecassary changes and streamlined view and edit actions

* Fix missed import

* Fixed a bug where if a page is not published, it should not be returned in view mode in list of page names api.

* Fixed update for a page which was not working in integration test.

* ActionDTO added.

* Solidified the new action structure.

* Migration added for NewAction index creation and NewAction per Action insertion in the database.

* Basic file structure added the new repository, custom repository, service, etc.

* Delete OldPage.java

* Repo functions added - TODO : Haven;t handled the published/edited views

* Helper functions added to convert Action to NewAction and vice-versa. Removed unused currentUserMono usage.

* Create & update action functionality added.

* Execute Action refactored. Removed dry run specific code.

* Repository migrated to handle new data structure. Execute action refactored to no longer support dry runs of actions.

* TODO added for special handling of change view of application to handle edge cases of pages/actions which either exist in published mode but don't exist in unpublished mode or vice versa.

* Migrated finding on load actions from spring repository to custom repository.

* In view mode, now actions are being fetched by application id directly instead of first fetching application and then using the page ids, fetching the actions. This reduces the db calls from 2 to 1 per fetch actions in view mode api call.

* Delete action and get all actions (used in edit mode on the client side) implemented.

* Updated CollectionService and ActionCollectionService to use the new action service instead of the old one.

* LayoutActionService refactored to now use the new service functions.

* ActionController now no longer used ActionService. The remaining service functions have been migrated to the new action service.

* Refactor across ACL code for addition/removal of policies during addition/removal of users to organization, making app public, refactor for services like policy utils, item service, etc.

* Removed the last of action repository and action service and replaced with new action repo and new action service.

* Compile and run time issues fixed. The server is coming up without any spring dependency errors.

* WIP in fixing fetching actions by page id.

* Finally!!! Fixed the fetch actions (both published and unpublished actions) by page id repository function.

* Fixed create action bug where null datasource in published actiondto (inside newly created action) leads to error.

* Fixed the execute action issues :
1. Removed the dry runs from the tests
2. Fixed the null pointer error in variable substituted action and datasource configurations.

* 1. Fixed the custom action repository field names.
2. Fixed the data structures used in ExamplesOrganizationClonerTests

* Fixed countByDatasourceId repository function which was querying the actions incorrectly.

* Fixed the clone example organization error where the id of the action was not getting updated in the page correctly. Yay!

* Fixed post merge compilation failure.

* Fixed more compilation time failures in ActionServiceTest

* Fixed failing test case for fetching actions in view mode.

* Minor changes to resolve merge changes and incorporate in the new refactored code.

* 1. Fixed compile time errors on Client code.
2. Fixed fetching of actions in view mode by application id. The repository function did not need name parameter. Removed the same.

* [Integration Testing Error Fix] : Added a new test case for refactor action name.

* Instead of fetching actions in the page, mistakenly used the base service which was fetching all the actions in the repository, barring none which led to the name refactor being blocked even though no action in the current page exists with the new proposed name,

* Added delete functionality to action service.

* Minor code cleanup

* Adding viewMode to action execution

* Replacing action with actionId.

* 1. Bug fix for deletion of unpublished action. In case of never published action, the entire action should be deleted. In case an action was published, only the unpublished action should be deleted.
2. In case of DB actions (external datasources), only the bare minimum fields should be stored inside the action (datasource id and datasource plugin id). The other fields should not be duplicated across code.

* Fixed yarn build compilation issues.

* Update app/server/appsmith-server/src/main/java/com/appsmith/server/controllers/ActionController.java

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

* Changed the API path for GET applications in view mode. Some minor code formatting.

* Incorporated review comments.

* Some more unnecessary code removed.

* Instead of returning Page, now the interface object between client and server for Pages is PageDTO

* Migrated Page and Action to PageDTO and ActionDTO
Fixed the compilation issues.
TODO : Fix the test compilation issues.

* Fixed compilation time issues with all the tests by migrating Page and Action to PageDTO and ActionDTO respectively

* Action Controller and Page Controller no longer extend Base Controller. All the required functions have now been implemented and no base line API end points are being re-used from the base.

* Test case fixes.

* Bug Fix : Updating an action was not updating execute on load. Fixed the data flow leading to the error.

* Deprecating Page and Action domain objects. This is to ensure no new code is written with these till we remove this old code.

* Cloned example applications are now published before returning. This is to ensure that the applications are in ready to view mode when the new user signs up.

* Added a function comment to expand on the usage of new param introduced.

* When cloning a page, new actions were not being stored. Added that. Also updated the clonePage test to assert that the actions are also cloned when the pages are cloned.

* Updated a Api call

* removed extra slash

Co-authored-by: Hetu Nandu <hetunandu@gmail.com>
Co-authored-by: Satbir Singh <satbir121@gmail.com>
Co-authored-by: Arpit Mohan <mohanarpit@users.noreply.github.com>
Co-authored-by: nandan.anantharamu <nandan@thinkify.io>
2020-10-26 18:04:23 +05:30
Arpit Mohan
c6d4902e3d
Adding microsoft SQL server plugin integration (#1374) 2020-10-23 20:36:45 +05:30
Shinn Lok
4768fd3848
Fix organization ordering by name on the homepage (#1177) 2020-10-22 17:53:51 +05:30
Arpit Mohan
74fe08f8bf
Adding the database changelog for Redis (#1346)
1. Fixing the build by excluding the slf4j-api from redis-plugin pom.xml
2. Adding the editor.json and form.json for the query pane & datasource pane.
3. Adding array handling in the Redis response by feeding all the output into a "result" key
2020-10-22 16:40:19 +05:30
Shrikant Sharat Kandula
2a53abd8a6
Add DynamoDB Plugin (#1167)
* Added DynamoPlugin to integrate with DynamoDB

* Connection management for DynamoPlugin

* Process action from a single JSON object as input

* Moved ListTables command to separate class

* Add missing UI definition files

* Use reflection to build request objects for AWS SDK

* All DynamoDB actions are now run purely by reflection

* Serialize responses to JSON

* Remove some unused/commented code and some refactorings

* Add non-working test with generic dynamodb container

* Added working test for ListTables action

* Added test for PutItem action

* Add tests for get and update actions

* Added comments and some refactoring

* Removed unused Command class.

* Added more tests for map to SDK object conversion

* Add templates

* Add option to set an endpoint override

* Fix Dynamo plugin tests when ~/.aws is missing

* Add documentation link for DynamoDB plugin

* Fix validation checks

* Remove debug log

* Added comments on expected query structure

* Fix incorrect error condition with incorrect request format

* Add comment for converting action to method name

* Error out if region is missing

* Remove unused throws declaration

* Use rich form for action configuration

* Removed templates

* Use PNG for logo images

* Use PNG logos for all plugins

* Avoid hard-coded field names

* Change logo to PNG only for ElasticSearch for now

* Wrap errors in AppsmithPluginException

* Typo

Co-authored-by: Trisha Anand <trisha@appsmith.com>

* Fix changeset order number

Co-authored-by: Trisha Anand <trisha@appsmith.com>

* Minor refactoring and fixed error messaging

Co-authored-by: Trisha Anand <trisha@appsmith.com>
2020-10-21 17:45:54 +05:30
Shrikant Sharat Kandula
fa1a0549ff
Add ElasticSearch integration (#1181)
* add elasticSearchPlugin

* Fix container startup in tests

* Add elasticsearch dependency

* Get plugin to a base working state

* Add templates and tests for all Document APIs

* Add support for bulk queries

* Add test and template for bulk operations

* Use rich form for action configuration

* Add test API for ElasticSearch

* Use rich form's values for plugin execution

* Add authorization header support

* Fix tests after config object use changes

* Add test for bulk requests with nd-json body

* Remove templates and minor refactoring

* Fix potential NPE with null body

Co-authored-by: Trisha Anand <trisha@appsmith.com>

* Add datasource validation for endpoint

* Wrap errors in AppsmithPluginException

Co-authored-by: Suman Patra <spatra@akamai.com>
Co-authored-by: Trisha Anand <trisha@appsmith.com>
2020-10-21 15:34:29 +05:30
Shinn Lok
014ff80548
Parameter missing for email template replace (#1323)
Co-authored-by: Trisha Anand <trisha1990@gmail.com>
2020-10-21 11:40:32 +05:30
Arpit Mohan
c89f5179b3 Removing db changelog for mssql 2020-10-20 22:46:59 +05:30
Arpit Mohan
f507cc8a0e Changing version for commons-validator 2020-10-20 19:47:30 +05:30
Trisha Anand
870a38af1c
[Bug Fix] Removed create_USER event during userCreate because this breaks OAUTH first user login. (#1292) 2020-10-19 22:51:26 +05:30
Arpit Mohan
7cb9583034 Making the request to oauth2 endpoints publicly accessible 2020-10-19 19:52:27 +05:30
Sufiyan Gani
f52a2500c1
Added sending email when the role of the member is (#1253)
Added sending email when the role of a member is changed
2020-10-19 17:53:12 +05:30
Trisha Anand
37aedcba24
User emails should be changed to lower case before creating/inviting user. (#1281) 2020-10-19 16:39:04 +05:30
Shrikant Sharat Kandula
a8d5138541
MS SQL Plugin implementation (#1272)
* Working version of MsSQL plugin

* Add tests for mssql-plugin
2020-10-19 15:06:08 +05:30
Akshay Avinash
4e99ab7ace
Fix 781 invalid message on password reset failure (#1234)
* Updated to add button to redirect to forgot password page
2020-10-16 19:48:03 +05:30
Daniel Shuy
a93bd52684
Don't append " Copy" suffix to cloned pages in cloned application (#1172)
* Add test to verify that Pages are cloned
2020-10-15 23:27:32 +05:30
Prashant Chaubey
7a1a2f55e1
Added an WebExceptionHandler to return JSON errors instead of HTML (#1178) 2020-10-15 17:47:13 +05:30
Shrikant Sharat Kandula
921c827817
Add isFromInvite field to create_USER event (#1223) 2020-10-15 17:42:37 +05:30
Prashant Chaubey
05380a9c43
Added email verification while creating user and sending email (#1208) 2020-10-15 12:19:20 +05:30
Prashant Chaubey
8d2701ed75
Made getAll operation of PageController unsupported (#1176) 2020-10-15 11:24:09 +05:30
Prashant Chaubey
67ef538409
Returning validation failures while creating organization (#1084)
* Returning validation failures while creating organization

* Added unit tests

* Changing the name of test security config

Co-authored-by: nitesh261193 <nitesh261193@gmail.com>
2020-10-15 09:07:57 +05:30
Shinn Lok
e85d5ed420
TTL must be set on date field (#1128)
The PasswordResetToken collection now expires the password reset request in 48 hours.
2020-10-15 09:01:30 +05:30
Shrikant Sharat Kandula
ff860e402c
Add logging to segment SDK (#1188) 2020-10-15 00:05:09 +05:30
Shrikant Sharat Kandula
8af1852b6a
Refactor tasks on first-login (#1190)
* Primarily doing example app cloning and analytics in parallel.

* Only create a examples organization, if not already done
2020-10-15 00:02:57 +05:30
Shrikant Sharat Kandula
02dc63840a
Don't send full object to analytics (#1186) 2020-10-14 14:56:09 +05:30
Shrikant Sharat Kandula
164824ca85
Add first_login event for analytics (#1184) 2020-10-14 12:40:47 +05:30
Prashant Chaubey
8a892b6e15
Removed invitation token from the invite email (#1180) 2020-10-14 10:30:19 +05:30
Trisha Anand
421b624cc4
Only mark applications as example applications if the application id exists in the template configuration. (#1093) 2020-10-09 15:21:28 +05:30
Shrikant Sharat Kandula
d872b3631b
Use username instead of object_id in analytics (#1082) 2020-10-09 12:47:27 +05:30
Trisha Anand
ffb1142b20
Adding a new email template for sending an email when an appsmith use… (#1077)
* Adding a new email template for sending an email when an appsmith user's role in an organization changes.

* Minor changes in text.
2020-10-08 14:48:41 +05:30
Shrikant Sharat Kandula
feda7ce022
Use email as id for users and fix signup events not being reported (#1067) 2020-10-07 21:06:58 +05:30
Shrikant Sharat Kandula
c77fcfa9ee
Send separate user create event for new users (#1066) 2020-10-07 18:28:17 +05:30
Shrikant Sharat Kandula
c4332b9a1c
Add source to user sign up event (#1065) 2020-10-07 18:07:30 +05:30
Prashant Chaubey
50072ff179
Fixed the ipify URL in PingScheduledTask (#1013) 2020-10-06 06:54:27 +05:30