Go to file
2021-10-01 16:18:51 +02:00
.github/workflows chore: update github actions 2021-07-28 16:51:53 +02:00
config feat: extend config with exampl 2021-09-14 08:55:54 +02:00
env initial commit 2021-05-18 08:34:47 +02:00
example feat: add postgres persistance 2021-10-01 16:18:51 +02:00
jwt feat: update telemetry 2021-09-06 22:15:23 +02:00
log fix: prevent nil access 2021-09-08 16:31:00 +02:00
metrics docs: mark metrics as deprecated 2021-09-10 12:00:38 +02:00
net feat: add decode 2021-10-01 16:18:28 +02:00
persistence feat: add postgres persistance 2021-10-01 16:18:51 +02:00
telemetry style: gofmt 2021-09-07 22:05:16 +02:00
utils/net/http revert: don't send error handler 2021-09-10 12:01:20 +02:00
.editorconfig initial commit 2021-05-18 08:34:47 +02:00
.gitignore chore: exclude temp folder 2021-09-06 19:26:06 +02:00
.golangci.yml chore: exclude tests 2021-09-06 19:28:54 +02:00
closer.go feat: add closers 2021-09-29 13:33:56 +02:00
go.mod fix: fix test path 2021-09-14 09:21:40 +02:00
go.sum chore: update go mod 2021-09-06 22:15:37 +02:00
ldflags.go initial commit 2021-05-18 08:34:47 +02:00
LICENSE docs: add license 2021-07-26 15:58:31 +02:00
Makefile feat: add log and telemetry closers by default 2021-05-20 07:34:22 +02:00
option.go feat: add service options 2021-09-06 22:03:39 +02:00
README.md docs: update README 2021-09-07 10:41:33 +02:00
server_test.go fix: fix test path 2021-09-14 09:21:40 +02:00
server.go feat: add closers 2021-09-29 13:33:56 +02:00
service.go initial commit 2021-05-18 08:34:47 +02:00
servicehttp.go feat: pass through service name 2021-09-10 12:02:03 +02:00
servicehttpprometheus.go feat: update telemetry 2021-09-06 22:15:23 +02:00
servicehttpviper.go feat: update telemetry 2021-09-06 22:15:23 +02:00
servicehttpzap.go feat: update telemetry 2021-09-06 22:15:23 +02:00

keel

Go Report Card godoc GitHub Super-Linter

Opinionated way to run services.

Stack

  • Zap
  • Viper
  • Open Telemetry
  • Nats
  • GoTSRPC

Examples

See the examples folder for usages

package main

import (
	"net/http"

	"github.com/foomo/keel"
)

func main() {
	svr := keel.NewServer(
		keel.WithHTTPZapService(true),
		keel.WithHTTPViperService(true),
		keel.WithHTTPPrometheusService(true),
	)

	l := svr.Logger()

	svs := newService()

	svr.AddService(
		keel.NewServiceHTTP(l, "demo", ":8080", svs),
	)

	svr.Run()
}

func newService() *http.ServeMux {
	s := http.NewServeMux()
	s.HandleFunc("/", func(w http.ResponseWriter, r *http.Request) {
		w.WriteHeader(http.StatusOK)
		_, _ = w.Write([]byte("OK"))
	})
	return s
}

How to Contribute

Make a pull request...

License

Distributed under MIT License, please see license file within the code for more details.