Documentation ¶
Index ¶
- func DerefInt16(v *int16) int16
- func DerefInt64(v *int64) int64
- func DerefString(s *string) string
- func DerefTime(t *time.Time) int64
- func DerefUint32(v *uint32) uint32
- func DirsExist(dirs []string) error
- func DurationSec(durationSec interface{}) time.Duration
- func FileExists(path string) bool
- func GenerateNATSAuthJWT(creds string) ([]nats.Option, error)
- func GenerateNATSAuthNKey(nkeyPath string) ([]nats.Option, error)
- func GenerateTLSConfig(caCert, clientCert, clientKey string, skipVerify bool, mTLS tls.ClientAuthType) (*tls.Config, error)
- func Gunzip(data []byte) ([]byte, error)
- func MapInterfaceToString(input map[string]interface{}) map[string]string
- func RandomString(n int) string
- func WriteError(l *logrus.Entry, errorCh chan<- *records.ErrorRecord, err error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func DerefInt16 ¶ added in v1.0.0
func DerefInt64 ¶ added in v1.0.0
func DerefString ¶ added in v1.0.0
func DerefUint32 ¶ added in v1.0.0
func DurationSec ¶ added in v1.0.0
func FileExists ¶ added in v1.0.0
func GenerateNATSAuthJWT ¶ added in v1.11.0
GenerateNATSAuthJWT accepts either a path to a .creds file containing JWT credentials or the credentials directly in string format, and returns the correct nats connection authentication options
func GenerateNATSAuthNKey ¶ added in v1.11.0
GenerateNATSAuthNKey accepts either a path to a file containing a Nkey seed, or the Nkey seed directly in string format, and returns the correct nats connection authentication options
func GenerateTLSConfig ¶ added in v1.5.1
func Gunzip ¶
Gunzip decompresses a slice of bytes and returns a slice of decompressed bytes or an error.
func MapInterfaceToString ¶ added in v1.0.0
func RandomString ¶ added in v1.10.0
func WriteError ¶ added in v1.0.0
func WriteError(l *logrus.Entry, errorCh chan<- *records.ErrorRecord, err error)
WriteError is a wrapper for logging an error + writing to an error channel. Both the logger and error channel can be nil.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.