api/resolver: update resolver to enable subdomain routing (#1747)
* api/resolver: update domain / service prefix usage * api/resolver/subdomain: implement subdomain resolver for domain resolution * api/handler: fix tests
This commit is contained in:
@@ -27,18 +27,6 @@ type Endpoint struct {
|
||||
Method string
|
||||
// HTTP Path e.g /greeter.
|
||||
Path string
|
||||
}
|
||||
|
||||
type Options struct {
|
||||
Handler string
|
||||
Namespace func(*http.Request) string
|
||||
}
|
||||
|
||||
type Option func(o *Options)
|
||||
|
||||
// StaticNamespace returns the same namespace for each request
|
||||
func StaticNamespace(ns string) func(*http.Request) string {
|
||||
return func(*http.Request) string {
|
||||
return ns
|
||||
}
|
||||
// Domain endpoint exists within
|
||||
Domain string
|
||||
}
|
||||
|
Reference in New Issue
Block a user