Documentation
¶
Overview ¶
Contains common flyte context utils.
Index ¶
- func GetLogFields(ctx context.Context) map[string]interface{}
- func Value(ctx context.Context, key Key) string
- func Values(ctx context.Context, keys ...Key) map[string]string
- func WithAppName(ctx context.Context, appName string) context.Context
- func WithExecutionID(ctx context.Context, execID string) context.Context
- func WithJobID(ctx context.Context, jobID string) context.Context
- func WithNamespace(ctx context.Context, namespace string) context.Context
- func WithNodeID(ctx context.Context, nodeID string) context.Context
- func WithPhase(ctx context.Context, phase string) context.Context
- func WithProjectDomain(ctx context.Context, project, domain string) context.Context
- func WithTaskID(ctx context.Context, taskID string) context.Context
- func WithTaskType(ctx context.Context, taskType string) context.Context
- func WithWorkflowID(ctx context.Context, workflow string) context.Context
- type Key
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetLogFields ¶
Gets a map of all known logKeys set on the context. logKeys are special and should be used incase, context fields are to be added to the log lines.
func WithAppName ¶
Gets a new context with AppName set.
func WithExecutionID ¶
Gets a new context with ExecutionID set.
func WithJobID ¶
Gets a new context with JobId set. If the existing context already has a job id, the new context will have <old_jobID>/<new_jobID> set as the job id.
func WithNamespace ¶
Gets a new context with namespace set.
func WithNodeID ¶
Gets a new context with NodeID (nested) set.
func WithProjectDomain ¶
Get new context with Project and Domain values set
func WithTaskID ¶
Gets a new context with WorkflowName set.
func WithTaskType ¶
Gets a new context with TaskType set.
Types ¶
Click to show internal directories.
Click to hide internal directories.