Go to file
2022-07-05 16:19:41 +02:00
.github chore(deps): bump golangci/golangci-lint-action from 3.1.0 to 3.2.0 2022-05-16 22:17:18 +00:00
config feat: add helper and update viper 2022-06-11 13:16:11 +02:00
env feat: add int64 and float64 2022-06-30 01:03:37 +02:00
errors feat: implement as interface 2022-05-05 14:12:08 +02:00
example fix: close row 2022-06-30 01:57:45 +02:00
integration feat: add env vars to control otel 2022-06-29 23:58:23 +02:00
jwt fix: allow multiple calls 2022-06-11 18:21:19 +02:00
log feat: add code package field 2022-06-22 12:14:50 +02:00
metrics docs: mark metrics as deprecated 2021-09-10 12:00:38 +02:00
net fix: nil response check in http roundtripper 2022-06-21 18:36:03 +02:00
persistence feat: add db access 2022-07-05 16:19:41 +02:00
telemetry feat: add env vars to control otel 2022-06-29 23:58:23 +02:00
test feat: add meter and tracer 2022-05-13 15:05:58 +02:00
time feat: add keeltime 2022-01-03 13:20:06 +01:00
utils/net/http feat: update otel 2022-05-05 12:19:08 +02:00
.editorconfig chore: linting 2021-11-19 14:16:09 +01:00
.gitignore chore: ignore log files 2022-03-08 14:57:21 +01:00
.golangci.yml chore: update config for go 1.18 2022-04-14 16:00:24 +02:00
.husky.yaml chore: fix husky path 2022-03-24 11:14:44 +01:00
.prettierrc.yml chore: update github workflow 2021-11-19 12:29:44 +01:00
closer.go refactor: rename probe to healthzer 2022-03-14 14:09:28 +01:00
errors.go feat: improve probes 2022-03-11 22:59:55 +01:00
go.mod feat: switch to lib/pq 2022-06-30 01:51:17 +02:00
go.sum feat: switch to lib/pq 2022-06-30 01:51:17 +02:00
healthzer.go refactor: rename probe to healthzer 2022-03-14 14:09:28 +01:00
healthztype.go refactor: rename probe to healthzer 2022-03-14 14:09:28 +01: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: update go mod 2022-05-04 11:38:36 +02:00
option.go feat: add remote config etcd 2022-05-16 22:36:34 +02:00
pinger.go refactor: rename probe to healthz 2022-03-14 13:12:25 +01:00
README.md chore: linting 2021-11-19 14:16:09 +01:00
server_test.go test: add timeout 2022-02-03 09:02:34 +01:00
server.go fix: add stopper 2022-05-16 22:40:30 +02:00
service.go feat: add name 2021-11-16 15:31:09 +01:00
serviceenabler.go feat: add service enabler 2022-06-02 14:10:10 +02:00
servicehttp.go feat: improve probes 2022-03-11 22:59:55 +01:00
servicehttphealthz.go refactor: rename probe to healthzer 2022-03-14 14:09:28 +01: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
shutdowner.go refactor: rename probe to healthz 2022-03-14 13:12:25 +01:00
stopper.go feat: add stopper 2022-05-07 17:49:10 +02:00
unsubscriber.go refactor: rename probe to healthz 2022-03-14 13:12:25 +01: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.