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

9866 Коммитов

Автор SHA1 Сообщение Дата
Derrick Anderson
c1853c7f40 prep code for 5.0 (#8743) 2018-05-08 09:27:37 -04:00
Jonathan Villemaire-Krajden
6c3d1fc1f8 Fix empty GOPATH behaviour in Makefile (#8724) 2018-05-07 07:04:09 -07:00
Joram Wilander
09c6770885 Add IncrementClusterEventType function to metrics interface (#8728) 2018-05-04 14:59:28 -07:00
Derrick Anderson
e555b7454d Uncomment upgrade for 4.10 (#8727)
* uncomment upgrade code

* ping jenkins

* add 4.10.0 to version.go
2018-05-04 17:01:14 -04:00
Harrison Healey
fc513a9e61 Added missing i18n strings for files and email batching (#8700)
* Added missing i18n strings for files and email batching

* Added more fields to log messages
2018-05-04 16:11:15 -04:00
Jesús Espino
7c680cacab MM-10319: Use normalized email for Saml (migration) (#8711) 2018-05-04 16:10:43 -04:00
Saturnino Abril
30fd4a2951 update permission of converting a channel from public to private to allow team admin (#8723) 2018-05-05 02:16:00 +08:00
Martin Kraft
37b3805ca6 Removes .vscode dir. (#8721) 2018-05-04 08:44:48 -07:00
Saturnino Abril
5000eac24f respect image orientation before saving height and width of FileInfo (#8710) 2018-05-04 01:02:22 +08:00
Martin Kraft
14b65b990c MM-10393: Fix for tracking active vs inactive users. (#8706) 2018-05-03 16:00:33 +02:00
Harrison Healey
3b138c8b16 MM-10189 Fixed inconsistency when using environment variables for MessageExportSettings (#8705) 2018-05-03 09:55:03 -04:00
Jesús Espino
ffb834ec3c Fix TestSendNotifications test (#8712) 2018-05-03 09:40:54 -04:00
George Goldberg
62898f4892 MM-10424: Migrate PostEditTimeLimit config setting. (#8702) 2018-05-02 14:09:11 -04:00
Joram Wilander
d6537deb3d Add inactive user count to analytics and fix client analytics function (#8695) 2018-05-02 07:50:56 -07:00
Carlos Tadeu Panato Junior
1647614fc9 [MM-10415] Reorder checks for command invite (#8701) 2018-05-02 22:07:26 +08:00
Joram Wilander
529807c1ba Update zoom plugin to 0.1.6 (#8698) 2018-05-01 07:35:27 -07:00
Jesse Hallam
1e6553704d MM-8622: improved plugin error handling (#8692)
* don't report an error on plugin activation if already active

* improved plugin logging events

Log an error when a plugin's ServeHTTP fails, or when it unexpectedly
terminates.

Restart a plugin at most three times, allowing its failure to later
bubble up under the "failed to stay running" status.

* clarified plugin activation/deactivation

Avoid repeatedly activating when any configuration bit changes. Improved
logging.

* constrain plugin ids to ^[a-zA-Z0-9-_\.]+$ and enforce minimum length

Previously, the plugin id was used unsanitized to relocate the plugin
bundle, which allowed writing outside the `plugins/` directory by using
an `id` containing `../`.

Similarly, an empty string was accepted as an id and led to unexpected
error messages.

* remove plugins by manifest path, not id

If the id within the manifest ever diverges from the actual plugin
location, it becomes impossible to remove via the API. Instead, if the
plugin is found by id, remove the path containing the manifest.

* ignore plugins with nil manifests

If a plugin was detected, but had a manifest that couldn't be parsed, it
will be left nil but still be listed among the packages. Skip over these
in most cases to avoid segfaults.

* leverage mlog more effectively for plugins

* build issues
2018-05-01 07:34:12 -07:00
Elias Nahum
3b57422c5f translations PR 20180430 (#8696) 2018-05-01 11:07:56 -03:00
Jesús Espino
baba8fa92f Upgrading minio-go library to 6.0.0 (#8651)
* Upgrading minio-go library to 6.0.0

* Removing unnecesary Gopkg constraint
2018-04-30 14:35:10 -07:00
Derrick Anderson
a5f006b8a9 Revert "MM-9770: rewrite getParentsPosts to improve performance (#8467)" (#8659) (#8694)
This reverts commit 4b675b347b.
2018-04-30 16:06:06 -04:00
Hyeseong Kim
e73f1d7314 MM-9072/MM-10185 Force-convert the encoding of OpenGraph metadata to UTF-8 (#8631)
* Force-convert non-UTF8 HTML to UTF8 before opengraph processing

* Split the force-encoding function

* Add benchmark Test for the forceHTMLEncodingToUTF8()

```
Running tool: /home/comet/go-v1.9.2/bin/go test -benchmem -run=^$ github.com/mattermost/mattermost-server/app -bench ^BenchmarkForceHTMLEncodingToUTF8$

[03:32:58 KST 2018/04/21] [INFO] (github.com/mattermost/mattermost-server/app.TestMain:28) -test.run used, not creating temporary containers
goos: linux
goarch: amd64
pkg: github.com/mattermost/mattermost-server/app
BenchmarkForceHTMLEncodingToUTF8/with_converting-4         	  100000	     11201 ns/op	   18704 B/op	      32 allocs/op
BenchmarkForceHTMLEncodingToUTF8/without_converting-4      	  300000	      3931 ns/op	    4632 B/op	      13 allocs/op
PASS
ok  	github.com/mattermost/mattermost-server/app	2.703s
Success: Benchmarks passed.
```

* Remove an unnecessary constraint

* Add pre-check if content-type header is already utf-8

* Move the checking for utf-8 into forceHTMLEncodingToUTF8() for testing

* Revert df3f347213faa0d023c26d201fa6531f46391086..HEAD, without Gopkg.lock
2018-04-30 09:54:11 -07:00
Christopher Speller
9c5815ee41 Add stdlog interpreter. (#8691) 2018-04-30 08:18:04 -07:00
Jason Blais
2f175001b4 Add missing diagnostics for 4.10 (#8675)
* Add missing diagnostics for 4.10

* Add missing ":"
2018-04-30 10:37:15 -04:00
Elias Nahum
37d89d3955 translations PR 20180424 (#8662) 2018-04-30 08:33:44 -03:00
Saturnino Abril
30011f67e8 [MM-10354] Add feature to remove team icon (#8684)
* set team.LastTeamIconUpdate to 0 when removing team icon

* add APIv4 for removing team icon

* removed comment and updated typo on AppError
2018-04-30 17:57:57 +08:00
Christopher Speller
2e6b3da1d3 Fixing some merge conflicts with structured logging. (#8685) 2018-04-27 13:31:50 -07:00
Christopher Speller
686c2fbab7 Structured logging (#8673)
* Implementing structured logging

* Changes to en.json to allow refactor to run.

* Fixing global logger

* Structured logger initalization.

* Add caller.

* Do some log redirection.

* Auto refactor

* Cleaning up l4g reference and removing dependancy.

* Removing junk.

* Copyright headers.

* Fixing tests

* Revert "Changes to en.json to allow refactor to run."

This reverts commit fd8249e99bcad0231e6ea65cd77c32aae9a54026.

* Fixing some auto refactor strangeness and typo.

* Making keys more human readable.
2018-04-27 12:49:45 -07:00
Corey Hulen
2acbc77d78 MM-10375 Fixing connected socket count (#8682)
* Fixing connected socket count

* Adding unit test
2018-04-27 10:38:40 -07:00
Jesse Hallam
7abd6176e9 modestly extend SQLite support (#8677)
This is primarily to unblock the advanced permissions merge. There's
still more work to do if we wanted this to be mainstream, but as it's
mainly for unit tests, I'm just focussing on the minimum.
2018-04-27 10:07:36 +01:00
Jesse Hallam
6d50d836f5 MM-10232, MM-10259: Improve error handling from invalid json (#8668)
* MM-10232: improve error handling from malformed slash command responses

Switch to json.Unmarshal, which doesn't obscure JSON parse failures like
json.Decode. The latter is primarily designed for streams of JSON, not
necessarily unmarshalling just a single object.

* rework HumanizedJsonError to expose Line and Character discretely

* MM-10259: pinpoint line and character where json config error occurs

* tweak HumanizeJsonError to accept err first
2018-04-26 11:19:25 -04:00
james-mm
d3f09b54e2 Update ISSUE_TEMPLATE.md (#8292)
* Update ISSUE_TEMPLATE.md

Customer wanted us to be more explicit on this page about searching for existing tickets in JIRA vs Github before proceeding to submit a new ticket.

* Update ISSUE_TEMPLATE.md

* Shorten proposed text
2018-04-25 15:39:58 -04:00
Saturnino Abril
3224d2f6a3 add api to convert a channel from public to private and restrict that to system_admin (#8655) 2018-04-23 08:18:58 -04:00
Joram Wilander
853445dc2e Properly implement session deep copy (#8602) 2018-04-20 12:25:14 -04:00
Joram Wilander
283f34b9c6 MM-10007 Send an admin and regular WS events when a user is updated (#8588)
* Add user.DeepCopy() function

* Add omit admins/non-admins to WS broadcast and use for updating users

* Updates per feedback and adding unit test for ShouldSendEvent
2018-04-20 08:44:18 -04:00
Joram Wilander
7987c95fcd MM-10133 Suppress confusing personal access token message in invalid session error (#8645)
* Suppress confusing personal access token message in invalid session error

* Updates per feedback
2018-04-20 08:44:01 -04:00
Joram Wilander
514033f14c Fix panics caused by race in notification code (#8652) 2018-04-19 11:21:33 -03:00
Martin Kraft
4921fda79f MM-10122: Adds a mention for added-to-channel messages even when 'username mentions' are disabled. (#8648) 2018-04-19 11:28:04 +01:00
Christopher Speller
2b83f8c48f Removing user cache clear from SessionHasPermissionsTo (#8624) 2018-04-18 19:41:15 -07:00
Jesús Espino
0910eae31d MM-9779: Incorporate a Token into the invitations system (#8604)
* Incorporate a Token into the invitations system

* Adding unit tests

* Fixing some api4 client tests

* Removing unnecesary hash validation

* Change the Hash concept on invitations with tokenId

* Not send invitation if it wasn't able to create the Token

* Fixing some naming problems

* Changing the hash query params received from the client side

* Removed unneded data param in the token usage
2018-04-18 13:46:10 -07:00
George Goldberg
b13a228b04 MM-10121: CLI command to reset permissions system to default state. (#8637)
* MM-10121: CLI command to reset permissions system to default state.

* Review comment.
2018-04-18 10:18:07 +01:00
Joram Wilander
a1882d4004 Ignore rolled log files (#8644) 2018-04-18 08:43:55 +01:00
Joram Wilander
b15f69ea30 Handle app errors in user autocomplete endpoint (#8643) 2018-04-17 15:39:08 -07:00
Carlos Tadeu Panato Junior
51a6e95f58 add app shutdown to make sure the goroutines finish and all process are closed (#8629)
* run the send email verification as goroutine as well

* add app shutdown to make sure all go routines finish
2018-04-17 11:06:55 -04:00
George Goldberg
5511106d93 MM-9918: Trim trailing / from push proxy URL. (#8635) 2018-04-17 07:13:16 -07:00
Derrick Anderson
af98bf1d49 Merge branch 'merge49final' 2018-04-17 09:49:02 -04:00
Derrick Anderson
58e559da39 Add MM9720 changes back in for master merge 2018-04-17 09:37:20 -04:00
Derrick Anderson
885b8e51f3 Merge remote-tracking branch 'origin/release-4.9' into merge49final 2018-04-17 09:21:33 -04:00
Daniel Schalla
997df03ac1 Initial Commit of Ephemeral Message Support for System Admins (#8611)
Fixed Permission Test

Fixed and extended ephemeral message tests; Removed Online/Activity Updates

Set Create Time to current time

gofmt
2018-04-17 08:20:47 -04:00
Jesse Hallam
3a4c7603b3 MM-10020: avoid duplicating unique indexes (#8587)
* unit test TestGet(Search)Replica

This adds partial, testing-focused support for SQLite, as well as removing
some translated log messages that required initializing i18n just for
testing.

* avoid returning master twice when no replicas are configured

* remove duplicate indexes

* unit test GetAllConns
2018-04-16 18:23:20 -07:00
Christopher Speller
ba6f9075c1 Fix opengraph images not going through the image proxy. (#8627) 2018-04-16 09:00:59 -04:00