Documentation ¶
Index ¶
- func CredentialsAPIRouter(credentialsService core.CredentialsService) http.Handler
- func ExtensionsRouter(appCtx appctx.ApplicationContext, registrationService core.RegistrationService, ...) http.Handler
- func LogsAPIRouter(registrationService core.RegistrationService, ...) http.Handler
- func LogsAPIStubRouter() http.Handler
- func NewRouter(appCtx appctx.ApplicationContext, registrationService core.RegistrationService, ...) http.Handler
- func SaveConnInContext(ctx context.Context, c net.Conn) context.Context
- func TelemetryAPIRouter(registrationService core.RegistrationService, ...) http.Handler
- func TelemetryAPIStubRouter() http.Handler
- type Server
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CredentialsAPIRouter ¶
func CredentialsAPIRouter(credentialsService core.CredentialsService) http.Handler
func ExtensionsRouter ¶
func ExtensionsRouter(appCtx appctx.ApplicationContext, registrationService core.RegistrationService, renderingService *rendering.EventRenderingService) http.Handler
ExtensionsRouter returns a new instance of chi router implementing Extensions Runtime API specification.
func LogsAPIRouter ¶
func LogsAPIRouter(registrationService core.RegistrationService, logsSubscriptionAPI telemetry.SubscriptionAPI) http.Handler
LogsAPIRouter returns a new instance of chi router implementing Logs API specification.
func LogsAPIStubRouter ¶
LogsAPIStubRouter returns a new instance of chi router implementing a stub of Logs API that always returns a non-committal response to prevent customer code from crashing when Logs API is disabled locally
func NewRouter ¶
func NewRouter(appCtx appctx.ApplicationContext, registrationService core.RegistrationService, renderingService *rendering.EventRenderingService) http.Handler
NewRouter returns a new instance of chi router implementing Runtime API specification.
func TelemetryAPIRouter ¶
func TelemetryAPIRouter(registrationService core.RegistrationService, telemetrySubscriptionAPI telemetry.SubscriptionAPI) http.Handler
TelemetryRouter returns a new instance of chi router implementing Telemetry API specification.
func TelemetryAPIStubRouter ¶
TelemetryStubRouter returns a new instance of chi router implementing a stub of Telemetry API that always returns a non-committal response to prevent customer code from crashing when Telemetry API is disabled locally
Types ¶
type Server ¶
type Server struct {
// contains filtered or unexported fields
}
Server is a Runtime API server
func NewServer ¶
func NewServer( host string, port int, appCtx appctx.ApplicationContext, registrationService core.RegistrationService, renderingService *rendering.EventRenderingService, telemetryAPIEnabled bool, logsSubscriptionAPI telemetry.SubscriptionAPI, telemetrySubscriptionAPI telemetry.SubscriptionAPI, credentialsService core.CredentialsService, ) *Server
NewServer creates a new Runtime API Server
Unlike net/http server's ListenAndServe, we separate Listen() and Serve(), this is done to guarantee order: call to Listen() should happen before provided runtime is started.
When port is 0, OS will dynamically allocate the listening port.
Directories ¶
Path | Synopsis |
---|---|
Package rendering provides stateful event rendering service.
|
Package rendering provides stateful event rendering service. |