diff --git a/handler/option.go b/handler/option.go index b75ca03..b1faf53 100644 --- a/handler/option.go +++ b/handler/option.go @@ -20,6 +20,7 @@ type Options struct { RateLimiter rate.RateLimiter TLSConfig *tls.Config Logger logger.Logger + Service string } type Option func(opts *Options) @@ -66,6 +67,12 @@ func LoggerOption(logger logger.Logger) Option { } } +func ServiceOption(service string) Option { + return func(opts *Options) { + opts.Service = service + } +} + type HandleOptions struct { Metadata metadata.Metadata } diff --git a/ingress/ingress.go b/ingress/ingress.go new file mode 100644 index 0000000..f0f6c0a --- /dev/null +++ b/ingress/ingress.go @@ -0,0 +1,5 @@ +package ingress + +type Ingress interface { + Get(host string) string +}