Setup
Registers the EventsProxyService handler, configuring OpenTelemetry tracing and metrics, and setting up the internal RunServiceClient for event proxying.
def Setup(
ctx: context.Context,
sc: *app.SetupContext
) - > error
Registers the EventsProxyService handler with the application's mux, enabling it to handle incoming requests. This function initializes OpenTelemetry providers and an interceptor for tracing and metrics, and sets up the necessary client to communicate with the Run Service.
Parameters
| Name | Type | Description |
|---|---|---|
| ctx | context.Context | The context for the operation, used for cancellation and carrying request-scoped values. |
| sc | *app.SetupContext | The application setup context, providing access to the application's mux and base URL for service registration. |
Returns
| Type | Description |
|---|---|
error | Returns an error if OpenTelemetry providers or interceptor cannot be registered or created, or if any other setup step fails. |