api/pkg/config/rpc.go
Peter Kurfer 1ef1f59402 Add gRPC API implementation
- add config struct for API
- add UUID to endpoint to be able to address them uniquely
- add manager to handle all gRPC services
2020-06-15 12:32:18 +02:00

15 lines
216 B
Go

package config
import "net/url"
type RPC struct {
Listen string
}
func (r RPC) ListenURL() (u *url.URL) {
var err error
if u, err = url.Parse(r.Listen); err != nil {
u, _ = url.Parse("tcp://:0")
}
return
}