The app package simplifies creation and management of asynchronous Go applications.
It particular, it has means to:
-
create, start, pause, and quit easy-manageable long-living goroutines in specified order and with specified timeouts;
-
simplify code by abstracting away the complexity of goroutine lifecycle management and concentrate on the actual tasks;
-
gracefully handle application shutdown;
-
intercept
SIGINTandSIGTERMsignals in order to provide graceful shutdown;
Code example to give you the taste:
// TODO