diff --git a/container/container.go b/container/container.go index 1982018..45e0cb9 100644 --- a/container/container.go +++ b/container/container.go @@ -24,6 +24,7 @@ func init() { go func() { <-ctx.Done() Close() + cancel() }() Cancel = cancel return ctx diff --git a/contracts/http.go b/contracts/http.go new file mode 100644 index 0000000..8c40d63 --- /dev/null +++ b/contracts/http.go @@ -0,0 +1,8 @@ +package contracts + +type Route interface{} + +type HttpService interface { + Serve() error + GetEngine() interface{} +} diff --git a/contracts/micro.go b/contracts/micro.go new file mode 100644 index 0000000..8d492b0 --- /dev/null +++ b/contracts/micro.go @@ -0,0 +1,6 @@ +package contracts + +type MicroService interface { + Serve() error + GetEngine() any +}