Documentation
¶
Index ¶
Constants ¶
View Source
const ( FieldNameModule = "module" FieldNameID = "id" )
Field name constants for the field names used on the logger entry.
Variables ¶
This section is empty.
Functions ¶
func ModuleLogEntry ¶
ModuleLogEntry creates a new logrus entry that includes the module name as a field.
func ModuleLogEntryWithID ¶
ModuleLogEntryWithID creates a new logrus entry that includes both the module name and a global id as keys. This is useful when multiple instances of the same module will be running as the id can then be used to keep track of each module instance.
func NextGlobalID ¶
func NextGlobalID() string
NextGlobalID returns the next value of a global id counter, shared between any caller to this method. The returned id is returned as a base36 string.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.