Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetFromContext ¶
func GetFromContext(ctx context.Context, key ContextKey) (interface{}, error)
GetFromContext set tenant data in context
func SetInContext ¶
func SetInContext(ctx context.Context, key ContextKey, data interface{}) context.Context
SetInContext set info in context
Types ¶
type ContextKey ¶
type ContextKey string
ContextKey is the type that should be used
const ( AccountIDContextField ContextKey = "AccountId" UserIDContextField ContextKey = "UserId" ProjectIDContextField ContextKey = "ProjectId" )
Click to show internal directories.
Click to hide internal directories.