MCPcopy Create free account
hub / github.com/couchbase/sync_gateway / GetWithCV

Method GetWithCV

db/revision_cache_interface.go:39–39  ·  view source on GitHub ↗

GetWithCV returns the given revision by CV, and stores if not already cached. When includeDelta=true, the returned DocumentRevision will include delta - requires additional locking during retrieval. When loadBackup=true, will load from backup revisions if requested version is not active document

(ctx context.Context, docID string, cv *Version, collectionID uint32, includeDelta bool, loadBackup bool)

Source from the content-addressed store, hash-verified

37 // When includeDelta=true, the returned DocumentRevision will include delta - requires additional locking during retrieval.
38 // When loadBackup=true, will load from backup revisions if requested version is not active document
39 GetWithCV(ctx context.Context, docID string, cv *Version, collectionID uint32, includeDelta bool, loadBackup bool) (DocumentRevision, error)
40
41 // GetActive returns the current revision for the given doc ID, and stores if not already cached.
42 GetActive(ctx context.Context, docID string, collectionID uint32) (docRev DocumentRevision, err error)

Implementers 4

collectionRevisionCachedb/revision_cache_interface.go
BypassRevisionCachedb/revision_cache_bypass.go
ShardedLRURevisionCachedb/revision_cache_lru.go
LRURevisionCachedb/revision_cache_lru.go

Calls

no outgoing calls