util

package
v0.0.0-...-8feb696 Latest Latest
Warning

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

Go to latest
Published: Jul 18, 2019 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var DebugLoggingEnabled = GetEnvProp("DEBUG_LOGGING", "false") == "true" || GetEnvProp("DEBUG_LOGGING", "false") == "trace"

DebugLoggingEnabled is a flag that indicates whether or not to print debug logs.

View Source
var ProtocolMap = map[int]string{}/* 138 elements not displayed */

ProtocolMap is a map of protocol number to short description of the protocol.

View Source
var TraceLoggingEnabled = GetEnvProp("DEBUG_LOGGING", "false") == "trace"

TraceLoggingEnabled is a flag that indicates whether or not to print Ztrace logs.

Functions

func CurrentMemoryInfo

func CurrentMemoryInfo() runtime.MemStats

CurrentMemoryInfo returns information about the current state of memory usage

func FromJSON

func FromJSON(data *string, obj interface{}) error

FromJSON parses a JSON blob into the provided object.

func GetEnvProp

func GetEnvProp(name string, defaultValue string) string

GetEnvProp returns the value of the given environment variable, or the defaultValue if the environment variable has not been specified

func PrintMemUsage

func PrintMemUsage(prefix string)

PrintMemUsage prints information about memory usage to the system log

func Region

func Region() string

Region returns the name of the AWS region to configure the AWS SDK for

func ToJSON

func ToJSON(obj interface{}) *string

ToJSON converts the provided object into a JSON string.

Types

This section is empty.

Jump to

Keyboard shortcuts

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