meta

package
v0.1.3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 16, 2025 License: Apache-2.0 Imports: 3 Imported by: 1

Documentation

Index

Constants

View Source
const (
	KeyAppId   = "hd-app-id"
	KeyClient  = "hd-client"
	KeyRelease = "hd-release"
	KeyTsn     = "hd-tsn"      // tenant sn
	KeyTid     = "hd-tid"      // tenant id
	KeyUid     = "hd-uid"      // user id
	KeyRoleIds = "hd-role-ids" // role ids
	KeyCaller  = "dapr-caller-app-id"
)

Variables

This section is empty.

Functions

func AddMetaToContext added in v0.1.2

func AddMetaToContext(ctx context.Context, metas map[string]string) context.Context

func GetMetaFromContext added in v0.1.2

func GetMetaFromContext(ctx context.Context) map[string]string

Types

type MetaReader

type MetaReader interface {
	GetTid() int64
	GetUid() int64
	GetAppId() string
	GetTsn() string
}

func FromGrpcContext

func FromGrpcContext(ctx context.Context) MetaReader

func FromServiceContext

func FromServiceContext(ctx context.Context) MetaReader

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL