sqlstore

package
v5.5.1+incompatible Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 12, 2018 License: AGPL-3.0, Apache-2.0 Imports: 25 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ALL_CHANNEL_MEMBERS_FOR_USER_CACHE_SIZE = model.SESSION_CACHE_SIZE
	ALL_CHANNEL_MEMBERS_FOR_USER_CACHE_SEC  = 900 // 15 mins

	ALL_CHANNEL_MEMBERS_NOTIFY_PROPS_FOR_CHANNEL_CACHE_SIZE = model.SESSION_CACHE_SIZE
	ALL_CHANNEL_MEMBERS_NOTIFY_PROPS_FOR_CHANNEL_CACHE_SEC  = 1800 // 30 mins

	CHANNEL_MEMBERS_COUNTS_CACHE_SIZE = model.CHANNEL_CACHE_SIZE
	CHANNEL_MEMBERS_COUNTS_CACHE_SEC  = 1800 // 30 mins

	CHANNEL_CACHE_SEC = 900 // 15 mins
)
View Source
const (
	EMOJI_CACHE_SIZE = 5000
	EMOJI_CACHE_SEC  = 1800 // 30 mins
)
View Source
const (
	FILE_INFO_CACHE_SIZE = 25000
	FILE_INFO_CACHE_SEC  = 1800 // 30 minutes
)
View Source
const (
	LAST_POST_TIME_CACHE_SIZE = 25000
	LAST_POST_TIME_CACHE_SEC  = 900 // 15 minutes

	LAST_POSTS_CACHE_SIZE = 1000
	LAST_POSTS_CACHE_SEC  = 900 // 15 minutes
)
View Source
const (
	INDEX_TYPE_FULL_TEXT = "full_text"
	INDEX_TYPE_DEFAULT   = "default"
	DB_PING_ATTEMPTS     = 18
	DB_PING_TIMEOUT_SECS = 10
)
View Source
const (
	EXIT_GENERIC_FAILURE             = 1
	EXIT_CREATE_TABLE                = 100
	EXIT_DB_OPEN                     = 101
	EXIT_PING                        = 102
	EXIT_NO_DRIVER                   = 103
	EXIT_TABLE_EXISTS                = 104
	EXIT_TABLE_EXISTS_MYSQL          = 105
	EXIT_COLUMN_EXISTS               = 106
	EXIT_DOES_COLUMN_EXISTS_POSTGRES = 107
	EXIT_DOES_COLUMN_EXISTS_MYSQL    = 108
	EXIT_DOES_COLUMN_EXISTS_MISSING  = 109
	EXIT_CREATE_COLUMN_POSTGRES      = 110
	EXIT_CREATE_COLUMN_MYSQL         = 111
	EXIT_CREATE_COLUMN_MISSING       = 112
	EXIT_REMOVE_COLUMN               = 113
	EXIT_RENAME_COLUMN               = 114
	EXIT_MAX_COLUMN                  = 115
	EXIT_ALTER_COLUMN                = 116
	EXIT_CREATE_INDEX_POSTGRES       = 117
	EXIT_CREATE_INDEX_MYSQL          = 118
	EXIT_CREATE_INDEX_FULL_MYSQL     = 119
	EXIT_CREATE_INDEX_MISSING        = 120
	EXIT_REMOVE_INDEX_POSTGRES       = 121
	EXIT_REMOVE_INDEX_MYSQL          = 122
	EXIT_REMOVE_INDEX_MISSING        = 123
	EXIT_REMOVE_TABLE                = 134
	EXIT_CREATE_INDEX_SQLITE         = 135
	EXIT_REMOVE_INDEX_SQLITE         = 136
	EXIT_TABLE_EXISTS_SQLITE         = 137
	EXIT_DOES_COLUMN_EXISTS_SQLITE   = 138
)
View Source
const (
	VERSION_5_5_0            = "5.5.0"
	VERSION_5_4_0            = "5.4.0"
	VERSION_5_3_0            = "5.3.0"
	VERSION_5_2_0            = "5.2.0"
	VERSION_5_1_0            = "5.1.0"
	VERSION_5_0_0            = "5.0.0"
	VERSION_4_10_0           = "4.10.0"
	VERSION_4_9_0            = "4.9.0"
	VERSION_4_8_1            = "4.8.1"
	VERSION_4_8_0            = "4.8.0"
	VERSION_4_7_2            = "4.7.2"
	VERSION_4_7_1            = "4.7.1"
	VERSION_4_7_0            = "4.7.0"
	VERSION_4_6_0            = "4.6.0"
	VERSION_4_5_0            = "4.5.0"
	VERSION_4_4_0            = "4.4.0"
	VERSION_4_3_0            = "4.3.0"
	VERSION_4_2_0            = "4.2.0"
	VERSION_4_1_0            = "4.1.0"
	VERSION_4_0_0            = "4.0.0"
	VERSION_3_10_0           = "3.10.0"
	VERSION_3_9_0            = "3.9.0"
	VERSION_3_8_0            = "3.8.0"
	VERSION_3_7_0            = "3.7.0"
	VERSION_3_6_0            = "3.6.0"
	VERSION_3_5_0            = "3.5.0"
	VERSION_3_4_0            = "3.4.0"
	VERSION_3_3_0            = "3.3.0"
	VERSION_3_2_0            = "3.2.0"
	VERSION_3_1_0            = "3.1.0"
	VERSION_3_0_0            = "3.0.0"
	OLDEST_SUPPORTED_VERSION = VERSION_3_0_0
)
View Source
const (
	EXIT_VERSION_SAVE_MISSING = 1001
	EXIT_TOO_OLD              = 1002
	EXIT_VERSION_SAVE         = 1003
	EXIT_THEME_MIGRATION      = 1004
)
View Source
const (
	PROFILES_IN_CHANNEL_CACHE_SIZE = model.CHANNEL_CACHE_SIZE
	PROFILES_IN_CHANNEL_CACHE_SEC  = 900 // 15 mins
	PROFILE_BY_IDS_CACHE_SIZE      = model.SESSION_CACHE_SIZE
	PROFILE_BY_IDS_CACHE_SEC       = 900 // 15 mins
)
View Source
const (
	WEBHOOK_CACHE_SIZE = 25000
	WEBHOOK_CACHE_SEC  = 900 // 15 minutes
)
View Source
const (
	MISSING_STATUS_ERROR = "store.sql_status.get.missing.app_error"
)
View Source
const (
	SESSIONS_CLEANUP_DELAY_MILLISECONDS = 100
)
View Source
const (
	TEAM_MEMBER_EXISTS_ERROR = "store.sql_team.save_member.exists.app_error"
)
View Source
const (
	// Set HasReactions = true if and only if the post has reactions, update UpdateAt only if HasReactions changes
	UPDATE_POST_HAS_REACTIONS_ON_DELETE_QUERY = `` /* 270-byte string literal not displayed */

)

Variables

View Source
var (
	USER_SEARCH_TYPE_NAMES_NO_FULL_NAME = []string{"Username", "Nickname"}
	USER_SEARCH_TYPE_NAMES              = []string{"Username", "FirstName", "LastName", "Nickname"}
	USER_SEARCH_TYPE_ALL_NO_FULL_NAME   = []string{"Username", "Nickname", "Email"}
	USER_SEARCH_TYPE_ALL                = []string{"Username", "FirstName", "LastName", "Nickname", "Email"}
)
View Source
var CHANNEL_MEMBERS_WITH_SCHEME_SELECT_QUERY = `` /* 574-byte string literal not displayed */
View Source
var TEAM_MEMBERS_WITH_SCHEME_SELECT_QUERY = `` /* 285-byte string literal not displayed */

Functions

func IsUniqueConstraintError

func IsUniqueConstraintError(err error, indexName []string) bool

func NewChannelMemberFromModel

func NewChannelMemberFromModel(cm *model.ChannelMember) *channelMember

func NewSqlAuditStore

func NewSqlAuditStore(sqlStore SqlStore) store.AuditStore

func NewSqlChannelMemberHistoryStore

func NewSqlChannelMemberHistoryStore(sqlStore SqlStore) store.ChannelMemberHistoryStore

func NewSqlChannelStore

func NewSqlChannelStore(sqlStore SqlStore, metrics einterfaces.MetricsInterface) store.ChannelStore

func NewSqlChannelStoreExperimental

func NewSqlChannelStoreExperimental(sqlStore SqlStore, metrics einterfaces.MetricsInterface, enabled bool) store.ChannelStore

func NewSqlClusterDiscoveryStore

func NewSqlClusterDiscoveryStore(sqlStore SqlStore) store.ClusterDiscoveryStore

func NewSqlCommandStore

func NewSqlCommandStore(sqlStore SqlStore) store.CommandStore

func NewSqlCommandWebhookStore

func NewSqlCommandWebhookStore(sqlStore SqlStore) store.CommandWebhookStore

func NewSqlComplianceStore

func NewSqlComplianceStore(sqlStore SqlStore) store.ComplianceStore

func NewSqlEmojiStore

func NewSqlEmojiStore(sqlStore SqlStore, metrics einterfaces.MetricsInterface) store.EmojiStore

func NewSqlFileInfoStore

func NewSqlFileInfoStore(sqlStore SqlStore, metrics einterfaces.MetricsInterface) store.FileInfoStore

func NewSqlJobStore

func NewSqlJobStore(sqlStore SqlStore) store.JobStore

func NewSqlLicenseStore

func NewSqlLicenseStore(sqlStore SqlStore) store.LicenseStore

func NewSqlOAuthStore

func NewSqlOAuthStore(sqlStore SqlStore) store.OAuthStore

func NewSqlPluginStore

func NewSqlPluginStore(sqlStore SqlStore) store.PluginStore

func NewSqlPostStore

func NewSqlPostStore(sqlStore SqlStore, metrics einterfaces.MetricsInterface) store.PostStore

func NewSqlPreferenceStore

func NewSqlPreferenceStore(sqlStore SqlStore) store.PreferenceStore

func NewSqlSessionStore

func NewSqlSessionStore(sqlStore SqlStore) store.SessionStore

func NewSqlStatusStore

func NewSqlStatusStore(sqlStore SqlStore) store.StatusStore

func NewSqlSystemStore

func NewSqlSystemStore(sqlStore SqlStore) store.SystemStore

func NewSqlTeamStore

func NewSqlTeamStore(sqlStore SqlStore) store.TeamStore

func NewSqlTermsOfServiceStore

func NewSqlTermsOfServiceStore(sqlStore SqlStore, metrics einterfaces.MetricsInterface) store.TermsOfServiceStore

func NewSqlTokenStore

func NewSqlTokenStore(sqlStore SqlStore) store.TokenStore

func NewSqlUserAccessTokenStore

func NewSqlUserAccessTokenStore(sqlStore SqlStore) store.UserAccessTokenStore

func NewSqlUserStore

func NewSqlUserStore(sqlStore SqlStore, metrics einterfaces.MetricsInterface) store.UserStore

