interface
DocumentLockStore
Atomically acquire, refresh, take over, and release authoring locks.
Properties
| Property | Type | Description |
|---|---|---|
FindDocumentLock | func(context.Context, | The FindDocumentLock value. |
AcquireDocumentLock | func(context.Context, | The AcquireDocumentLock value. |
ReleaseDocumentLock | func(context.Context, | The ReleaseDocumentLock value. |
How it works
Lock-enabled collections require this capability. Lock ownership includes both auth collection and actor ID.
Full signature
type DocumentLockStore interface {
FindDocumentLock(context.Context, schema.StableID, string, time.Time) (DocumentLock, error)
AcquireDocumentLock(context.Context, DocumentLock, time.Time, bool) (DocumentLock, bool, error)
ReleaseDocumentLock(context.Context, schema.StableID, string, schema.StableID, string) error
}