Go to file
Kevin Franklin Kim 520470de69
feat: bump deps
2024-03-15 15:44:33 +01:00
.github chore: bump actions 2024-03-15 15:44:18 +01:00
.husky feat: update deps and setup 2023-08-11 09:55:34 +02:00
config style: fix typo 2023-09-11 11:52:26 +02:00
env feat: add mongo and refactor readme 2023-09-08 22:24:31 +02:00
errors chore: use new Unwrap() []error 2023-07-06 11:28:22 +02:00
examples feat: bump deps 2024-03-15 15:44:33 +01:00
healthz feat: add GoRoutine service 2023-09-08 12:17:23 +02:00
integration feat: add env configuration 2023-08-14 13:21:49 +02:00
interfaces refactor: rename and modify CloserFunc 2024-03-15 10:10:17 +01:00
jwt feat: fix lint errors 2022-08-12 15:58:56 +02:00
log feat: add GoRoutine service 2023-09-08 12:17:23 +02:00
markdown feat: add nats readmer 2023-09-11 10:37:18 +02:00
metrics feat: fence output 2023-09-11 14:14:58 +02:00
net feat: fix lint error 2023-12-14 09:45:58 +01:00
persistence feat: bump deps 2024-03-15 15:44:33 +01:00
service fix: test 2024-03-15 15:14:32 +01:00
telemetry feat: fix metrics readme 2023-09-11 13:52:24 +02:00
test feat: keep perm 2023-02-20 10:35:21 +01:00
time feat: add keeltime 2022-01-03 13:20:06 +01:00
utils/net/http feat: wrap server error 2023-07-10 12:22:16 +02:00
.editorconfig chore: linting 2021-11-19 14:16:09 +01:00
.gitignore chore: update github workflow 2023-09-08 12:17:44 +02:00
.golangci.yml refactor: expose docs through interface 2023-09-08 15:49:23 +02:00
.goreleaser.yml chore: update github workflow 2023-09-08 12:17:44 +02:00
.husky.yaml chore: update github workflow 2023-09-08 12:17:44 +02:00
.prettierrc.yml chore: update github workflow 2021-11-19 12:29:44 +01:00
closer.go feat: add mongo and refactor readme 2023-09-08 22:24:31 +02:00
CODE_OF_CONDUCT.md feat: update deps and setup 2023-08-11 09:55:34 +02:00
errors.go feat: update graceful shutdown 2024-03-15 11:01:25 +01:00
go.mod feat: bump deps 2024-03-15 15:44:33 +01:00
go.sum feat: bump deps 2024-03-15 15:44:33 +01:00
healthz.go feat: add mongo and refactor readme 2023-09-08 22:24:31 +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 chore: update github workflow 2023-09-08 12:17:44 +02:00
option.go feat: update graceful shutdown 2024-03-15 11:01:25 +01:00
README.md docs: update readme 2023-09-08 12:28:36 +02:00
server_test.go fix: unit tests 2024-03-15 12:41:02 +01:00
server.go fix: test 2024-03-15 15:14:32 +01:00
service.go feat: add name 2021-11-16 15:31:09 +01:00
serviceenabler.go fix: closed race condition 2023-10-03 11:16:33 +02:00

keel

Build Status Go Report Card Coverage Status GoDoc

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"
  "github.com/foomo/keel/service"
)

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

  l := svr.Logger()

  svs := newService()

  svr.AddService(
    service.NewHTTP(l, "demo", "localhost: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.