func NewSqlWebhookStore

func NewSqlWebhookStore(sqlStore SqlStore, metrics einterfaces.MetricsInterface) store.WebhookStore

func NewTeamMemberFromModel

func NewTeamMemberFromModel(tm *model.TeamMember) *teamMember

func UpgradeDatabase

func UpgradeDatabase(sqlStore SqlStore)

func UpgradeDatabaseToVersion31

func UpgradeDatabaseToVersion31(sqlStore SqlStore)

func UpgradeDatabaseToVersion310

func UpgradeDatabaseToVersion310(sqlStore SqlStore)

func UpgradeDatabaseToVersion32

func UpgradeDatabaseToVersion32(sqlStore SqlStore)

func UpgradeDatabaseToVersion33

func UpgradeDatabaseToVersion33(sqlStore SqlStore)

func UpgradeDatabaseToVersion34

func UpgradeDatabaseToVersion34(sqlStore SqlStore)

func UpgradeDatabaseToVersion35

func UpgradeDatabaseToVersion35(sqlStore SqlStore)

func UpgradeDatabaseToVersion36

func UpgradeDatabaseToVersion36(sqlStore SqlStore)

func UpgradeDatabaseToVersion37

func UpgradeDatabaseToVersion37(sqlStore SqlStore)

func UpgradeDatabaseToVersion38

func UpgradeDatabaseToVersion38(sqlStore SqlStore)

func UpgradeDatabaseToVersion39

func UpgradeDatabaseToVersion39(sqlStore SqlStore)

func UpgradeDatabaseToVersion40

func UpgradeDatabaseToVersion40(sqlStore SqlStore)

func UpgradeDatabaseToVersion41

func UpgradeDatabaseToVersion41(sqlStore SqlStore)

func UpgradeDatabaseToVersion410

func UpgradeDatabaseToVersion410(sqlStore SqlStore)

func UpgradeDatabaseToVersion42

func UpgradeDatabaseToVersion42(sqlStore SqlStore)

func UpgradeDatabaseToVersion43

func UpgradeDatabaseToVersion43(sqlStore SqlStore)

func UpgradeDatabaseToVersion44

func UpgradeDatabaseToVersion44(sqlStore SqlStore)

func UpgradeDatabaseToVersion45

func UpgradeDatabaseToVersion45(sqlStore SqlStore)

func UpgradeDatabaseToVersion46

func UpgradeDatabaseToVersion46(sqlStore SqlStore)

func UpgradeDatabaseToVersion47

func UpgradeDatabaseToVersion47(sqlStore SqlStore)

func UpgradeDatabaseToVersion471

func UpgradeDatabaseToVersion471(sqlStore SqlStore)

If any new instances started with 4.7, they would have the bad Email column on the ChannelMemberHistory table. So for those cases we need to do an upgrade between 4.7.0 and 4.7.1

func UpgradeDatabaseToVersion472

func UpgradeDatabaseToVersion472(sqlStore SqlStore)

func UpgradeDatabaseToVersion48

func UpgradeDatabaseToVersion48(sqlStore SqlStore)

func UpgradeDatabaseToVersion481

func UpgradeDatabaseToVersion481(sqlStore SqlStore)

func UpgradeDatabaseToVersion49

func UpgradeDatabaseToVersion49(sqlStore SqlStore)

func UpgradeDatabaseToVersion50

func UpgradeDatabaseToVersion50(sqlStore SqlStore)

func UpgradeDatabaseToVersion51

func UpgradeDatabaseToVersion51(sqlStore SqlStore)

func UpgradeDatabaseToVersion52

func UpgradeDatabaseToVersion52(sqlStore SqlStore)

func UpgradeDatabaseToVersion53

func UpgradeDatabaseToVersion53(sqlStore SqlStore)

func UpgradeDatabaseToVersion54

func UpgradeDatabaseToVersion54(sqlStore SqlStore)

func UpgradeDatabaseToVersion55

func UpgradeDatabaseToVersion55(sqlStore SqlStore)

Types

type Role

type Role struct {
	Id            string
	Name          string
	DisplayName   string
	Description   string
	CreateAt      int64
	UpdateAt      int64
	DeleteAt      int64
	Permissions   string
	SchemeManaged bool
	BuiltIn       bool
}

func NewRoleFromModel

func NewRoleFromModel(role *model.Role) *Role

func (Role) ToModel

func (role Role) ToModel() *model.Role

type SqlAuditStore

type SqlAuditStore struct {
	SqlStore
}

func (SqlAuditStore) CreateIndexesIfNotExists

func (s SqlAuditStore) CreateIndexesIfNotExists()

func (SqlAuditStore) Get

func (s SqlAuditStore) Get(user_id string, offset int, limit int) store.StoreChannel

func (SqlAuditStore) PermanentDeleteBatch

func (s SqlAuditStore) PermanentDeleteBatch(endTime int64, limit int64) store.StoreChannel

func (SqlAuditStore) PermanentDeleteByUser

func (s SqlAuditStore) PermanentDeleteByUser(userId string) store.StoreChannel

func (SqlAuditStore) Save

func (s SqlAuditStore) Save(audit *model.Audit) store.StoreChannel

type SqlChannelMemberHistoryStore

type SqlChannelMemberHistoryStore struct {
	SqlStore
}

func (SqlChannelMemberHistoryStore) GetUsersInChannelDuring

func (s SqlChannelMemberHistoryStore) GetUsersInChannelDuring(startTime int64, endTime int64, channelId string) store.StoreChannel

func (SqlChannelMemberHistoryStore) LogJoinEvent

func (s SqlChannelMemberHistoryStore) LogJoinEvent(userId string, channelId string, joinTime int64) store.StoreChannel

func (SqlChannelMemberHistoryStore) LogLeaveEvent

func (s SqlChannelMemberHistoryStore) LogLeaveEvent(userId string, channelId string, leaveTime int64) store.StoreChannel

func (SqlChannelMemberHistoryStore) PermanentDeleteBatch

func (s SqlChannelMemberHistoryStore) PermanentDeleteBatch(endTime int64, limit int64) store.StoreChannel

type SqlChannelStore

type SqlChannelStore struct {
	SqlStore
	// contains filtered or unexported fields
}

func (SqlChannelStore) AnalyticsDeletedTypeCount

func (s SqlChannelStore) AnalyticsDeletedTypeCount(teamId string, channelType string) store.StoreChannel

func (SqlChannelStore) AnalyticsTypeCount

func (s SqlChannelStore) AnalyticsTypeCount(teamId string, channelType string) store.StoreChannel

func (SqlChannelStore) AutocompleteInTeam

func (s SqlChannelStore) AutocompleteInTeam(teamId string, term string, includeDeleted bool) store.StoreChannel

func (SqlChannelStore) AutocompleteInTeamForSearch

func (s SqlChannelStore) AutocompleteInTeamForSearch(teamId string, userId string, term string, includeDeleted bool) store.StoreChannel

func (SqlChannelStore) ClearAllCustomRoleAssignments

func (s SqlChannelStore) ClearAllCustomRoleAssignments() store.StoreChannel

func (SqlChannelStore) ClearCaches

func (s SqlChannelStore) ClearCaches()

func (SqlChannelStore) CreateDirectChannel

func (s SqlChannelStore) CreateDirectChannel(userId string, otherUserId string) store.StoreChannel

func (SqlChannelStore) CreateIndexesIfNotExists

func (s SqlChannelStore) CreateIndexesIfNotExists()

func (SqlChannelStore) Delete

func (s SqlChannelStore) Delete(channelId string, time int64) store.StoreChannel

Delete records the given deleted timestamp to the channel in question.

@see ChannelStoreExperimental for how this update propagates to the PublicChannels table.

func (SqlChannelStore) DisableExperimentalPublicChannelsMaterialization

func (s SqlChannelStore) DisableExperimentalPublicChannelsMaterialization()

func (SqlChannelStore) DropPublicChannels

func (s SqlChannelStore) DropPublicChannels() error

func (SqlChannelStore) EnableExperimentalPublicChannelsMaterialization

func (s SqlChannelStore) EnableExperimentalPublicChannelsMaterialization()

func (SqlChannelStore) Get

func (s SqlChannelStore) Get(id string, allowFromCache bool) store.StoreChannel

func (SqlChannelStore) GetAll

func (s SqlChannelStore) GetAll(teamId string) store.StoreChannel

func (SqlChannelStore) GetAllChannelMembersForUser

func (s SqlChannelStore) GetAllChannelMembersForUser(userId string, allowFromCache bool, includeDeleted bool) store.StoreChannel

func (SqlChannelStore) GetAllChannelMembersNotifyPropsForChannel

func (s SqlChannelStore) GetAllChannelMembersNotifyPropsForChannel(channelId string, allowFromCache bool) store.StoreChannel

func (SqlChannelStore) GetAllChannelsForExportAfter

func (s SqlChannelStore) GetAllChannelsForExportAfter(limit int, afterId string) store.StoreChannel

func (SqlChannelStore) GetByName

func (s SqlChannelStore) GetByName(teamId string, name string, allowFromCache bool) store.StoreChannel

func (SqlChannelStore) GetByNameIncludeDeleted

func (s SqlChannelStore) GetByNameIncludeDeleted(teamId string, name string, allowFromCache bool) store.StoreChannel

func (SqlChannelStore) GetByNames

func (s SqlChannelStore) GetByNames(teamId string, names []string, allowFromCache bool) store.StoreChannel

func (SqlChannelStore) GetChannelCounts

func (s SqlChannelStore) GetChannelCounts(teamId string, userId string) store.StoreChannel

func (SqlChannelStore) GetChannelMembersForExport

func (s SqlChannelStore) GetChannelMembersForExport(userId string, teamId string) store.StoreChannel

func (SqlChannelStore) GetChannelUnread

func (s SqlChannelStore) GetChannelUnread(channelId, userId string) store.StoreChannel

func (SqlChannelStore) GetChannels

func (s SqlChannelStore) GetChannels(teamId string, userId string, includeDeleted bool) store.StoreChannel

func (SqlChannelStore) GetChannelsByScheme

func (s SqlChannelStore) GetChannelsByScheme(schemeId string, offset int, limit int) store.StoreChannel

func (SqlChannelStore) GetDeleted

func (s SqlChannelStore) GetDeleted(teamId string, offset int, limit int) store.StoreChannel

func (SqlChannelStore) GetDeletedByName

func (s SqlChannelStore) GetDeletedByName(teamId string, name string) store.StoreChannel

func (SqlChannelStore) GetForPost

func (s SqlChannelStore) GetForPost(postId string) store.StoreChannel

func (SqlChannelStore) GetFromMaster

func (s SqlChannelStore) GetFromMaster(id string) store.StoreChannel

func (SqlChannelStore) GetMember

func (s SqlChannelStore) GetMember(channelId string, userId string) store.StoreChannel

func (SqlChannelStore) GetMemberCount

