Implement plugin KV store in memory (#26244)

Этот коммит содержится в:
Ben Schumacher
2024-03-01 12:12:52 +01:00
коммит произвёл GitHub
родитель f9861b8666
Коммит 02379b17ca
5 изменённых файлов: 756 добавлений и 92 удалений

Просмотреть файл

@@ -2,7 +2,6 @@ package common
import (
"errors"
"time"
"github.com/mattermost/mattermost/server/public/pluginapi"
)
@@ -11,9 +10,6 @@ var ErrNotFound = errors.New("not found")
type KVStore interface {
Set(key string, value interface{}, options ...pluginapi.KVSetOption) (bool, error)
SetWithExpiry(key string, value interface{}, ttl time.Duration) error
CompareAndSet(key string, oldValue, value interface{}) (bool, error)
CompareAndDelete(key string, oldValue interface{}) (bool, error)
Get(key string, o interface{}) error
Delete(key string) error
DeleteAll() error