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

Method invalRoleChannels

db/database.go:1944–1949  ·  view source on GitHub ↗

invalRoleChannels invalidates a role's computed channels for the specified collections

(ctx context.Context, rolename string, collections base.ScopeAndCollectionNames, invalSeq uint64)

Source from the content-addressed store, hash-verified

1942
1943// invalRoleChannels invalidates a role's computed channels for the specified collections
1944func (dbCtx *DatabaseContext) invalRoleChannels(ctx context.Context, rolename string, collections base.ScopeAndCollectionNames, invalSeq uint64) {
1945 authr := dbCtx.Authenticator(ctx)
1946 if err := authr.InvalidateChannels(rolename, false, collections, invalSeq); err != nil {
1947 base.WarnfCtx(ctx, "Error invalidating channels for role %s: %v", base.UD(rolename), err)
1948 }
1949}
1950
1951// invalUserRoles invalidates a user's computed roles
1952func (dbCtx *DatabaseContext) invalUserRoles(ctx context.Context, username string, invalSeq uint64) {

Callers 1

Calls 4

AuthenticatorMethod · 0.95
WarnfCtxFunction · 0.92
UDFunction · 0.92
InvalidateChannelsMethod · 0.80

Tested by

no test coverage detected