func (s SqlChannelStore) GetMemberCount(channelId string, allowFromCache bool) store.StoreChannel

func (SqlChannelStore) GetMemberCountFromCache

func (s SqlChannelStore) GetMemberCountFromCache(channelId string) int64

func (SqlChannelStore) GetMemberForPost

func (s SqlChannelStore) GetMemberForPost(postId string, userId string) store.StoreChannel

func (SqlChannelStore) GetMembers

func (s SqlChannelStore) GetMembers(channelId string, offset, limit int) store.StoreChannel

func (SqlChannelStore) GetMembersByIds

func (s SqlChannelStore) GetMembersByIds(channelId string, userIds []string) store.StoreChannel

func (SqlChannelStore) GetMembersForUser

func (s SqlChannelStore) GetMembersForUser(teamId string, userId string) store.StoreChannel

func (SqlChannelStore) GetMoreChannels

func (s SqlChannelStore) GetMoreChannels(teamId string, userId string, offset int, limit int) store.StoreChannel

func (SqlChannelStore) GetPinnedPosts

func (s SqlChannelStore) GetPinnedPosts(channelId string) store.StoreChannel

func (SqlChannelStore) GetPublicChannelsByIdsForTeam

func (s SqlChannelStore) GetPublicChannelsByIdsForTeam(teamId string, channelIds []string) store.StoreChannel

func (SqlChannelStore) GetPublicChannelsForTeam

func (s SqlChannelStore) GetPublicChannelsForTeam(teamId string, offset int, limit int) store.StoreChannel

func (SqlChannelStore) GetTeamChannels

func (s SqlChannelStore) GetTeamChannels(teamId string) store.StoreChannel

func (SqlChannelStore) IncrementMentionCount

func (s SqlChannelStore) IncrementMentionCount(channelId string, userId string) store.StoreChannel

func (SqlChannelStore) InvalidateAllChannelMembersForUser

func (s SqlChannelStore) InvalidateAllChannelMembersForUser(userId string)

func (SqlChannelStore) InvalidateCacheForChannelMembersNotifyProps

func (s SqlChannelStore) InvalidateCacheForChannelMembersNotifyProps(channelId string)

func (SqlChannelStore) InvalidateChannel

func (s SqlChannelStore) InvalidateChannel(id string)

func (SqlChannelStore) InvalidateChannelByName

func (s SqlChannelStore) InvalidateChannelByName(teamId, name string)

func (SqlChannelStore) InvalidateMemberCount

func (s SqlChannelStore) InvalidateMemberCount(channelId string)

func (SqlChannelStore) IsExperimentalPublicChannelsMaterializationEnabled

func (s SqlChannelStore) IsExperimentalPublicChannelsMaterializationEnabled() bool

func (SqlChannelStore) IsUserInChannelUseCache

func (s SqlChannelStore) IsUserInChannelUseCache(userId string, channelId string) bool

func (SqlChannelStore) MigrateChannelMembers

func (s SqlChannelStore) MigrateChannelMembers(fromChannelId string, fromUserId string) store.StoreChannel

This function does the Advanced Permissions Phase 2 migration for ChannelMember objects. It performs the migration in batches as a single transaction per batch to ensure consistency but to also minimise execution time to avoid causing unnecessary table locks. **THIS FUNCTION SHOULD NOT BE USED FOR ANY OTHER PURPOSE.** Executing this function *after* the new Schemes functionality has been used on an installation will have unintended consequences.

func (SqlChannelStore) MigratePublicChannels

func (s SqlChannelStore) MigratePublicChannels() error

func (SqlChannelStore) PermanentDelete

func (s SqlChannelStore) PermanentDelete(channelId string) store.StoreChannel

PermanentDelete removes the given channel from the database.

@see ChannelStoreExperimental for how this update propagates to the PublicChannels table.

func (SqlChannelStore) PermanentDeleteByTeam

func (s SqlChannelStore) PermanentDeleteByTeam(teamId string) store.StoreChannel

PermanentDeleteByTeam removes all channels for the given team from the database.

@see ChannelStoreExperimental for how this update propagates to the PublicChannels table.

func (SqlChannelStore) PermanentDeleteMembersByChannel

func (s SqlChannelStore) PermanentDeleteMembersByChannel(channelId string) store.StoreChannel

func (SqlChannelStore) PermanentDeleteMembersByUser

func (s SqlChannelStore) PermanentDeleteMembersByUser(userId string) store.StoreChannel

func (SqlChannelStore) RemoveAllDeactivatedMembers

func (s SqlChannelStore) RemoveAllDeactivatedMembers(channelId string) store.StoreChannel

func (SqlChannelStore) RemoveMember

func (s SqlChannelStore) RemoveMember(channelId string, userId string) store.StoreChannel

func (SqlChannelStore) ResetAllChannelSchemes

func (s SqlChannelStore) ResetAllChannelSchemes() store.StoreChannel

func (SqlChannelStore) ResetLastPostAt

func (s SqlChannelStore) ResetLastPostAt() store.StoreChannel

func (SqlChannelStore) Restore

func (s SqlChannelStore) Restore(channelId string, time int64) store.StoreChannel

Restore reverts a previous deleted timestamp from the channel in question.

@see ChannelStoreExperimental for how this update propagates to the PublicChannels table.

func (SqlChannelStore) Save

func (s SqlChannelStore) Save(channel *model.Channel, maxChannelsPerTeam int64) store.StoreChannel

Save writes the (non-direct) channel channel to the database.

@see ChannelStoreExperimental for how this update propagates to the PublicChannels table.

func (SqlChannelStore) SaveDirectChannel

func (s SqlChannelStore) SaveDirectChannel(directchannel *model.Channel, member1 *model.ChannelMember, member2 *model.ChannelMember) store.StoreChannel

func (SqlChannelStore) SaveMember

func (s SqlChannelStore) SaveMember(member *model.ChannelMember) store.StoreChannel

func (SqlChannelStore) SearchInTeam

func (s SqlChannelStore) SearchInTeam(teamId string, term string, includeDeleted bool) store.StoreChannel

func (SqlChannelStore) SearchMore

func (s SqlChannelStore) SearchMore(userId string, teamId string, term string) store.StoreChannel

func (SqlChannelStore) SetDeleteAt

func (s SqlChannelStore) SetDeleteAt(channelId string, deleteAt, updateAt int64) store.StoreChannel

SetDeleteAt records the given deleted and updated timestamp to the channel in question.

@see ChannelStoreExperimental for how this update propagates to the PublicChannels table.

func (SqlChannelStore) Update

func (s SqlChannelStore) Update(channel *model.Channel) store.StoreChannel

Update writes the updated channel to the database.

@see ChannelStoreExperimental for how this update propagates to the PublicChannels table.

func (SqlChannelStore) UpdateLastViewedAt

func (s SqlChannelStore) UpdateLastViewedAt(channelIds []string, userId string) store.StoreChannel

func (SqlChannelStore) UpdateMember

func (s SqlChannelStore) UpdateMember(member *model.ChannelMember) store.StoreChannel

type SqlChannelStoreExperimental

type SqlChannelStoreExperimental struct {
	SqlChannelStore
	// contains filtered or unexported fields
}

func (SqlChannelStoreExperimental) AutocompleteInTeam

func (s SqlChannelStoreExperimental) AutocompleteInTeam(teamId string, term string, includeDeleted bool) store.StoreChannel

func (SqlChannelStoreExperimental) CreateIndexesIfNotExists

func (s SqlChannelStoreExperimental) CreateIndexesIfNotExists()

func (SqlChannelStoreExperimental) Delete

func (s SqlChannelStoreExperimental) Delete(channelId string, time int64) store.StoreChannel

func (SqlChannelStoreExperimental) DisableExperimentalPublicChannelsMaterialization

func (s SqlChannelStoreExperimental) DisableExperimentalPublicChannelsMaterialization()

func (SqlChannelStoreExperimental) DropPublicChannels

func (s SqlChannelStoreExperimental) DropPublicChannels() error

DropPublicChannels removes the public channels table.

func (SqlChannelStoreExperimental) EnableExperimentalPublicChannelsMaterialization

func (s SqlChannelStoreExperimental) EnableExperimentalPublicChannelsMaterialization()

func (SqlChannelStoreExperimental) GetMoreChannels

func (s SqlChannelStoreExperimental) GetMoreChannels(teamId string, userId string, offset int, limit int) store.StoreChannel

func (SqlChannelStoreExperimental) GetPublicChannelsByIdsForTeam

func (s SqlChannelStoreExperimental) GetPublicChannelsByIdsForTeam(teamId string, channelIds []string) store.StoreChannel

func (SqlChannelStoreExperimental) GetPublicChannelsForTeam

func (s SqlChannelStoreExperimental) GetPublicChannelsForTeam(teamId string, offset int, limit int) store.StoreChannel

func (SqlChannelStoreExperimental) IsExperimentalPublicChannelsMaterializationEnabled

func (s SqlChannelStoreExperimental) IsExperimentalPublicChannelsMaterializationEnabled() bool

func (SqlChannelStoreExperimental) MigratePublicChannels

func (s SqlChannelStoreExperimental) MigratePublicChannels() error

migratePublicChannels initializes the PublicChannels table with data created before this version of the Mattermost server kept it up-to-date.

func (SqlChannelStoreExperimental) PermanentDelete

func (s SqlChannelStoreExperimental) PermanentDelete(channelId string) store.StoreChannel

func (SqlChannelStoreExperimental) PermanentDeleteByTeam

func (s SqlChannelStoreExperimental) PermanentDeleteByTeam(teamId string) store.StoreChannel

func (SqlChannelStoreExperimental) Restore

func (s SqlChannelStoreExperimental) Restore(channelId string, time int64) store.StoreChannel

func (SqlChannelStoreExperimental) Save

func (s SqlChannelStoreExperimental) Save(channel *model.Channel, maxChannelsPerTeam int64) store.StoreChannel

func (SqlChannelStoreExperimental) SearchInTeam

func (s SqlChannelStoreExperimental) SearchInTeam(teamId string, term string, includeDeleted bool) store.StoreChannel

func (SqlChannelStoreExperimental) SearchMore

func (s SqlChannelStoreExperimental) SearchMore(userId string, teamId string, term string) store.StoreChannel

func (SqlChannelStoreExperimental) SetDeleteAt

func (s SqlChannelStoreExperimental) SetDeleteAt(channelId string, deleteAt, updateAt int64) store.StoreChannel

func (SqlChannelStoreExperimental) Update

type SqlCommandStore

type SqlCommandStore struct {
	SqlStore
}

func (SqlCommandStore) AnalyticsCommandCount

func (s SqlCommandStore) AnalyticsCommandCount(teamId string) store.StoreChannel

func (SqlCommandStore) CreateIndexesIfNotExists

func (s SqlCommandStore) CreateIndexesIfNotExists()

func (SqlCommandStore) Delete

func (s SqlCommandStore) Delete(commandId string, time int64) store.StoreChannel

