/squad

Squad is package contains a shared shutdown primitive with helpful options.

Primary LanguageGoApache License 2.0Apache-2.0

Squad Go Reference

Squad is package contains a shared shutdown primitive.

Usage

Simple service with signal handler and healthchecker.

package main

import (
	"context"

	"github.com/moeryomenko/squad"
)

func main() {
	s := squad.NewSquad(squad.WithSignalHandler())

	// s.Run(...) // run your code.

	s.Wait()
}

License

Squad is primarily distributed under the terms of both the MIT license and the Apache License (Version 2.0).

See LICENSE-APACHE and/or LICENSE-MIT for details.