kochman / runner

Run a bunch of things at the same time

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Runner Build Status GoDoc Go Report Card

Runner runs anything with a Run() method. Perfect for API servers with background tasks, health check endpoints, or anything else that does long-lived, blocking work.

package main

import "github.com/kochman/runner"

func main() {
    r := runner.New()
    r.Add(myRunnable{})
    r.Add(anotherRunnable{})
    r.Run()
}

About

Run a bunch of things at the same time

License:MIT License


Languages

Language:Go 100.0%