func (SqlCommandStore) Get

func (SqlCommandStore) GetByTeam

func (s SqlCommandStore) GetByTeam(teamId string) store.StoreChannel

func (SqlCommandStore) GetByTrigger

func (s SqlCommandStore) GetByTrigger(teamId string, trigger string) store.StoreChannel

func (SqlCommandStore) PermanentDeleteByTeam

func (s SqlCommandStore) PermanentDeleteByTeam(teamId string) store.StoreChannel

func (SqlCommandStore) PermanentDeleteByUser

func (s SqlCommandStore) PermanentDeleteByUser(userId string) store.StoreChannel

func (SqlCommandStore) Save

func (s SqlCommandStore) Save(command *model.Command) store.StoreChannel

func (SqlCommandStore) Update

type SqlCommandWebhookStore

type SqlCommandWebhookStore struct {
	SqlStore
}

func (SqlCommandWebhookStore) Cleanup

func (s SqlCommandWebhookStore) Cleanup()

func (SqlCommandWebhookStore) CreateIndexesIfNotExists

func (s SqlCommandWebhookStore) CreateIndexesIfNotExists()

func (SqlCommandWebhookStore) Get

func (SqlCommandWebhookStore) Save

func (SqlCommandWebhookStore) TryUse

func (s SqlCommandWebhookStore) TryUse(id string, limit int) store.StoreChannel

type SqlComplianceStore

type SqlComplianceStore struct {
	SqlStore
}

func (SqlComplianceStore) ComplianceExport

func (s SqlComplianceStore) ComplianceExport(job *model.Compliance) store.StoreChannel

func (SqlComplianceStore) CreateIndexesIfNotExists

func (s SqlComplianceStore) CreateIndexesIfNotExists()

func (SqlComplianceStore) Get

func (SqlComplianceStore) GetAll

func (s SqlComplianceStore) GetAll(offset, limit int) store.StoreChannel

func (SqlComplianceStore) MessageExport

func (s SqlComplianceStore) MessageExport(after int64, limit int) store.StoreChannel

func (SqlComplianceStore) Save

func (SqlComplianceStore) Update

func (us SqlComplianceStore) Update(compliance *model.Compliance) store.StoreChannel

type SqlEmojiStore

type SqlEmojiStore struct {
	SqlStore
	// contains filtered or unexported fields
}

func (SqlEmojiStore) CreateIndexesIfNotExists

func (es SqlEmojiStore) CreateIndexesIfNotExists()

func (SqlEmojiStore) Delete

func (es SqlEmojiStore) Delete(id string, time int64) store.StoreChannel

func (SqlEmojiStore) Get

func (es SqlEmojiStore) Get(id string, allowFromCache bool) store.StoreChannel

func (SqlEmojiStore) GetByName

func (es SqlEmojiStore) GetByName(name string) store.StoreChannel

func (SqlEmojiStore) GetList

func (es SqlEmojiStore) GetList(offset, limit int, sort string) store.StoreChannel

func (SqlEmojiStore) Save

func (es SqlEmojiStore) Save(emoji *model.Emoji) store.StoreChannel

func (SqlEmojiStore) Search

func (es SqlEmojiStore) Search(name string, prefixOnly bool, limit int) store.StoreChannel

type SqlFileInfoStore

type SqlFileInfoStore struct {
	SqlStore
	// contains filtered or unexported fields
}

func (SqlFileInfoStore) AttachToPost

func (fs SqlFileInfoStore) AttachToPost(fileId, postId string) store.StoreChannel

func (SqlFileInfoStore) ClearCaches

func (fs SqlFileInfoStore) ClearCaches()

func (SqlFileInfoStore) CreateIndexesIfNotExists

func (fs SqlFileInfoStore) CreateIndexesIfNotExists()

func (SqlFileInfoStore) DeleteForPost

func (fs SqlFileInfoStore) DeleteForPost(postId string) store.StoreChannel

func (SqlFileInfoStore) Get

func (SqlFileInfoStore) GetByPath

func (fs SqlFileInfoStore) GetByPath(path string) store.StoreChannel

func (SqlFileInfoStore) GetForPost

func (fs SqlFileInfoStore) GetForPost(postId string, readFromMaster bool, allowFromCache bool) store.StoreChannel

func (SqlFileInfoStore) GetForUser

func (fs SqlFileInfoStore) GetForUser(userId string) store.StoreChannel

func (SqlFileInfoStore) InvalidateFileInfosForPostCache

func (fs SqlFileInfoStore) InvalidateFileInfosForPostCache(postId string)

func (SqlFileInfoStore) PermanentDelete

func (fs SqlFileInfoStore) PermanentDelete(fileId string) store.StoreChannel

func (SqlFileInfoStore) PermanentDeleteBatch

func (s SqlFileInfoStore) PermanentDeleteBatch(endTime int64, limit int64) store.StoreChannel

func (SqlFileInfoStore) PermanentDeleteByUser

func (s SqlFileInfoStore) PermanentDeleteByUser(userId string) store.StoreChannel

func (SqlFileInfoStore) Save

type SqlJobStore

type SqlJobStore struct {
	SqlStore
}

func (SqlJobStore) CreateIndexesIfNotExists

func (jss SqlJobStore) CreateIndexesIfNotExists()

func (SqlJobStore) Delete

func (jss SqlJobStore) Delete(id string) store.StoreChannel

func (SqlJobStore) Get

func (jss SqlJobStore) Get(id string) store.StoreChannel

func (SqlJobStore) GetAllByStatus

func (jss SqlJobStore) GetAllByStatus(status string) store.StoreChannel

func (SqlJobStore) GetAllByType

func (jss SqlJobStore) GetAllByType(jobType string) store.StoreChannel

func (SqlJobStore) GetAllByTypePage

func (jss SqlJobStore) GetAllByTypePage(jobType string, offset int, limit int) store.StoreChannel

func (SqlJobStore) GetAllPage

func (jss SqlJobStore) GetAllPage(offset int, limit int) store.StoreChannel

func (SqlJobStore) GetCountByStatusAndType

func (jss SqlJobStore) GetCountByStatusAndType(status string, jobType string) store.StoreChannel

func (SqlJobStore) GetNewestJobByStatusAndType

func (jss SqlJobStore) GetNewestJobByStatusAndType(status string, jobType string) store.StoreChannel

func (SqlJobStore) Save

func (jss SqlJobStore) Save(job *model.Job) store.StoreChannel

func (SqlJobStore) UpdateOptimistically

func (jss SqlJobStore) UpdateOptimistically(job *model.Job, currentStatus string) store.StoreChannel

func (SqlJobStore) UpdateStatus

func (jss SqlJobStore) UpdateStatus(id string, status string) store.StoreChannel

func (SqlJobStore) UpdateStatusOptimistically

func (jss SqlJobStore) UpdateStatusOptimistically(id string, currentStatus string, newStatus string) store.StoreChannel

type SqlLicenseStore

type SqlLicenseStore struct {
	SqlStore
}

func (SqlLicenseStore) CreateIndexesIfNotExists

func (ls SqlLicenseStore) CreateIndexesIfNotExists()

func (SqlLicenseStore) Get

func (SqlLicenseStore) Save

type SqlOAuthStore

type SqlOAuthStore struct {
	SqlStore
}

func (SqlOAuthStore) CreateIndexesIfNotExists

func (as SqlOAuthStore) CreateIndexesIfNotExists()

func (SqlOAuthStore) DeleteApp

func (as SqlOAuthStore) DeleteApp(id string) store.StoreChannel

func (SqlOAuthStore) GetAccessData

func (as SqlOAuthStore) GetAccessData(token string) store.StoreChannel

func (SqlOAuthStore) GetAccessDataByRefreshToken

func (as SqlOAuthStore) GetAccessDataByRefreshToken(token string) store.StoreChannel

func (SqlOAuthStore) GetAccessDataByUserForApp

func (as SqlOAuthStore) GetAccessDataByUserForApp(userId, clientId string) store.StoreChannel

func (SqlOAuthStore) GetApp

func (as SqlOAuthStore) GetApp(id string) store.StoreChannel

func (SqlOAuthStore) GetAppByUser

func (as SqlOAuthStore) GetAppByUser(userId string, offset, limit int) store.StoreChannel

func (SqlOAuthStore) GetApps

func (as SqlOAuthStore) GetApps(offset, limit int) store.StoreChannel

func (SqlOAuthStore) GetAuthData

func (as SqlOAuthStore) GetAuthData(code string) store.StoreChannel

func (SqlOAuthStore) GetAuthorizedApps

func (as SqlOAuthStore) GetAuthorizedApps(userId string, offset, limit int) store.StoreChannel

func (SqlOAuthStore) GetPreviousAccessData

func (as SqlOAuthStore) GetPreviousAccessData(userId, clientId string) store.StoreChannel

func (SqlOAuthStore) PermanentDeleteAuthDataByUser

func (as SqlOAuthStore) PermanentDeleteAuthDataByUser(userId string) store.StoreChannel

func (SqlOAuthStore) RemoveAccessData

func (as SqlOAuthStore) RemoveAccessData(token string) store.StoreChannel

func (SqlOAuthStore) RemoveAuthData

func (as SqlOAuthStore) RemoveAuthData(code string) store.StoreChannel

func (SqlOAuthStore) SaveAccessData

func (as SqlOAuthStore) SaveAccessData(accessData *model.AccessData) store.StoreChannel

func (SqlOAuthStore) SaveApp

func (as SqlOAuthStore) SaveApp(app *model.OAuthApp) store.StoreChannel

func (SqlOAuthStore) SaveAuthData

func (as SqlOAuthStore) SaveAuthData(authData *model.AuthData) store.StoreChannel

func (SqlOAuthStore) UpdateAccessData

func (as SqlOAuthStore) UpdateAccessData(accessData *model.AccessData) store.StoreChannel

func (SqlOAuthStore) UpdateApp

func (as SqlOAuthStore) UpdateApp(app *model.OAuthApp) store.StoreChannel

type SqlPluginStore

type SqlPluginStore struct {
	SqlStore
}

func (SqlPluginStore) CreateIndexesIfNotExists

func (ps SqlPluginStore) CreateIndexesIfNotExists()

func (SqlPluginStore) Delete

func (ps SqlPluginStore) Delete(pluginId, key string) store.StoreChannel

func (SqlPluginStore) Get

func (ps SqlPluginStore) Get(pluginId, key string) store.StoreChannel

func (SqlPluginStore) SaveOrUpdate

func (ps SqlPluginStore) SaveOrUpdate(kv *model.PluginKeyValue) store.StoreChannel

type SqlPostStore

type SqlPostStore struct {
	SqlStore
	// contains filtered or unexported fields
}

func (*SqlPostStore) AnalyticsPostCount

func (s *SqlPostStore) AnalyticsPostCount(teamId string, mustHaveFile bool, mustHaveHashtag bool) store.StoreChannel

func (*SqlPostStore) AnalyticsPostCountsByDay

