Commit graph

1695 commits

Author SHA1 Message Date
Conor Macpherson
4bd3701363 remove new model in favor of making self hosted confirm payment method request more generic. 2023-04-12 14:15:11 -04:00
Conor Macpherson
451f169fea use a more generic model for self hosted confirm payment method. 2023-04-12 14:12:28 -04:00
Conor Macpherson
77e1fbfbc8 Change error upon failure of true up review submission to CWS. 2023-04-12 10:12:33 -04:00
Conor Macpherson
382894b41c revert change to show true up review when telemetry is enabled, always send true up data to CWS for telemetry capture. 2023-04-12 09:56:46 -04:00
Claudio Costa
b00ca20abe
[MM-50827] Detect content-type if missing in response during link metadata generation (#22885)
* Detect content-type if missing in response during link metadata generation

* Initialize buffer only when necessary
2023-04-12 07:53:03 -06:00
Ben Schumacher
4cc370098e
[MM-26398] Remove deprecated model.CommandArgs.Session (#22815) 2023-04-12 01:10:59 +02:00
Conor Macpherson
33d3c90654 Add mocks/layers. 2023-04-11 14:15:56 -04:00
Conor Macpherson
dd2e325c24 Ensure admins can send true up telemetry, even if telemetry is disabled. 2023-04-11 12:52:54 -04:00
Agniva De Sarker
bf952e690b
MM-52088: Skip Flaky test (#22910)
https://mattermost.atlassian.net/browse/MM-52088

```release-note
NONE
```
2023-04-11 21:40:42 +05:30
Julien Tant
6e7759b314
[MM-51844 & MM-51843] Work template permissions check (#22825) 2023-04-10 09:51:20 -07:00
Agniva De Sarker
bcf115e315
Upgrade mockery to fix errors (#22892)
Mockery started to throw errors like "Unexpected package creation during export data loading".

This was consistently reproducible locally and on upgrade, it has gone away.

```release-note
NONE
```
2023-04-10 14:20:57 +05:30
Jesse Hallam
4b7f6cb974
bind to localhost:0 for tests (#22839)
* bind to localhost:0 for tests

Explicitly bind to `localhost:0` instead of just `:0` to avoid binding to all available interfaces and in turn avoid triggering firewall warnings on MacOS.

* fix Playbooks to use dynamic port

* TestMetrics: handle ipv4 localhost too

* TestMetrics: linting
2023-04-06 09:59:58 -03:00
Rohitesh Gupta
7325c38c39
Fixes MM-50733 (#22784) 2023-04-05 21:58:21 +02:00
Konstantinos Pittas
7029d88443
[MM-51034] Sanitize embedded posts transmitted over WS (#22424)
Co-authored-by: Mattermost Build <build@mattermost.com>
2023-04-05 21:43:22 +03:00
Nick Misasi
62e6f29638
Undo accidental merge (#22848) 2023-04-05 11:24:32 -04:00
Nick Misasi
6fce376e7b
[MM-51905] Fix: Successful trial request shows error modal (#22800)
* License public key to test env for mono-repo

* Fix error modal showing on a successful trial request
2023-04-05 10:53:07 -04:00
Jesse Hallam
28ad1c80cd
fix various copy/paste/typos (#22823) 2023-04-05 10:18:50 -03:00
Allan Guwatudde
ed36e8bd64
[MM-51236] - Add opt-in checkbox in self-hosted account creation page (#22709)
* [MM-51236] - Add opt-in checkbox in self-hosted account creation page

* add server impl

* fix lint and translations

* add tests

* improvents

* fix model

* fix mocks

* feedback impl

* update text color

* handle error

* fix tests
2023-04-04 13:57:32 +03:00
Saturnino Abril
8d301c0d64
fix: /test url and json (#22780) 2023-04-04 06:04:11 +08:00
Ben Cooke
af4c98cdf9
[MM-51724] (#22740)
* createUserAccessToken updates

* lint
2023-04-03 14:30:07 -04:00
Agniva De Sarker
dacac2e3ed
MM-51768: Scrub username/password from SQL datasource (#22731)
https://mattermost.atlassian.net/browse/MM-51768
```release-note
NONE
```
2023-04-03 23:41:51 +05:30
Kyriakos Z
4d2ed469bf
MM-49564: Drafts upsert in the Store vs App layer (#22530)
* MM-49564: Upsert in the Store vs App layer

Refactor drafts so that Upserting a draft would happen in the DB and not
in the app layer.

* Fixes mocks

* Fixes tests

* Fixes translations

* Fixes tests

* Update tests

* Fixes tests

* Addresses review comments

- renames Save => Upsert
- removes Sleep from tests

* Fixes flaky test

---------

Co-authored-by: Mattermost Build <build@mattermost.com>
2023-04-01 10:32:40 +03:00
Maria A Nunez
4a3c853636
Update Work Templates content and images (#22716)
* Enabled Work templates by default

* Remove board as product condition

* Removed playbook as a plugin condition

* Removed backend condition for playbook plugin/board product

* remove boards from templates

* Removed unnecessary translations after booards templates removal

* Removed template with no playbook or integration

* Updated entrypoint wording

* update texts

* update thumbnails

* update bigger pictures

* reorder i18n

* Copy updates. Add menu order

* Remove changed translations

* Updated casing for add menu

* Restored boards

* fix i18n

* Fix missing capital in text

* Added missing boards in template

* Updated feature release playbook image

* Updated channel preview for create a project

* Update title copy

* Updated create project thumbnail

* Generate updated work templates

* Updating snapshot

---------

Co-authored-by: Julien Tant <julien@craftyx.fr>
Co-authored-by: Julian Mondragon <bugshoo+github@gmail.com>
2023-03-31 16:12:56 -04:00
Doug Lauder
99467c6b68
MM-51792 Replace Boards feature flag with env var (#22739)
* remove Boards feature flag from server, makefile, and docker

* Update server/boards/server/boards_service_util.go

Co-authored-by: Miguel de la Cruz <miguel@mcrx.me>

---------

Co-authored-by: Miguel de la Cruz <miguel@mcrx.me>
2023-03-31 10:29:29 -04:00
Nick Misasi
957f999266
[MM-51233] Updates for Trial Requests (#22620)
* Add new trial form to enrich trial requests with more customer info

* Update snapshots

* One more addition

* Fixes from PR feedback

* Fix types, i18n, update e2e tests

* Fix linter

* Fix i18n?

* Fix blank translation

* update snapshot

* Update snapshot properly

* Remove inapplicable test

* Fix business email validation only happening once

* UX Feedback

* Fix linter

* Fix linter again, not working locally

* FIX LINTER

* Move isvalid check until after some fields are set

* Fix for overlapping modals

* Fix linter

* UX feedback

* UX Feedback

* Fix typo in error modal

* [MM-51551] Add new Trial Form to Playbooks trial requests (#22650)

* Playbooks start trial entrypoints opens new trial form modal

* Fix style

---------

Co-authored-by: Mattermost Build <build@mattermost.com>

* [MM-51347] Trial form error modal for embargoed and air gapped entities (#22656)

* Playbooks start trial entrypoints opens new trial form modal

* Add support for air gapped environments when making trial requests

* Add specific handling for embargoed entities

* undo some code

* Fix linter

* Fix types

* Fix style

* Updates because TE has to upgrade to E0 before it can activate a trial

---------

Co-authored-by: Mattermost Build <build@mattermost.com>

---------

Co-authored-by: Mattermost Build <build@mattermost.com>
2023-03-30 14:57:07 -04:00
Harshil Sharma
22b3d9e4cb
Fixed MM-51060 (#22532)
* Fixed MM-51060

* Minor improvements

* Breaking bigger loops

* CI

* Removed an unintended line change

---------

Co-authored-by: Mattermost Build <build@mattermost.com>
2023-03-30 07:38:53 +05:30
Doug Lauder
40da76ddc8
MM-51705 Fixes Shared Channels issue due to SELECT('*') (#22660)
* remove all select('*') from shared channels store

* remove left join when fetching user
2023-03-29 11:17:51 -04:00
Allan Guwatudde
c70d85c9bc
[MM-51330] - Sentry Crash: nil pointer dereference in getSelfHostedProducts (#22569)
* [MM-51330] - Sentry Crash: nil pointer dereference in getSelfHostedProducts

* feedback impl

* fix bool

* remove double check

* fix failing tests

---------

Co-authored-by: Mattermost Build <build@mattermost.com>
2023-03-29 18:11:45 +03:00
Harshil Sharma
5da458a16f
Allowed searcginbg users by substring in admin console (#22505) 2023-03-29 17:11:55 +05:30
Conor Macpherson
dd7e84aca2 Add missing checks for self hosted expansion config enabled. 2023-03-28 14:46:27 -04:00
Mattermost Build
30921f5e52
Merge branch 'master' into MM-50966-in-product-expansion-backend 2023-03-28 20:45:40 +03:00
Agniva De Sarker
2287dff298
MM-51700: Suppress websocket warnings with a threshold (#22637)
We log warnings whenever our websocket buffer sizes exceed
certain thresholds. The problem with that is, when this happens,
the logs are completely spammed with these lines
making it annoying for the customer.

To improve the situation, we use a timer that only gets reset
every minute.

https://mattermost.atlassian.net/browse/MM-51700

```release-note
NONE
```
2023-03-28 09:04:09 +05:30
Christopher Speller
ae6416e357
Remove configuration auto enable. (#22625)
* Remove configuration auto enable.

* i18n

* Fix diff tests.
2023-03-27 14:02:18 -07:00
Allan Guwatudde
0140e94d77
[MM-49751] - Turn off Inactive Server Email (#22648)
* [MM-49751] - Turn off Inactive Server Email

* remove unused var

---------

Co-authored-by: Mattermost Build <build@mattermost.com>
2023-03-27 22:38:19 +03:00
Conor Macpherson
1b9d97209d Merge branch 'master' of github.com:mattermost/mattermost-server into MM-50966-in-product-expansion-backend 2023-03-27 13:29:20 -04:00
Jesse Hallam
80c1431983
Revert testing workarounds (#22630)
* Revert "fix store issue take two"

This reverts commit 59f943c2c7.

* Revert "fix store override issue"

This reverts commit 29c346757a.

* Revert "Fix TestPushNotificationRace"

This reverts commit 6d62dddf86.

* Revert "fix default DSN for CI"

This reverts commit e0e69cdbb0.

* Revert "disable playbooks from more unit tests"

This reverts commit a1e97a9e96.

* Revert "disable playbooks for more tests"

This reverts commit 4d2dc74f05.

* Revert "disable playbooks for TestSAMLSettings"

This reverts commit 35c1a4312d.

* Revert "disable playbooks for more unit tests"

This reverts commit c049631a14.

* Revert "disable playbooks for mocked enterprise tests"

This reverts commit 829317fddb.

* Partially revert "disable playbooks for channel/apps mocked tests"

This reverts commit 52b4a0a6cf.

* Revert "fix TestUnitUpdateConfig"

This reverts commit 8f134f2a8a.

* Revert "add plugin mock to TestUnitUpdateConfig"

This reverts commit 3ec5419092.

* Revert "disable Boards for more test helpers"

This reverts commit 5d4d0d02d9.

* Revert "disable boards at correct place in test helpers"

This reverts commit 0c9e175f79.

* Partially revert "disable boards for slash cmd tests"

This reverts commit fad8d9de93.

* Revert "disable Boards for channels web tests"

This reverts commit 15540fdfc0.

* Revert "Adds a teardown function to playbook server tests to disable and reenable boards"

This reverts commit 9a46e3d0f4.

* Revert "Test disable boards through feature flag"

This reverts commit 787044add8.

* TestUnitUpdateConfig: restore callback check

* Revert "Revert "fix default DSN for CI""

This reverts commit 01b879d55a.
2023-03-27 13:19:29 -03:00
Nathaniel Allred
b7f2c00554
return 404 if the enterprise library error returned is 404 (#22628) 2023-03-27 08:21:29 -05:00
Allan Guwatudde
ee068726bc
[MM-51467] - NotifyAdmin job reports an error for unlicensed servers (#22568)
* [MM-51467] - Reduce frequency for notify install plugin job

* [MM-51467] - NotifyAdmin job reports an error for unlicensed servers

* .

* fix imports
2023-03-27 10:50:45 +03:00
Conor Macpherson
ff01fabc32 add mocks. 2023-03-24 16:30:26 -04:00
Conor Macpherson
9d8597b399 add self hostded expansion mm-server parts. 2023-03-24 15:11:17 -04:00
Agniva De Sarker
176a58617d
MM-51504: Control compliance export goroutine (#22604)
Spawn a goroutine from the server layer to have better
control for compliance tests.

https://mattermost.atlassian.net/browse/MM-51504

```release-note
NONE
```

Co-authored-by: Mattermost Build <build@mattermost.com>
2023-03-24 13:56:19 +05:30
byigorv
017c51c246
fix mem leak in hubConnectionIndex (#22560) 2023-03-24 11:22:37 +05:30
Agniva De Sarker
56b18ca7bf
MM-45956: Optimize FileInfo stats query (#22603)
* MM-45956: Optimize FileInfo stats query

We Denormalize Post.ChannelId on FileInfo.ChannelId

```release-note
The file info stats query is now optimized by denormalizing the channelID column into the table itself. This will speed up the query to get the file count for a channel on clicking the RHS.

Migration times:
On a MySQL 8.0.31 DB with
1405 rows in FileInfo and 11M posts, it took around 0.3s

On a Postgres 12.14 DB with
1731 rows in FileInfo and 11M posts, it took around 0.27s
```

https://mattermost.atlassian.net/browse/MM-45956
2023-03-23 22:14:04 +05:30
Agniva De Sarker
19c7c6fa7a
MM-51486: Implementing UTS 46 to check for preview blocklist (#22601)
There is a standard IDNA2008 which defines how unicode characters
in domain names can be compared using UTS (Unicode Technical Standard) 46.

We use that to convert any links in messages to ASCII and
then compare with the domain list in config.

https://mattermost.atlassian.net/browse/MM-51486

```release-note
NONE
```
2023-03-23 13:03:59 +05:30
Doug Lauder
c943ed6859
Mono repo -> Master (#22553)
Combines the following repositories into one:

https://github.com/mattermost/mattermost-server
https://github.com/mattermost/mattermost-webapp
https://github.com/mattermost/focalboard
https://github.com/mattermost/mattermost-plugin-playbooks
2023-03-22 17:22:27 -04:00