Documentation

Overview

    Package opname contains an extensible "operation name" construct for go applications. This allows a user to create a base operation, eg: "createWidget" and then sub-operations such as "pgSaveWidget" and they will get composed such as "createWidget.pgSaveWidget" in log lines. Each operation name adds a lightweight "layer" to the context.

    Index

    Constants

    This section is empty.

    Variables

    This section is empty.

    Functions

    func Get

    func Get(ctx context.Context) (string, bool)

      Get fetches the operation name from the given context.

      func With

      func With(ctx context.Context, name string) context.Context

        With stores the current operation name to the context, optionally prepending the existing operation name in the context if it exists.

        Types

        This section is empty.

        Source Files