Граф коммитов

14173 Коммитов

Автор SHA1 Сообщение Дата
MArtin Johnson
af36c02e21 Translated using Weblate (Swedish)
Currently translated at 100.0% (2318 of 2318 strings)

Translation: mattermost-languages-shipped/mattermost-server
Translate-URL: https://translate.mattermost.com/projects/mattermost/mattermost-server_master/sv/
2021-11-22 12:34:20 -05:00
jprusch
9e3dbe910f Translated using Weblate (German)
Currently translated at 100.0% (2322 of 2322 strings)

Translation: mattermost-languages-shipped/mattermost-server
Translate-URL: https://translate.mattermost.com/projects/mattermost/mattermost-server_master/de/

Translated using Weblate (German)

Currently translated at 100.0% (2318 of 2318 strings)

Translation: mattermost-languages-shipped/mattermost-server
Translate-URL: https://translate.mattermost.com/projects/mattermost/mattermost-server_master/de/
2021-11-22 12:34:20 -05:00
Kaya Zeren
a5d3a3eaf1 Translated using Weblate (Turkish)
Currently translated at 100.0% (2318 of 2318 strings)

Translation: mattermost-languages-shipped/mattermost-server
Translate-URL: https://translate.mattermost.com/projects/mattermost/mattermost-server_master/tr/

Translated using Weblate (Turkish)

Currently translated at 100.0% (2317 of 2317 strings)

Translation: mattermost-languages-shipped/mattermost-server
Translate-URL: https://translate.mattermost.com/projects/mattermost/mattermost-server_master/tr/
2021-11-22 12:34:20 -05:00
master7
4b6b8a80f7 Translated using Weblate (Polish)
Currently translated at 100.0% (2322 of 2322 strings)

Translation: mattermost-languages-shipped/mattermost-server
Translate-URL: https://translate.mattermost.com/projects/mattermost/mattermost-server_master/pl/

Translated using Weblate (Polish)

Currently translated at 100.0% (2318 of 2318 strings)

Translation: mattermost-languages-shipped/mattermost-server
Translate-URL: https://translate.mattermost.com/projects/mattermost/mattermost-server_master/pl/

Translated using Weblate (Polish)

Currently translated at 100.0% (2317 of 2317 strings)

Translation: mattermost-languages-shipped/mattermost-server
Translate-URL: https://translate.mattermost.com/projects/mattermost/mattermost-server_master/pl/
2021-11-22 12:34:20 -05:00
Matthew Williams
45a5a28fbb Translated using Weblate (English (Australia))
Currently translated at 100.0% (2322 of 2322 strings)

Translation: mattermost-languages-shipped/mattermost-server
Translate-URL: https://translate.mattermost.com/projects/mattermost/mattermost-server_master/en_AU/

Translated using Weblate (English (Australia))

Currently translated at 100.0% (2318 of 2318 strings)

Translation: mattermost-languages-shipped/mattermost-server
Translate-URL: https://translate.mattermost.com/projects/mattermost/mattermost-server_master/en_AU/

Translated using Weblate (English (Australia))

Currently translated at 100.0% (2317 of 2317 strings)

