loaders

package
v1.52.2 Latest Latest
Warning

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

Go to latest
Published: Oct 13, 2019 License: MIT Imports: 2 Imported by: 0

README

loaders

GoDoc

Package loaders implements helpers to initialize global state inside the application.

Install
import (
	"libs.altipla.consulting/loaders"
)
Contributing

You can make pull requests or create issues in GitHub. Any code you send should be formatted using make gofmt.

Running tests

Run the tests:

make test
License

MIT License

Documentation

Overview

Package loaders implements helpers to initialize global state inside the application.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Lazy

func Lazy(once *sync.Once, f func() error) error

Lazy runs the function only once and returns the error if there is one. If the function has already been executed it will never return an error.

It is safe for concurrent use as it uses the once provided to it.

Types

This section is empty.

Jump to

Keyboard shortcuts

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