func (s *SqlPostStore) AnalyticsPostCountsByDay(teamId string) store.StoreChannel

func (*SqlPostStore) AnalyticsUserCountsWithPostsByDay

func (s *SqlPostStore) AnalyticsUserCountsWithPostsByDay(teamId string) store.StoreChannel

func (*SqlPostStore) ClearCaches

func (s *SqlPostStore) ClearCaches()

func (*SqlPostStore) CreateIndexesIfNotExists

func (s *SqlPostStore) CreateIndexesIfNotExists()

func (*SqlPostStore) Delete

func (s *SqlPostStore) Delete(postId string, time int64, deleteByID string) store.StoreChannel

func (*SqlPostStore) Get

func (*SqlPostStore) GetEtag

func (s *SqlPostStore) GetEtag(channelId string, allowFromCache bool) store.StoreChannel

func (*SqlPostStore) GetFlaggedPosts

func (s *SqlPostStore) GetFlaggedPosts(userId string, offset int, limit int) store.StoreChannel

func (*SqlPostStore) GetFlaggedPostsForChannel

func (s *SqlPostStore) GetFlaggedPostsForChannel(userId, channelId string, offset int, limit int) store.StoreChannel

func (*SqlPostStore) GetFlaggedPostsForTeam

func (s *SqlPostStore) GetFlaggedPostsForTeam(userId, teamId string, offset int, limit int) store.StoreChannel

func (*SqlPostStore) GetMaxPostSize

func (s *SqlPostStore) GetMaxPostSize() store.StoreChannel

GetMaxPostSize returns the maximum number of runes that may be stored in a post.

func (*SqlPostStore) GetOldest

func (s *SqlPostStore) GetOldest() store.StoreChannel

func (*SqlPostStore) GetParentsForExportAfter

func (s *SqlPostStore) GetParentsForExportAfter(limit int, afterId string) store.StoreChannel

func (*SqlPostStore) GetPosts

func (s *SqlPostStore) GetPosts(channelId string, offset int, limit int, allowFromCache bool) store.StoreChannel

func (*SqlPostStore) GetPostsAfter

func (s *SqlPostStore) GetPostsAfter(channelId string, postId string, numPosts int, offset int) store.StoreChannel

func (*SqlPostStore) GetPostsBatchForIndexing

func (s *SqlPostStore) GetPostsBatchForIndexing(startTime int64, endTime int64, limit int) store.StoreChannel

func (*SqlPostStore) GetPostsBefore

func (s *SqlPostStore) GetPostsBefore(channelId string, postId string, numPosts int, offset int) store.StoreChannel

func (*SqlPostStore) GetPostsByIds

func (s *SqlPostStore) GetPostsByIds(postIds []string) store.StoreChannel

func (*SqlPostStore) GetPostsCreatedAt

func (s *SqlPostStore) GetPostsCreatedAt(channelId string, time int64) store.StoreChannel

func (*SqlPostStore) GetPostsSince

func (s *SqlPostStore) GetPostsSince(channelId string, time int64, allowFromCache bool) store.StoreChannel

func (*SqlPostStore) GetRepliesForExport

func (s *SqlPostStore) GetRepliesForExport(parentId string) store.StoreChannel

func (*SqlPostStore) GetSingle

func (s *SqlPostStore) GetSingle(id string) store.StoreChannel

func (*SqlPostStore) InvalidateLastPostTimeCache

func (s *SqlPostStore) InvalidateLastPostTimeCache(channelId string)

func (*SqlPostStore) Overwrite

func (s *SqlPostStore) Overwrite(post *model.Post) store.StoreChannel

func (*SqlPostStore) PermanentDeleteBatch

func (s *SqlPostStore) PermanentDeleteBatch(endTime int64, limit int64) store.StoreChannel

func (*SqlPostStore) PermanentDeleteByChannel

func (s *SqlPostStore) PermanentDeleteByChannel(channelId string) store.StoreChannel

func (*SqlPostStore) PermanentDeleteByUser

func (s *SqlPostStore) PermanentDeleteByUser(userId string) store.StoreChannel

func (*SqlPostStore) Save

func (s *SqlPostStore) Save(post *model.Post) store.StoreChannel

func (*SqlPostStore) Search

func (s *SqlPostStore) Search(teamId string, userId string, params *model.SearchParams) store.StoreChannel

func (*SqlPostStore) Update

func (s *SqlPostStore) Update(newPost *model.Post, oldPost *model.Post) store.StoreChannel

type SqlPreferenceStore

type SqlPreferenceStore struct {
	SqlStore
}

func (SqlPreferenceStore) CleanupFlagsBatch

func (s SqlPreferenceStore) CleanupFlagsBatch(limit int64) store.StoreChannel

func (SqlPreferenceStore) CreateIndexesIfNotExists

func (s SqlPreferenceStore) CreateIndexesIfNotExists()

func (SqlPreferenceStore) Delete

func (s SqlPreferenceStore) Delete(userId, category, name string) store.StoreChannel

func (SqlPreferenceStore) DeleteCategory

func (s SqlPreferenceStore) DeleteCategory(userId string, category string) store.StoreChannel

func (SqlPreferenceStore) DeleteCategoryAndName

func (s SqlPreferenceStore) DeleteCategoryAndName(category string, name string) store.StoreChannel

func (SqlPreferenceStore) DeleteUnusedFeatures

func (s SqlPreferenceStore) DeleteUnusedFeatures()

func (SqlPreferenceStore) Get

func (s SqlPreferenceStore) Get(userId string, category string, name string) store.StoreChannel

func (SqlPreferenceStore) GetAll

func (s SqlPreferenceStore) GetAll(userId string) store.StoreChannel

func (SqlPreferenceStore) GetCategory

func (s SqlPreferenceStore) GetCategory(userId string, category string) store.StoreChannel

func (SqlPreferenceStore) IsFeatureEnabled

func (s SqlPreferenceStore) IsFeatureEnabled(feature, userId string) store.StoreChannel

func (SqlPreferenceStore) PermanentDeleteByUser

func (s SqlPreferenceStore) PermanentDeleteByUser(userId string) store.StoreChannel

func (SqlPreferenceStore) Save

func (s SqlPreferenceStore) Save(preferences *model.Preferences) store.StoreChannel

type SqlSessionStore

type SqlSessionStore struct {
	SqlStore
}

func (SqlSessionStore) AnalyticsSessionCount

func (me SqlSessionStore) AnalyticsSessionCount() store.StoreChannel

func (SqlSessionStore) Cleanup

func (me SqlSessionStore) Cleanup(expiryTime int64, batchSize int64)

func (SqlSessionStore) CreateIndexesIfNotExists

func (me SqlSessionStore) CreateIndexesIfNotExists()

func (SqlSessionStore) Get

func (me SqlSessionStore) Get(sessionIdOrToken string) store.StoreChannel

func (SqlSessionStore) GetSessions

func (me SqlSessionStore) GetSessions(userId string) store.StoreChannel

func (SqlSessionStore) GetSessionsWithActiveDeviceIds

func (me SqlSessionStore) GetSessionsWithActiveDeviceIds(userId string) store.StoreChannel

func (SqlSessionStore) PermanentDeleteSessionsByUser

func (me SqlSessionStore) PermanentDeleteSessionsByUser(userId string) store.StoreChannel

func (SqlSessionStore) Remove

func (me SqlSessionStore) Remove(sessionIdOrToken string) store.StoreChannel

func (SqlSessionStore) RemoveAllSessions

func (me SqlSessionStore) RemoveAllSessions() store.StoreChannel

func (SqlSessionStore) Save

func (me SqlSessionStore) Save(session *model.Session) store.StoreChannel

func (SqlSessionStore) UpdateDeviceId

func (me SqlSessionStore) UpdateDeviceId(id string, deviceId string, expiresAt int64) store.StoreChannel

func (SqlSessionStore) UpdateLastActivityAt

func (me SqlSessionStore) UpdateLastActivityAt(sessionId string, time int64) store.StoreChannel

func (SqlSessionStore) UpdateRoles

func (me SqlSessionStore) UpdateRoles(userId, roles string) store.StoreChannel

type SqlStatusStore

type SqlStatusStore struct {
	SqlStore
}

func (SqlStatusStore) CreateIndexesIfNotExists

func (s SqlStatusStore) CreateIndexesIfNotExists()

func (SqlStatusStore) Get

func (s SqlStatusStore) Get(userId string) store.StoreChannel

func (SqlStatusStore) GetAllFromTeam

func (s SqlStatusStore) GetAllFromTeam(teamId string) store.StoreChannel

func (SqlStatusStore) GetByIds

func (s SqlStatusStore) GetByIds(userIds []string) store.StoreChannel

func (SqlStatusStore) GetOnline

func (s SqlStatusStore) GetOnline() store.StoreChannel

func (SqlStatusStore) GetOnlineAway

func (s SqlStatusStore) GetOnlineAway() store.StoreChannel

func (SqlStatusStore) GetTotalActiveUsersCount

func (s SqlStatusStore) GetTotalActiveUsersCount() store.StoreChannel

func (SqlStatusStore) ResetAll

func (s SqlStatusStore) ResetAll() store.StoreChannel

func (SqlStatusStore) SaveOrUpdate

func (s SqlStatusStore) SaveOrUpdate(status *model.Status) store.StoreChannel

func (SqlStatusStore) UpdateLastActivityAt

func (s SqlStatusStore) UpdateLastActivityAt(userId string, lastActivityAt int64) store.StoreChannel

type SqlStore

type SqlStore interface {
	DriverName() string
	GetCurrentSchemaVersion() string
	GetMaster() *gorp.DbMap
	GetSearchReplica() *gorp.DbMap
	GetReplica() *gorp.DbMap
	TotalMasterDbConnections() int
	TotalReadDbConnections() int
	TotalSearchDbConnections() int
	MarkSystemRanUnitTests()
	DoesTableExist(tablename string) bool
	DoesColumnExist(tableName string, columName string) bool
	DoesTriggerExist(triggerName string) bool
	CreateColumnIfNotExists(tableName string, columnName string, mySqlColType string, postgresColType string, defaultValue string) bool
	CreateColumnIfNotExistsNoDefault(tableName string, columnName string, mySqlColType string, postgresColType string) bool
	RemoveColumnIfExists(tableName string, columnName string) bool
	RemoveTableIfExists(tableName string) bool
	RenameColumnIfExists(tableName string, oldColumnName string, newColumnName string, colType string) bool
	GetMaxLengthOfColumnIfExists(tableName string, columnName string) string
	AlterColumnTypeIfExists(tableName string, columnName string, mySqlColType string, postgresColType string) bool
	CreateUniqueIndexIfNotExists(indexName string, tableName string, columnName string) bool
	CreateIndexIfNotExists(indexName string, tableName string, columnName string) bool
	CreateCompositeIndexIfNotExists(indexName string, tableName string, columnNames []string) bool
	CreateFullTextIndexIfNotExists(indexName string, tableName string, columnName string) bool
	RemoveIndexIfExists(indexName string, tableName string) bool
	GetAllConns() []*gorp.DbMap
	Close()
	LockToMaster()
	UnlockFromMaster()
	Team() store.TeamStore
	Channel() store.ChannelStore
	Post() store.PostStore
	User() store.UserStore
	Audit() store.AuditStore
	ClusterDiscovery() store.ClusterDiscoveryStore
	Compliance() store.ComplianceStore
	Session() store.SessionStore
	OAuth() store.OAuthStore
	System() store.SystemStore
	Webhook() store.WebhookStore
	Command() store.CommandStore
	CommandWebhook() store.CommandWebhookStore
	Preference() store.PreferenceStore
	License() store.LicenseStore
	Token() store.TokenStore
	Emoji() store.EmojiStore
	Status() store.StatusStore
	FileInfo() store.FileInfoStore
	Reaction() store.ReactionStore
	Job() store.JobStore
	Plugin() store.PluginStore
	UserAccessToken() store.UserAccessTokenStore
	Role() store.RoleStore
	Scheme() store.SchemeStore
	TermsOfService() store.TermsOfServiceStore
}

