Documentation ¶
Index ¶
Constants ¶
View Source
const ( BaseApiPath = "/geoip" APIKey = "GEOS-API-Key" APIKeyMetaKey = "api-key" GrpcAddressMetaKey = "grpc-address" ServiceName = config.ServiceName )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type GrpcMicroservice ¶
type GrpcMicroservice struct {
// contains filtered or unexported fields
}
func NewGrpcMicroservice ¶
func NewGrpcMicroservice(address string, geoIpService controller.GeoIpService, geoNameService controller.GeoNameService) *GrpcMicroservice
func (*GrpcMicroservice) Run ¶
func (s *GrpcMicroservice) Run() error
type Microservice ¶
type Microservice struct {
// contains filtered or unexported fields
}
func NewMicroservice ¶
func NewMicroservice(config config.Config) *Microservice
func (*Microservice) ApiKeyMiddleware ¶
func (m *Microservice) ApiKeyMiddleware() func(next http.Handler) http.Handler
func (*Microservice) BuildRoutes ¶
func (m *Microservice) BuildRoutes(router chi.Router)
func (*Microservice) GetAsyncRunners ¶
func (m *Microservice) GetAsyncRunners() []server.AsyncRunner
Click to show internal directories.
Click to hide internal directories.