caller

package
v0.0.0-...-f941a7e Latest Latest
Warning

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

Go to latest
Published: Apr 28, 2026 License: Apache-2.0 Imports: 4 Imported by: 6

Documentation

Index

Constants

View Source
const (
	// TestID is used for test.
	TestID ID = "test"

	// TestComponent is used for test.
	TestComponent Component = "test"

	// client-go component
	CodecPDClient       Component = "CodecPdClient"
	RegionCache         Component = "RegionCache"
	StoreCache          Component = "StoreCache"
	Oracle              Component = "Oracle"
	Rawkv               Component = "Rawkv"
	KvStore             Component = "KvStore"
	InterceptedPDClient Component = "InterceptedPdClient"

	// TiDB component
	Pitr             Component = "Pitr"
	Ddl              Component = "Ddl"
	ImportInto       Component = "ImportInto"
	TikvHandler      Component = "TikvHandler"
	GcWorker         Component = "GcWorker"
	GcJob            Component = "GcJob"
	DistributedGcJob Component = "DistributedGcJob"
)

nolint: exported

Variables

This section is empty.

Functions

This section is empty.

Types

type Component

type Component string

Component refers to the components within the process.

func GetComponent

func GetComponent(upperLayer int) Component

GetComponent returns the package path of the calling function The argument upperLayer specifies the number of stack frames to ascend. NOTE: This function is time-consuming and please do not use it in high qps scenarios.

type ID

type ID string

ID can be understood as a binary file; it is a process.

func GetCallerID

func GetCallerID() ID

GetCallerID returns the name of the currently running process

Jump to

Keyboard shortcuts

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