type SqlSupplier

type SqlSupplier struct {
	// contains filtered or unexported fields
}

func NewSqlSupplier

func NewSqlSupplier(settings model.SqlSettings, metrics einterfaces.MetricsInterface) *SqlSupplier

func (*SqlSupplier) AlterColumnTypeIfExists

func (ss *SqlSupplier) AlterColumnTypeIfExists(tableName string, columnName string, mySqlColType string, postgresColType string) bool

func (*SqlSupplier) Audit

func (ss *SqlSupplier) Audit() store.AuditStore

func (*SqlSupplier) Channel

func (ss *SqlSupplier) Channel() store.ChannelStore

func (*SqlSupplier) ChannelMemberHistory

func (ss *SqlSupplier) ChannelMemberHistory() store.ChannelMemberHistoryStore

func (*SqlSupplier) Close

func (ss *SqlSupplier) Close()

func (*SqlSupplier) ClusterDiscovery

func (ss *SqlSupplier) ClusterDiscovery() store.ClusterDiscoveryStore

func (*SqlSupplier) Command

func (ss *SqlSupplier) Command() store.CommandStore

func (*SqlSupplier) CommandWebhook

func (ss *SqlSupplier) CommandWebhook() store.CommandWebhookStore

func (*SqlSupplier) Compliance

func (ss *SqlSupplier) Compliance() store.ComplianceStore

func (*SqlSupplier) CreateColumnIfNotExists

func (ss *SqlSupplier) CreateColumnIfNotExists(tableName string, columnName string, mySqlColType string, postgresColType string, defaultValue string) bool

func (*SqlSupplier) CreateColumnIfNotExistsNoDefault

func (ss *SqlSupplier) CreateColumnIfNotExistsNoDefault(tableName string, columnName string, mySqlColType string, postgresColType string) bool

func (*SqlSupplier) CreateCompositeIndexIfNotExists

func (ss *SqlSupplier) CreateCompositeIndexIfNotExists(indexName string, tableName string, columnNames []string) bool

func (*SqlSupplier) CreateFullTextIndexIfNotExists

func (ss *SqlSupplier) CreateFullTextIndexIfNotExists(indexName string, tableName string, columnName string) bool

func (*SqlSupplier) CreateIndexIfNotExists

func (ss *SqlSupplier) CreateIndexIfNotExists(indexName string, tableName string, columnName string) bool

func (*SqlSupplier) CreateUniqueIndexIfNotExists

func (ss *SqlSupplier) CreateUniqueIndexIfNotExists(indexName string, tableName string, columnName string) bool

func (*SqlSupplier) DoesColumnExist

func (ss *SqlSupplier) DoesColumnExist(tableName string, columnName string) bool

func (*SqlSupplier) DoesTableExist

func (ss *SqlSupplier) DoesTableExist(tableName string) bool

func (*SqlSupplier) DoesTriggerExist

func (ss *SqlSupplier) DoesTriggerExist(triggerName string) bool

func (*SqlSupplier) DriverName

func (ss *SqlSupplier) DriverName() string

func (*SqlSupplier) DropAllTables

func (ss *SqlSupplier) DropAllTables()

func (*SqlSupplier) Emoji

func (ss *SqlSupplier) Emoji() store.EmojiStore

func (*SqlSupplier) FileInfo

func (ss *SqlSupplier) FileInfo() store.FileInfoStore

func (*SqlSupplier) GetAllConns

func (ss *SqlSupplier) GetAllConns() []*gorp.DbMap

func (*SqlSupplier) GetCurrentSchemaVersion

func (ss *SqlSupplier) GetCurrentSchemaVersion() string

func (*SqlSupplier) GetMaster

func (ss *SqlSupplier) GetMaster() *gorp.DbMap

func (*SqlSupplier) GetMaxLengthOfColumnIfExists

func (ss *SqlSupplier) GetMaxLengthOfColumnIfExists(tableName string, columnName string) string

func (*SqlSupplier) GetReplica

func (ss *SqlSupplier) GetReplica() *gorp.DbMap

func (*SqlSupplier) GetSearchReplica

func (ss *SqlSupplier) GetSearchReplica() *gorp.DbMap

func (*SqlSupplier) Job

func (ss *SqlSupplier) Job() store.JobStore

func (*SqlSupplier) License

func (ss *SqlSupplier) License() store.LicenseStore

func (*SqlSupplier) LockToMaster

func (ss *SqlSupplier) LockToMaster()

func (*SqlSupplier) MarkSystemRanUnitTests

func (ss *SqlSupplier) MarkSystemRanUnitTests()

func (*SqlSupplier) Next

func (*SqlSupplier) OAuth

func (ss *SqlSupplier) OAuth() store.OAuthStore

func (*SqlSupplier) Plugin

func (ss *SqlSupplier) Plugin() store.PluginStore

func (*SqlSupplier) Post

func (ss *SqlSupplier) Post() store.PostStore

func (*SqlSupplier) Preference

func (ss *SqlSupplier) Preference() store.PreferenceStore

func (*SqlSupplier) Reaction

func (ss *SqlSupplier) Reaction() store.ReactionStore

func (*SqlSupplier) ReactionDelete

func (s *SqlSupplier) ReactionDelete(ctx context.Context, reaction *model.Reaction, hints ...store.LayeredStoreHint) *store.LayeredStoreSupplierResult

func (*SqlSupplier) ReactionDeleteAllWithEmojiName

func (s *SqlSupplier) ReactionDeleteAllWithEmojiName(ctx context.Context, emojiName string, hints ...store.LayeredStoreHint) *store.LayeredStoreSupplierResult

func (*SqlSupplier) ReactionGetForPost

func (s *SqlSupplier) ReactionGetForPost(ctx context.Context, postId string, hints ...store.LayeredStoreHint) *store.LayeredStoreSupplierResult

func (*SqlSupplier) ReactionPermanentDeleteBatch

func (s *SqlSupplier) ReactionPermanentDeleteBatch(ctx context.Context, endTime int64, limit int64, hints ...store.LayeredStoreHint) *store.LayeredStoreSupplierResult

func (*SqlSupplier) ReactionSave

func (s *SqlSupplier) ReactionSave(ctx context.Context, reaction *model.Reaction, hints ...store.LayeredStoreHint) *store.LayeredStoreSupplierResult

func (*SqlSupplier) RemoveColumnIfExists

func (ss *SqlSupplier) RemoveColumnIfExists(tableName string, columnName string) bool

func (*SqlSupplier) RemoveIndexIfExists

func (ss *SqlSupplier) RemoveIndexIfExists(indexName string, tableName string) bool

func (*SqlSupplier) RemoveTableIfExists

func (ss *SqlSupplier) RemoveTableIfExists(tableName string) bool

func (*SqlSupplier) RenameColumnIfExists

func (ss *SqlSupplier) RenameColumnIfExists(tableName string, oldColumnName string, newColumnName string, colType string) bool

func (*SqlSupplier) Role

func (ss *SqlSupplier) Role() store.RoleStore

func (*SqlSupplier) RoleDelete

func (*SqlSupplier) RoleGet

func (*SqlSupplier) RoleGetByName

func (*SqlSupplier) RoleGetByNames

func (s *SqlSupplier) RoleGetByNames(ctx context.Context, names []string, hints ...store.LayeredStoreHint) *store.LayeredStoreSupplierResult

func (*SqlSupplier) RolePermanentDeleteAll

func (s *SqlSupplier) RolePermanentDeleteAll(ctx context.Context, hints ...store.LayeredStoreHint) *store.LayeredStoreSupplierResult

func (*SqlSupplier) RoleSave

func (*SqlSupplier) Scheme

func (ss *SqlSupplier) Scheme() store.SchemeStore

func (*SqlSupplier) SchemeDelete

func (s *SqlSupplier) SchemeDelete(ctx context.Context, schemeId string, hints ...store.LayeredStoreHint) *store.LayeredStoreSupplierResult

func (*SqlSupplier) SchemeGet

func (*SqlSupplier) SchemeGetAllPage

func (s *SqlSupplier) SchemeGetAllPage(ctx context.Context, scope string, offset int, limit int, hints ...store.LayeredStoreHint) *store.LayeredStoreSupplierResult

func (*SqlSupplier) SchemeGetByName

func (s *SqlSupplier) SchemeGetByName(ctx context.Context, schemeName string, hints ...store.LayeredStoreHint) *store.LayeredStoreSupplierResult

func (*SqlSupplier) SchemePermanentDeleteAll

func (s *SqlSupplier) SchemePermanentDeleteAll(ctx context.Context, hints ...store.LayeredStoreHint) *store.LayeredStoreSupplierResult

func (*SqlSupplier) SchemeSave

func (*SqlSupplier) Session

func (ss *SqlSupplier) Session() store.SessionStore

func (*SqlSupplier) SetChainNext

func (s *SqlSupplier) SetChainNext(next store.LayeredStoreSupplier)

func (*SqlSupplier) Status

func (ss *SqlSupplier) Status() store.StatusStore

func (*SqlSupplier) System

func (ss *SqlSupplier) System() store.SystemStore

func (*SqlSupplier) Team

func (ss *SqlSupplier) Team() store.TeamStore

func (*SqlSupplier) TermsOfService

func (ss *SqlSupplier) TermsOfService() store.TermsOfServiceStore

func (*SqlSupplier) Token

func (ss *SqlSupplier) Token() store.TokenStore

func (*SqlSupplier) TotalMasterDbConnections

func (ss *SqlSupplier) TotalMasterDbConnections() int

func (*SqlSupplier) TotalReadDbConnections

func (ss *SqlSupplier) TotalReadDbConnections() int

func (*SqlSupplier) TotalSearchDbConnections

func (ss *SqlSupplier) TotalSearchDbConnections() int

func (*SqlSupplier) UnlockFromMaster

func (ss *SqlSupplier) UnlockFromMaster()

func (*SqlSupplier) User

func (ss *SqlSupplier) User() store.UserStore

func (*SqlSupplier) UserAccessToken

func (ss *SqlSupplier) UserAccessToken() store.UserAccessTokenStore

func (*SqlSupplier) Webhook

func (ss *SqlSupplier) Webhook() store.WebhookStore

type SqlSupplierOldStores

type SqlSupplierOldStores struct {
	TermsOfService store.TermsOfServiceStore
	// contains filtered or unexported fields
}

type SqlSystemStore

type SqlSystemStore struct {
	SqlStore
}

func (SqlSystemStore) CreateIndexesIfNotExists

func (s SqlSystemStore) CreateIndexesIfNotExists()

func (SqlSystemStore) Get

func (SqlSystemStore) GetByName

func (s SqlSystemStore) GetByName(name string) store.StoreChannel

func (SqlSystemStore) PermanentDeleteByName

func (s SqlSystemStore) PermanentDeleteByName(name string) store.StoreChannel

func (SqlSystemStore) Save

func (s SqlSystemStore) Save(system *model.System) store.StoreChannel

func (SqlSystemStore) SaveOrUpdate

func (s SqlSystemStore) SaveOrUpdate(system *model.System) store.StoreChannel

func (SqlSystemStore) Update

func (s SqlSystemStore) Update(system *model.System) store.StoreChannel

type SqlTeamStore

type SqlTeamStore struct {
	SqlStore
}

func (SqlTeamStore) AnalyticsGetTeamCountForScheme

func (s SqlTeamStore) AnalyticsGetTeamCountForScheme(schemeId string) store.StoreChannel

func (SqlTeamStore) AnalyticsTeamCount

func (s SqlTeamStore) AnalyticsTeamCount() store.StoreChannel

func (SqlTeamStore) ClearAllCustomRoleAssignments

func (s SqlTeamStore) ClearAllCustomRoleAssignments() store.StoreChannel

func (SqlTeamStore) CreateIndexesIfNotExists

func (s SqlTeamStore) CreateIndexesIfNotExists()

func (SqlTeamStore) Get

func (SqlTeamStore) GetActiveMemberCount

func (s SqlTeamStore) GetActiveMemberCount(teamId string) store.StoreChannel

func (SqlTeamStore) GetAll

func (s SqlTeamStore) GetAll() store.StoreChannel

func (SqlTeamStore) GetAllForExportAfter

func (s SqlTeamStore) GetAllForExportAfter(limit int, afterId string) store.StoreChannel

func (SqlTeamStore) GetAllPage

func (s SqlTeamStore) GetAllPage(offset int, limit int) store.StoreChannel

func (SqlTeamStore) GetAllTeamListing

func (s SqlTeamStore) GetAllTeamListing() store.StoreChannel

func (SqlTeamStore) GetAllTeamPageListing

func (s SqlTeamStore) GetAllTeamPageListing(offset int, limit int) store.StoreChannel

func (SqlTeamStore) GetByInviteId

func (s SqlTeamStore) GetByInviteId(inviteId string) store.StoreChannel

func (SqlTeamStore) GetByName

func (s SqlTeamStore) GetByName(name string) store.StoreChannel

func (SqlTeamStore) GetChannelUnreadsForAllTeams

func (s SqlTeamStore) GetChannelUnreadsForAllTeams(excludeTeamId, userId string) store.StoreChannel

func (SqlTeamStore) GetChannelUnreadsForTeam

func (s SqlTeamStore) GetChannelUnreadsForTeam(teamId, userId string) store.StoreChannel

func (SqlTeamStore) GetMember

func (s SqlTeamStore) GetMember(teamId string, userId string) store.StoreChannel

func (SqlTeamStore) GetMembers

func (s SqlTeamStore) GetMembers(teamId string, offset int, limit int) store.StoreChannel

func (SqlTeamStore) GetMembersByIds

func (s SqlTeamStore) GetMembersByIds(teamId string, userIds []string) store.StoreChannel

func (SqlTeamStore) GetTeamMembersForExport

func (s SqlTeamStore) GetTeamMembersForExport(userId string) store.StoreChannel

func (SqlTeamStore) GetTeamsByScheme

func (s SqlTeamStore) GetTeamsByScheme(schemeId string, offset int, limit int) store.StoreChannel

func (SqlTeamStore) GetTeamsByUserId

func (s SqlTeamStore) GetTeamsByUserId(userId string) store.StoreChannel

func (SqlTeamStore) GetTeamsForUser

func (s SqlTeamStore) GetTeamsForUser(userId string) store.StoreChannel

func (SqlTeamStore) GetTotalMemberCount

func (s SqlTeamStore) GetTotalMemberCount(teamId string) store.StoreChannel

func (SqlTeamStore) MigrateTeamMembers

func (s SqlTeamStore) MigrateTeamMembers(fromTeamId string, fromUserId string) store.StoreChannel

This function does the Advanced Permissions Phase 2 migration for TeamMember objects. It performs the migration in batches as a single transaction per batch to ensure consistency but to also minimise execution time to avoid causing unnecessary table locks. **THIS FUNCTION SHOULD NOT BE USED FOR ANY OTHER PURPOSE.** Executing this function *after* the new Schemes functionality has been used on an installation will have unintended consequences.

func (SqlTeamStore) PermanentDelete

func (s SqlTeamStore) PermanentDelete(teamId string) store.StoreChannel

func (SqlTeamStore) RemoveAllMembersByTeam

func (s SqlTeamStore) RemoveAllMembersByTeam(teamId string) store.StoreChannel

func (SqlTeamStore) RemoveAllMembersByUser

func (s SqlTeamStore) RemoveAllMembersByUser(userId string) store.StoreChannel

func (SqlTeamStore) RemoveMember

func (s SqlTeamStore) RemoveMember(teamId string, userId string) store.StoreChannel

func (SqlTeamStore) ResetAllTeamSchemes

func (s SqlTeamStore) ResetAllTeamSchemes() store.StoreChannel

func (SqlTeamStore) Save

func (s SqlTeamStore) Save(team *model.Team) store.StoreChannel

func (SqlTeamStore) SaveMember

func (s SqlTeamStore) SaveMember(member *model.TeamMember, maxUsersPerTeam int) store.StoreChannel

func (SqlTeamStore) SearchAll

func (s SqlTeamStore) SearchAll(term string) store.StoreChannel

func (SqlTeamStore) SearchByName

func (s SqlTeamStore) SearchByName(name string) store.StoreChannel

func (SqlTeamStore) SearchOpen

func (s SqlTeamStore) SearchOpen(term string) store.StoreChannel

func (SqlTeamStore) Update

func (s SqlTeamStore) Update(team *model.Team) store.StoreChannel

func (SqlTeamStore) UpdateDisplayName

func (s SqlTeamStore) UpdateDisplayName(name string, teamId string) store.StoreChannel

func (SqlTeamStore) UpdateLastTeamIconUpdate

func (us SqlTeamStore) UpdateLastTeamIconUpdate(teamId string, curTime int64) store.StoreChannel

func (SqlTeamStore) UpdateMember

func (s SqlTeamStore) UpdateMember(member *model.TeamMember) store.StoreChannel

type SqlTermsOfServiceStore

type SqlTermsOfServiceStore struct {
	SqlStore
	// contains filtered or unexported fields
}

func (SqlTermsOfServiceStore) CreateIndexesIfNotExists

func (s SqlTermsOfServiceStore) CreateIndexesIfNotExists()

func (SqlTermsOfServiceStore) Get

func (s SqlTermsOfServiceStore) Get(id string, allowFromCache bool) store.StoreChannel

func (SqlTermsOfServiceStore) GetLatest

func (s SqlTermsOfServiceStore) GetLatest(allowFromCache bool) store.StoreChannel

func (SqlTermsOfServiceStore) Save

type SqlTokenStore

type SqlTokenStore struct {
	SqlStore
}

func (SqlTokenStore) Cleanup

func (s SqlTokenStore) Cleanup()

func (SqlTokenStore) CreateIndexesIfNotExists

func (s SqlTokenStore) CreateIndexesIfNotExists()

func (SqlTokenStore) Delete

func (s SqlTokenStore) Delete(token string) store.StoreChannel

func (SqlTokenStore) GetByToken

func (s SqlTokenStore) GetByToken(tokenString string) store.StoreChannel

func (SqlTokenStore) Save

func (s SqlTokenStore) Save(token *model.Token) store.StoreChannel

type SqlUserAccessTokenStore

type SqlUserAccessTokenStore struct {
	SqlStore
}

func (SqlUserAccessTokenStore) CreateIndexesIfNotExists

func (s SqlUserAccessTokenStore) CreateIndexesIfNotExists()

func (SqlUserAccessTokenStore) Delete

func (SqlUserAccessTokenStore) DeleteAllForUser

func (s SqlUserAccessTokenStore) DeleteAllForUser(userId string) store.StoreChannel

func (SqlUserAccessTokenStore) Get

func (SqlUserAccessTokenStore) GetAll

func (s SqlUserAccessTokenStore) GetAll(offset, limit int) store.StoreChannel

func (SqlUserAccessTokenStore) GetByToken

func (s SqlUserAccessTokenStore) GetByToken(tokenString string) store.StoreChannel

func (SqlUserAccessTokenStore) GetByUser

func (s SqlUserAccessTokenStore) GetByUser(userId string, offset, limit int) store.StoreChannel

func (SqlUserAccessTokenStore) Save

func (SqlUserAccessTokenStore) Search

func (SqlUserAccessTokenStore) UpdateTokenDisable

func (s SqlUserAccessTokenStore) UpdateTokenDisable(tokenId string) store.StoreChannel

func (SqlUserAccessTokenStore) UpdateTokenEnable

func (s SqlUserAccessTokenStore) UpdateTokenEnable(tokenId string) store.StoreChannel

type SqlUserStore

type SqlUserStore struct {
	SqlStore
	// contains filtered or unexported fields
}

func (SqlUserStore) AnalyticsActiveCount

func (us SqlUserStore) AnalyticsActiveCount(timePeriod int64) store.StoreChannel

func (SqlUserStore) AnalyticsGetInactiveUsersCount

func (us SqlUserStore) AnalyticsGetInactiveUsersCount() store.StoreChannel

func (SqlUserStore) AnalyticsGetSystemAdminCount

func (us SqlUserStore) AnalyticsGetSystemAdminCount() store.StoreChannel

func (SqlUserStore) AnalyticsUniqueUserCount

func (us SqlUserStore) AnalyticsUniqueUserCount(teamId string) store.StoreChannel

func (SqlUserStore) ClearAllCustomRoleAssignments

func (us SqlUserStore) ClearAllCustomRoleAssignments() store.StoreChannel

func (SqlUserStore) ClearCaches

func (us SqlUserStore) ClearCaches()

func (SqlUserStore) CreateIndexesIfNotExists