Translation: mattermost-languages-shipped/mattermost-server
Translate-URL: https://translate.mattermost.com/projects/mattermost/mattermost-server_master/en_AU/
2021-11-22 12:34:20 -05:00
Ernest Nguyen
47de1f37e6 MM-39632: Migrate from using gorp to sqlx (#18949)
Automatic Merge
2021-11-22 17:05:13 +01:00
Alex Boutin
478b3f7108 MM-39634: Migrated gorp to sqlx (#18951)
* MM-39634: Migrated gorp to sqlx

* MM-39634: Removed redundant limit on get since only one value is returned

* MM-39485: Fixed returned errors + goimports

Co-authored-by: Alex <alex@rumandcode.io>
Co-authored-by: Mattermod <mattermod@users.noreply.github.com>
2021-11-22 20:58:50 +05:30
Claudio Costa
3dea98ea4b Implement deep copy method for model.WebSocketEvent (#18977) 2021-11-22 09:54:19 +01:00
Ashish Bhate
0da249c651 [MM-37013] Async job to fix CRT channel unreads (#18340)
Summary
The addition of the TotalMsgCountRoot and MsgCountRoot columns to support CRT caused several issues with previously read threads and channels being marked as unread. Previously we attempted to fix this purely in a SQL migration [MM-35345][MM-35494] fixes for incorrect mentions and unreads for threads and channels #17803 but that turned out to be too heavy and it was decided to break up some of the fixes into async jobs.
This PR implements an async job to mark channels as read if there are no user posts since the last time the user viewed the channel. 

Ticket Link
https://mattermost.atlassian.net/browse/MM-37013
2021-11-18 15:31:18 +05:30
Agniva De Sarker
12dc171a60 MM-39341: Sentry crash: nil dereference in *User.ClearNonProfileFields (#18966)
In some cases, an invalid participant id like an empty string
might creep into the database. It's not exactly clear
how can this happen, but if it does, then it breaks the logic
of assuming that the users slice will contain all users
in the participants slice.

To prevent this, we check if a match was found before
adding it in the slice.

https://community-daily.mattermost.com/boards/workspace/zyoahc9uapdn3xdptac6jb69ic/285b80a3-257d-41f6-8cf4-ed80ca9d92e5/495cdb4d-c13a-4992-8eb9-80cfee2819a4/7sixm4t7c6rsr3d8ydxbtfgy9gr

```release-note
NONE
```
2021-11-17 20:49:40 +05:30
Agniva De Sarker
b7a7d8e7b6 MM-39612: Make acquiring and removing connections atomic (#18982)
* MM-39612: Make acquiring and removing connections atomic

The reconnect phase of a websocket was split into two parts:
one where we check if a connection with a given connectionID
exists or not. And second, where we remove that connection
and insert the new connection again in the index.

This would lead to a race where it would be possible
for 2 concurrent requests for the same connectionID to go through
which would lead to separate goroutines working on the same dead queue.

We simplify this by removing the connection from the index
in the check connection stage itself. And then just add that
during register phase.

And to distinguish between a fresh and an old connection, we add
a new field called reuseCount.

While here, we also cleanup some old comments and add more
in some places.

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

```release-note
NONE
```

* remove unused method

```release-note
NONE
```

* race test

```release-note
NONE
```
2021-11-16 19:43:43 +05:30
Ben Schumacher
e8591537e0 [MM-39851] Add CRUD methods for user sessions to plugin API (#18958) 2021-11-16 15:08:20 +01:00
Penthaa Patel
397edef1d8 [MM-39637] - Migrate from gorp to sqlx in store/sqlstore/shared_channel_store.go (#18898)
Automatic Merge
2021-11-16 05:40:13 +01:00
Kaya Zeren
c3ed4e11ab Translated using Weblate (Turkish)
Currently translated at 100.0% (2316 of 2316 strings)

Translation: mattermost-languages-shipped/mattermost-server
Translate-URL: https://translate.mattermost.com/projects/mattermost/mattermost-server_master/tr/
2021-11-15 17:29:07 -05:00
kaakaa
8a176846e8 Translated using Weblate (Japanese)
Currently translated at 99.9% (2315 of 2316 strings)

Translation: mattermost-languages-shipped/mattermost-server
Translate-URL: https://translate.mattermost.com/projects/mattermost/mattermost-server_master/ja/
2021-11-15 17:29:07 -05:00
maruTA-bis5
fa462d7891 Translated using Weblate (Japanese)
Currently translated at 99.9% (2314 of 2315 strings)

Translation: mattermost-languages-shipped/mattermost-server
Translate-URL: https://translate.mattermost.com/projects/mattermost/mattermost-server_master/ja/
2021-11-15 17:29:07 -05:00
MArtin Johnson
bc7f1882ce Translated using Weblate (Swedish)
Currently translated at 100.0% (2315 of 2315 strings)

Translation: mattermost-languages-shipped/mattermost-server
Translate-URL: https://translate.mattermost.com/projects/mattermost/mattermost-server_master/sv/

Translated using Weblate (Swedish)

Currently translated at 99.9% (2314 of 2315 strings)

Translation: mattermost-languages-shipped/mattermost-server
Translate-URL: https://translate.mattermost.com/projects/mattermost/mattermost-server_master/sv/
2021-11-15 17:29:07 -05:00
jprusch
b48e695ec4 Translated using Weblate (German)
Currently translated at 100.0% (2317 of 2317 strings)

Translation: mattermost-languages-shipped/mattermost-server
Translate-URL: https://translate.mattermost.com/projects/mattermost/mattermost-server_master/de/

Translated using Weblate (German)

Currently translated at 100.0% (2315 of 2315 strings)

Translation: mattermost-languages-shipped/mattermost-server
Translate-URL: https://translate.mattermost.com/projects/mattermost/mattermost-server_master/de/
2021-11-15 17:29:07 -05:00
SerHack
846a08041a Translated using Weblate (Italian)
Currently translated at 75.6% (1751 of 2314 strings)

Translation: mattermost-languages-shipped/mattermost-server
Translate-URL: https://translate.mattermost.com/projects/mattermost/mattermost-server_master/it/
2021-11-15 17:29:07 -05:00
Matthew Williams
580c439bff Translated using Weblate (English (Australia))
Currently translated at 100.0% (2315 of 2315 strings)

Translation: mattermost-languages-shipped/mattermost-server
Translate-URL: https://translate.mattermost.com/projects/mattermost/mattermost-server_master/en_AU/

Translated using Weblate (English (Australia))

Currently translated at 100.0% (2314 of 2314 strings)

Translation: mattermost-languages-shipped/mattermost-server
Translate-URL: https://translate.mattermost.com/projects/mattermost/mattermost-server_master/en_AU/
2021-11-15 17:29:07 -05:00
Tóth Csaba // Online ERP Hungary Kft
c426f5407d Translated using Weblate (Hungarian)
Currently translated at 100.0% (2317 of 2317 strings)

Translation: mattermost-languages-shipped/mattermost-server
Translate-URL: https://translate.mattermost.com/projects/mattermost/mattermost-server_master/hu/

Translated using Weblate (Hungarian)

Currently translated at 100.0% (2316 of 2316 strings)

Translation: mattermost-languages-shipped/mattermost-server
Translate-URL: https://translate.mattermost.com/projects/mattermost/mattermost-server_master/hu/

Translated using Weblate (Hungarian)

Currently translated at 100.0% (2315 of 2315 strings)

Translation: mattermost-languages-shipped/mattermost-server
Translate-URL: https://translate.mattermost.com/projects/mattermost/mattermost-server_master/hu/

Translated using Weblate (Hungarian)

Currently translated at 100.0% (2314 of 2314 strings)

Translation: mattermost-languages-shipped/mattermost-server
Translate-URL: https://translate.mattermost.com/projects/mattermost/mattermost-server_master/hu/
2021-11-15 17:29:07 -05:00
Ujjwal Sharma
627d2b9d6c [MM-39628] Migrate from gorp to sqlx in store/sqlstore/scheme_store.go (#18895)
Automatic Merge
2021-11-15 17:40:13 +01:00
Cesar Bretana
2153dc4d6d [MM-39641] Migrate Webhook store to sqlx (#18896)
* Migrated to sqlx INSERT + UPDATE incoming_webhooks

* Finish migrating IncomingWebhook to sqlx

* wip: outgoing webhooks

* Fix sql syntax error for incoming webhooks

* Add missing fields to insert incoming webhooks query

* Migrate outgoing_webhooks store to sqlx

* Migrate incoming_webhooks analytics count to sqlx

* Migrate outgoing_webhooks analytics count to sqlx

* Fix lint goimports alert

* Migrate unmigrated gorp methods

* Add missing fields to update incoming webhooks sql + remove unnecessary guards

* Address comments from review
2021-11-15 21:13:14 +05:30
Penthaa Patel
25b727d197 [MM-39638] - Migrate from gorp to sqlx in store/sqlstore/status_store.go (#18897)
* migrate from gorp to sqlx

Signed-off-by: Penthaa Patel <penthaapatel@gmail.com>

* fixes

Signed-off-by: Penthaa Patel <penthaapatel@gmail.com>

Co-authored-by: Mattermod <mattermod@users.noreply.github.com>
2021-11-15 21:12:30 +05:30
Allan Guwatudde
0ee2a3ca35 [MM-39060] - A/B Test: Reminder to Join Workspace email (#18894)
* [MM-39060] - A/B Test: Reminder to Join Workspace email

* Fix error and add error handling

* feedback impl

* run make i18n-extract

* improvements

* make i18n-extract

* setup ability to do telemetry on reminder invite emails

* improvement

* add telemetry

Co-authored-by: Mattermod <mattermod@users.noreply.github.com>
2021-11-15 18:42:15 +03:00
Yair Facio
e1eb0a0cf3 [MM-39643] Migrate from gorp to sqlx in store/sqlstore/system_store.go (#18893)
* Migrate from gorp to sqlx in SystemStore

* Add BeginXWithIsolation method to *sqlxDBWrapper

* Address PR comments
2021-11-15 21:03:55 +05:30
Penthaa Patel
bde2b540d6 [MM-39644] - Migrate from gorp to sqlx in store/sqlstore/upload_session_store.go (#18892)
* migrate from gorp to sqlx

Signed-off-by: Penthaa Patel <penthaapatel@gmail.com>

* fix insert query

Signed-off-by: Penthaa Patel <penthaapatel@gmail.com>

* replace NamedExec() with Exec()

Signed-off-by: Penthaa Patel <penthaapatel@gmail.com>

* fix typo

Signed-off-by: Penthaa Patel <penthaapatel@gmail.com>

* remove string()

Signed-off-by: Penthaa Patel <penthaapatel@gmail.com>
2021-11-15 19:40:54 +05:30
Penthaa Patel
ae897bc59a [MM-39642] - Migrate from gorp to sqlx in store/sqlstore/session_store.go (#18891)
* migrate from gorp to sqlx

Signed-off-by: Penthaa Patel <penthaapatel@gmail.com>

* fix Save function

Signed-off-by: Penthaa Patel <penthaapatel@gmail.com>

* fix Get function

Signed-off-by: Penthaa Patel <penthaapatel@gmail.com>

* use json.Marshal() for session.Props

Signed-off-by: Penthaa Patel <penthaapatel@gmail.com>
2021-11-15 19:40:37 +05:30
Allan Guwatudde
21a61813e8 [MM-39504] - Remove Prewritten Messages Feature Flag (#18968) 2021-11-15 09:35:10 +03:00
Anurag Shivarathri
c603b1b989 fix (#18793) 2021-11-15 10:43:07 +05:30
Anurag Shivarathri
65c670a4c9 MM-36687 CRT push notifications (#18347)
* CRT changes

* Lint fix

* Moved postId check

* Moved postId check

* Lint fix

* Misc

* Added test case for badge count while clearing notifications

* Fixed count when CRT is on and added isCRTEnabled, teamId to isIdLoaded notifications

* test fix

* isCRTEnabledForUser capitalised

Co-authored-by: Mattermod <mattermod@users.noreply.github.com>
2021-11-15 10:41:47 +05:30
Devin Binnie
929caaff3d [MM-39374] Remove DesktopLatestVersion and DesktopMinVersion (#18979) 2021-11-12 10:37:43 -05:00
Nathaniel Allred
a7d9b83968 Mm 38799 invite to team (#18987)
* Add in-screen invitation modal invite to team feature flag
2021-11-12 09:20:15 -06:00
Allan Guwatudde
e3240a2ddd [MM-40022] - Expose telemetry service in the server (#18976)
* [MM-40022] - Expose telemetry service in the server

* make app-layers

* feedback impl
2021-11-12 10:16:19 +03:00
Agniva De Sarker
a850704afe Move pluginCommands into Channels (#18974)
* Move pluginCommands into Channels

We move pluginCommands, pluginCommandsLock
into Channels.

We also move the plugin related route handlers
under Channels and move the init code under
NewChannels. To achieve this, the router initialization
is bumped up.

Along with it, we clean up some App methods
which were just wrappers over Channel methods.
Instead, we call the Channel method directly
to make things more readable and easy to understand.

```release-note
NONE
```

* fix tests

```release-note
NONE
```
2021-11-12 10:35:14 +05:30
Sharath Huddar
27559c1c7b GH-18288: Allow configuring unsafe-eval and unsafe-inline (#18801)
* GH-18288: Allow configuring unsafe-eval and unsafe-inline

* Add developer flags to telemetry

* wip

* wip

* Refactor based on review

* Refactor based on review

* fix expected vs. actual in assert.Equal

* Add unit tests, rework to check only supported flags.

* Update model/config.go

Co-authored-by: Jesse Hallam <jesse@thehallams.ca>

* Fix failing tests

* Refactor based on review

* Refactor based on review

* Refactor based on review

Co-authored-by: Jesse Hallam <jesse.hallam@gmail.com>
Co-authored-by: Jesse Hallam <jesse@thehallams.ca>
2021-11-12 05:41:11 +08:00
Penthaa Patel
df3ed307df [MM-39639] - Migrate from gorp to sqlx in store/sqlstore/user_access_token_store.go (#18888)
Automatic Merge
2021-11-11 05:40:13 +01:00
Scott Bishel
e3051b0df8 prepackage boards to 0.10.0 (#18973)
Co-authored-by: Mattermod <mattermod@users.noreply.github.com>
2021-11-10 15:58:36 -07:00
Harrison Healey
7677a93494 MM-40003 Fix patch route for Town Square (#18971)
Automatic Merge
2021-11-10 23:10:13 +01:00
Michael Kochell
ba1b279c5f [MM-39820] Add AppBarEnabled feature flag (#18967)
Automatic Merge
2021-11-10 19:10:14 +01:00
Carlos Tadeu Panato Junior
19de373498 update client function to match the new format and fix bad merge (#18978) 2021-11-10 12:38:02 -05:00
Carlos Tadeu Panato Junior
bb5a74a42b [MM-34076] Add Plugin API User custom status (#17435)
* add missing client for custom user status

* add custom user status plugin api

* update based on feedback review

* add GetCustomStatus

* update interfaces
2021-11-10 11:11:20 -05:00
Agniva De Sarker
0a3e7f4d55 Ordering clarifications (#18964)
Automatic Merge
2021-11-09 10:15:15 +01:00
jprusch
ba5f1f3f5c Translated using Weblate (German)
Currently translated at 100.0% (2314 of 2314 strings)

Translation: mattermost-languages-shipped/mattermost-server
Translate-URL: https://translate.mattermost.com/projects/mattermost/mattermost-server_master/de/
2021-11-08 11:39:45 -06:00
kaakaa
4be195327c Translated using Weblate (Japanese)
Currently translated at 100.0% (2313 of 2313 strings)

Translation: mattermost-languages-shipped/mattermost-server
Translate-URL: https://translate.mattermost.com/projects/mattermost/mattermost-server_master/ja/
2021-11-08 11:39:45 -06:00
Tóth Csaba // Online ERP Hungary Kft
3a168226b4 Translated using Weblate (Hungarian)
Currently translated at 100.0% (2313 of 2313 strings)

Translation: mattermost-languages-shipped/mattermost-server
Translate-URL: https://translate.mattermost.com/projects/mattermost/mattermost-server_master/hu/
2021-11-08 11:39:45 -06:00
Berke Kalkan
e70c5a605a MM-32396 Create endpoint for listing all the roles (#16988)
* Create an endpoint for listing roles

* Add function to client model

* Create tests for listing roles endpoint

* Apply code review suggestions

* Restore GetAllRoles app method

* Use AppContext instead of App

* Minor fix

* Refactor according to new changes

Co-authored-by: Mattermod <mattermod@users.noreply.github.com>
2021-11-08 16:38:41 +03:00
Agniva De Sarker
25257d6ef6 Move plugins under Channels (#18938)
* Move plugins under Channels

We move all plugin related fields under *Channels.
This essentially migrates several methods from being under
*Server to under *Channels.

We also move the plugin startup and shutdown code
to be under Channels.Start and Channels.Shutdown.

While here, we remove the getPluginPublicKeyFiles
method which was a one-line method which uselessly
returned an error.

Lastly, we fix the product initialization order which
was incorrect previously. Products are dependent on
the main server.

So startup should be products -> server.
And shutdown should be server -> products.

```release-note
NONE
```

* Added app layer

```release-note
NONE
```

* Incorporate suggestions

```release-note
NONE
```
2021-11-08 11:57:22 +05:30
Agniva De Sarker
24248dc764 Add JobSettings.CleanupJobsThresholdDays to telemetry (#18936)
* Add JobSettings.CleanupJobsThresholdDays to telemetry

```release-note
NONE
```

* Moved telemetry to more specific fields

```release-note
NONE
```

* Add missing space

```release-note
NONE
```
2021-11-08 11:45:59 +05:30
Penthaa Patel
c88c9b6625 [MM-39630] - Migrate from gorp to sqlx in store/sqlstore/tokens_store.go (#18887)
* migrate from gorp to sqlx

Signed-off-by: Penthaa Patel <penthaapatel@gmail.com>

* fixes

Signed-off-by: Penthaa Patel <penthaapatel@gmail.com>
2021-11-05 10:00:03 +05:30