Go to file
Kevin Franklin Kim c1f9393dd1 feat: add name
2021-11-16 15:31:09 +01:00
.github/workflows chore: use installed go 2021-10-02 07:36:46 +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
errors feat: add mongo persistance 2021-10-01 16:19:13 +02:00
example style: fix typo 2021-11-08 13:47:59 +01:00
jwt feat: add debug output 2021-11-16 15:30:37 +01:00
log fix: add nosec comment 2021-11-08 13:42:42 +01:00
metrics docs: mark metrics as deprecated 2021-09-10 12:00:38 +02:00
net Merge branch 'main' of github.com:foomo/keel 2021-11-08 13:44:11 +01:00
persistence fix: check for err stream not found 2021-11-08 12:35:33 +01: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 feat: update go mod 2021-10-01 16:19:35 +02:00
go.sum feat: update go mod 2021-10-01 16:19:35 +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 refactor: remove vars 2021-11-16 15:31:00 +01:00
service.go feat: add name 2021-11-16 15:31:09 +01: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.