func (us SqlUserStore) CreateIndexesIfNotExists()

func (SqlUserStore) Get

func (SqlUserStore) GetAll

func (us SqlUserStore) GetAll() store.StoreChannel

func (SqlUserStore) GetAllAfter

func (us SqlUserStore) GetAllAfter(limit int, afterId string) store.StoreChannel

func (SqlUserStore) GetAllProfiles

func (us SqlUserStore) GetAllProfiles(offset int, limit int) store.StoreChannel

func (SqlUserStore) GetAllProfilesInChannel

func (us SqlUserStore) GetAllProfilesInChannel(channelId string, allowFromCache bool) store.StoreChannel

func (SqlUserStore) GetAllUsingAuthService

func (us SqlUserStore) GetAllUsingAuthService(authService string) store.StoreChannel

func (SqlUserStore) GetAnyUnreadPostCountForChannel

func (us SqlUserStore) GetAnyUnreadPostCountForChannel(userId string, channelId string) store.StoreChannel

func (SqlUserStore) GetByAuth

func (us SqlUserStore) GetByAuth(authData *string, authService string) store.StoreChannel

func (SqlUserStore) GetByEmail

func (us SqlUserStore) GetByEmail(email string) store.StoreChannel

func (SqlUserStore) GetByUsername

func (us SqlUserStore) GetByUsername(username string) store.StoreChannel

func (SqlUserStore) GetEtagForAllProfiles

func (s SqlUserStore) GetEtagForAllProfiles() store.StoreChannel

func (SqlUserStore) GetEtagForProfiles

func (s SqlUserStore) GetEtagForProfiles(teamId string) store.StoreChannel

func (SqlUserStore) GetEtagForProfilesNotInTeam

func (us SqlUserStore) GetEtagForProfilesNotInTeam(teamId string) store.StoreChannel

func (SqlUserStore) GetForLogin

func (us SqlUserStore) GetForLogin(loginId string, allowSignInWithUsername, allowSignInWithEmail bool) store.StoreChannel

func (SqlUserStore) GetNewUsersForTeam

func (us SqlUserStore) GetNewUsersForTeam(teamId string, offset, limit int) store.StoreChannel

func (SqlUserStore) GetProfileByIds

func (us SqlUserStore) GetProfileByIds(userIds []string, allowFromCache bool) store.StoreChannel

func (SqlUserStore) GetProfiles

func (us SqlUserStore) GetProfiles(teamId string, offset int, limit int) store.StoreChannel

func (SqlUserStore) GetProfilesByUsernames

func (us SqlUserStore) GetProfilesByUsernames(usernames []string, teamId string) store.StoreChannel

func (SqlUserStore) GetProfilesInChannel

func (us SqlUserStore) GetProfilesInChannel(channelId string, offset int, limit int) store.StoreChannel

func (SqlUserStore) GetProfilesInChannelByStatus

func (us SqlUserStore) GetProfilesInChannelByStatus(channelId string, offset int, limit int) store.StoreChannel

func (SqlUserStore) GetProfilesNotInChannel

func (us SqlUserStore) GetProfilesNotInChannel(teamId string, channelId string, offset int, limit int) store.StoreChannel

func (SqlUserStore) GetProfilesNotInTeam

func (us SqlUserStore) GetProfilesNotInTeam(teamId string, offset int, limit int) store.StoreChannel

func (SqlUserStore) GetProfilesWithoutTeam

func (us SqlUserStore) GetProfilesWithoutTeam(offset int, limit int) store.StoreChannel

func (SqlUserStore) GetRecentlyActiveUsersForTeam

func (us SqlUserStore) GetRecentlyActiveUsersForTeam(teamId string, offset, limit int) store.StoreChannel

func (SqlUserStore) GetSystemAdminProfiles

func (us SqlUserStore) GetSystemAdminProfiles() store.StoreChannel

func (SqlUserStore) GetTotalUsersCount

func (us SqlUserStore) GetTotalUsersCount() store.StoreChannel

func (SqlUserStore) GetUnreadCount

func (us SqlUserStore) GetUnreadCount(userId string) store.StoreChannel

func (SqlUserStore) GetUnreadCountForChannel

func (us SqlUserStore) GetUnreadCountForChannel(userId string, channelId string) store.StoreChannel

func (SqlUserStore) InferSystemInstallDate

func (us SqlUserStore) InferSystemInstallDate() store.StoreChannel

func (SqlUserStore) InvalidatProfileCacheForUser

func (us SqlUserStore) InvalidatProfileCacheForUser(userId string)

func (SqlUserStore) InvalidateProfilesInChannelCache

func (us SqlUserStore) InvalidateProfilesInChannelCache(channelId string)

func (SqlUserStore) InvalidateProfilesInChannelCacheByUser

func (us SqlUserStore) InvalidateProfilesInChannelCacheByUser(userId string)

func (SqlUserStore) PermanentDelete

func (us SqlUserStore) PermanentDelete(userId string) store.StoreChannel

func (SqlUserStore) Save

func (us SqlUserStore) Save(user *model.User) store.StoreChannel

func (SqlUserStore) Search

func (us SqlUserStore) Search(teamId string, term string, options map[string]bool) store.StoreChannel

func (SqlUserStore) SearchInChannel

func (us SqlUserStore) SearchInChannel(channelId string, term string, options map[string]bool) store.StoreChannel

func (SqlUserStore) SearchNotInChannel

func (us SqlUserStore) SearchNotInChannel(teamId string, channelId string, term string, options map[string]bool) store.StoreChannel

func (SqlUserStore) SearchNotInTeam

func (us SqlUserStore) SearchNotInTeam(notInTeamId string, term string, options map[string]bool) store.StoreChannel

func (SqlUserStore) SearchWithoutTeam

func (us SqlUserStore) SearchWithoutTeam(term string, options map[string]bool) store.StoreChannel

func (SqlUserStore) Update

func (us SqlUserStore) Update(user *model.User, trustedUpdateData bool) store.StoreChannel

func (SqlUserStore) UpdateAuthData

func (us SqlUserStore) UpdateAuthData(userId string, service string, authData *string, email string, resetMfa bool) store.StoreChannel

func (SqlUserStore) UpdateFailedPasswordAttempts

func (us SqlUserStore) UpdateFailedPasswordAttempts(userId string, attempts int) store.StoreChannel

func (SqlUserStore) UpdateLastPictureUpdate

func (us SqlUserStore) UpdateLastPictureUpdate(userId string) store.StoreChannel

func (SqlUserStore) UpdateMfaActive

func (us SqlUserStore) UpdateMfaActive(userId string, active bool) store.StoreChannel

func (SqlUserStore) UpdateMfaSecret

func (us SqlUserStore) UpdateMfaSecret(userId, secret string) store.StoreChannel

func (SqlUserStore) UpdatePassword

func (us SqlUserStore) UpdatePassword(userId, hashedPassword string) store.StoreChannel

func (SqlUserStore) UpdateUpdateAt

func (us SqlUserStore) UpdateUpdateAt(userId string) store.StoreChannel

func (SqlUserStore) VerifyEmail

func (us SqlUserStore) VerifyEmail(userId string) store.StoreChannel

type SqlWebhookStore

type SqlWebhookStore struct {
	SqlStore
	// contains filtered or unexported fields
}

func (SqlWebhookStore) AnalyticsIncomingCount

func (s SqlWebhookStore) AnalyticsIncomingCount(teamId string) store.StoreChannel

func (SqlWebhookStore) AnalyticsOutgoingCount

func (s SqlWebhookStore) AnalyticsOutgoingCount(teamId string) store.StoreChannel

func (SqlWebhookStore) ClearCaches

func (s SqlWebhookStore) ClearCaches()

func (SqlWebhookStore) CreateIndexesIfNotExists

func (s SqlWebhookStore) CreateIndexesIfNotExists()

func (SqlWebhookStore) DeleteIncoming

func (s SqlWebhookStore) DeleteIncoming(webhookId string, time int64) store.StoreChannel

func (SqlWebhookStore) DeleteOutgoing

func (s SqlWebhookStore) DeleteOutgoing(webhookId string, time int64) store.StoreChannel

func (SqlWebhookStore) GetIncoming

func (s SqlWebhookStore) GetIncoming(id string, allowFromCache bool) store.StoreChannel

func (SqlWebhookStore) GetIncomingByChannel

func (s SqlWebhookStore) GetIncomingByChannel(channelId string) store.StoreChannel

func (SqlWebhookStore) GetIncomingByTeam

func (s SqlWebhookStore) GetIncomingByTeam(teamId string, offset, limit int) store.StoreChannel

func (SqlWebhookStore) GetIncomingList

func (s SqlWebhookStore) GetIncomingList(offset, limit int) store.StoreChannel

func (SqlWebhookStore) GetOutgoing

func (s SqlWebhookStore) GetOutgoing(id string) store.StoreChannel

func (SqlWebhookStore) GetOutgoingByChannel

func (s SqlWebhookStore) GetOutgoingByChannel(channelId string, offset, limit int) store.StoreChannel

func (SqlWebhookStore) GetOutgoingByTeam

func (s SqlWebhookStore) GetOutgoingByTeam(teamId string, offset, limit int) store.StoreChannel

func (SqlWebhookStore) GetOutgoingList

func (s SqlWebhookStore) GetOutgoingList(offset, limit int) store.StoreChannel

func (SqlWebhookStore) InvalidateWebhookCache

func (s SqlWebhookStore) InvalidateWebhookCache(webhookId string)

func (SqlWebhookStore) PermanentDeleteIncomingByChannel

func (s SqlWebhookStore) PermanentDeleteIncomingByChannel(channelId string) store.StoreChannel

func (SqlWebhookStore) PermanentDeleteIncomingByUser

func (s SqlWebhookStore) PermanentDeleteIncomingByUser(userId string) store.StoreChannel

func (SqlWebhookStore) PermanentDeleteOutgoingByChannel

func (s SqlWebhookStore) PermanentDeleteOutgoingByChannel(channelId string) store.StoreChannel

func (SqlWebhookStore) PermanentDeleteOutgoingByUser

func (s SqlWebhookStore) PermanentDeleteOutgoingByUser(userId string) store.StoreChannel

func (SqlWebhookStore) SaveIncoming

func (s SqlWebhookStore) SaveIncoming(webhook *model.IncomingWebhook) store.StoreChannel

func (SqlWebhookStore) SaveOutgoing

func (s SqlWebhookStore) SaveOutgoing(webhook *model.OutgoingWebhook) store.StoreChannel

func (SqlWebhookStore) UpdateIncoming

func (s SqlWebhookStore) UpdateIncoming(hook *model.IncomingWebhook) store.StoreChannel

func (SqlWebhookStore) UpdateOutgoing

func (s SqlWebhookStore) UpdateOutgoing(hook *model.OutgoingWebhook) store.StoreChannel

type UserWithLastActivityAt

type UserWithLastActivityAt struct {
	model.User
	LastActivityAt int64
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL