Fixing leader election (#7267)
Этот коммит содержится в:
@@ -28,7 +28,7 @@ func GetLogs(page, perPage int) ([]string, *model.AppError) {
|
||||
if einterfaces.GetClusterInterface() != nil && *utils.Cfg.ClusterSettings.Enable {
|
||||
lines = append(lines, "-----------------------------------------------------------------------------------------------------------")
|
||||
lines = append(lines, "-----------------------------------------------------------------------------------------------------------")
|
||||
lines = append(lines, einterfaces.GetClusterInterface().GetClusterId())
|
||||
lines = append(lines, einterfaces.GetClusterInterface().GetMyClusterInfo().Hostname)
|
||||
lines = append(lines, "-----------------------------------------------------------------------------------------------------------")
|
||||
lines = append(lines, "-----------------------------------------------------------------------------------------------------------")
|
||||
}
|
||||
|
||||
@@ -15,6 +15,7 @@ type ClusterInterface interface {
|
||||
RegisterClusterMessageHandler(event string, crm ClusterMessageHandler)
|
||||
GetClusterId() string
|
||||
IsLeader() bool
|
||||
GetMyClusterInfo() *model.ClusterInfo
|
||||
GetClusterInfos() []*model.ClusterInfo
|
||||
SendClusterMessage(cluster *model.ClusterMessage)
|
||||
NotifyMsg(buf []byte)
|
||||
|
||||
Ссылка в новой задаче
Block a user