summaryrefslogtreecommitdiffstats
path: root/vendor/github.com/mattermost/platform/einterfaces/cluster.go
diff options
context:
space:
mode:
Diffstat (limited to 'vendor/github.com/mattermost/platform/einterfaces/cluster.go')
-rw-r--r--vendor/github.com/mattermost/platform/einterfaces/cluster.go23
1 files changed, 8 insertions, 15 deletions
diff --git a/vendor/github.com/mattermost/platform/einterfaces/cluster.go b/vendor/github.com/mattermost/platform/einterfaces/cluster.go
index b7ba5514..096a775f 100644
--- a/vendor/github.com/mattermost/platform/einterfaces/cluster.go
+++ b/vendor/github.com/mattermost/platform/einterfaces/cluster.go
@@ -1,4 +1,4 @@
-// Copyright (c) 2015 Mattermost, Inc. All Rights Reserved.
+// Copyright (c) 2015-present Mattermost, Inc. All Rights Reserved.
// See License.txt for license information.
package einterfaces
@@ -7,26 +7,19 @@ import (
"github.com/mattermost/platform/model"
)
+type ClusterMessageHandler func(msg *model.ClusterMessage)
+
type ClusterInterface interface {
StartInterNodeCommunication()
StopInterNodeCommunication()
+ RegisterClusterMessageHandler(event string, crm ClusterMessageHandler)
+ GetClusterId() string
GetClusterInfos() []*model.ClusterInfo
+ SendClusterMessage(cluster *model.ClusterMessage)
+ NotifyMsg(buf []byte)
GetClusterStats() ([]*model.ClusterStats, *model.AppError)
- ClearSessionCacheForUser(userId string)
- InvalidateCacheForUser(userId string)
- InvalidateCacheForChannel(channelId string)
- InvalidateCacheForChannelByName(teamId, name string)
- InvalidateCacheForChannelMembers(channelId string)
- InvalidateCacheForChannelMembersNotifyProps(channelId string)
- InvalidateCacheForChannelPosts(channelId string)
- InvalidateCacheForWebhook(webhookId string)
- InvalidateCacheForReactions(postId string)
- Publish(event *model.WebSocketEvent)
- UpdateStatus(status *model.Status)
- GetLogs() ([]string, *model.AppError)
- GetClusterId() string
+ GetLogs(page, perPage int) ([]string, *model.AppError)
ConfigChanged(previousConfig *model.Config, newConfig *model.Config, sendToOtherServer bool) *model.AppError
- InvalidateAllCaches() *model.AppError
}
var theClusterInterface ClusterInterface