github.com/lologarithm/mattermost-server@v5.3.2-0.20181002060438-c82a84ed765b+incompatible/einterfaces/elasticsearch.go (about) 1 // Copyright (c) 2017-present Mattermost, Inc. All Rights Reserved. 2 // See License.txt for license information. 3 4 package einterfaces 5 6 import ( 7 "time" 8 9 "github.com/mattermost/mattermost-server/model" 10 ) 11 12 type ElasticsearchInterface interface { 13 Start() *model.AppError 14 Stop() *model.AppError 15 IndexPost(post *model.Post, teamId string) *model.AppError 16 SearchPosts(channels *model.ChannelList, searchParams []*model.SearchParams, page, perPage int) ([]string, model.PostSearchMatches, *model.AppError) 17 DeletePost(post *model.Post) *model.AppError 18 TestConfig(cfg *model.Config) *model.AppError 19 PurgeIndexes() *model.AppError 20 DataRetentionDeleteIndexes(cutoff time.Time) *model.AppError 21 }