mirror of
https://github.com/superseriousbusiness/gotosocial.git
synced 2025-10-29 16:42:25 -05:00
[chore] fix testrig with new otel setup (#4135)
Follow-up to https://codeberg.org/superseriousbusiness/gotosocial/pulls/4110 Reviewed-on: https://codeberg.org/superseriousbusiness/gotosocial/pulls/4135 Co-authored-by: tobi <tobi.smethurst@protonmail.com> Co-committed-by: tobi <tobi.smethurst@protonmail.com>
This commit is contained in:
parent
ecbdc4227b
commit
73aa62581e
1 changed files with 2 additions and 4 deletions
|
|
@ -110,7 +110,7 @@ var Start action.GTSAction = func(ctx context.Context) error {
|
||||||
}
|
}
|
||||||
config.SetInstanceLanguages(parsedLangs)
|
config.SetInstanceLanguages(parsedLangs)
|
||||||
|
|
||||||
if err := observability.InitializeTracing(); err != nil {
|
if err := observability.InitializeTracing(ctx); err != nil {
|
||||||
return fmt.Errorf("error initializing tracing: %w", err)
|
return fmt.Errorf("error initializing tracing: %w", err)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -161,7 +161,7 @@ var Start action.GTSAction = func(ctx context.Context) error {
|
||||||
defer testrig.StopWorkers(state)
|
defer testrig.StopWorkers(state)
|
||||||
|
|
||||||
// Initialize metrics.
|
// Initialize metrics.
|
||||||
if err := observability.InitializeMetrics(state.DB); err != nil {
|
if err := observability.InitializeMetrics(ctx, state.DB); err != nil {
|
||||||
return fmt.Errorf("error initializing metrics: %w", err)
|
return fmt.Errorf("error initializing metrics: %w", err)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -250,7 +250,6 @@ var Start action.GTSAction = func(ctx context.Context) error {
|
||||||
var (
|
var (
|
||||||
authModule = api.NewAuth(state, processor, idp, routerSession, sessionName, cookiePolicy) // auth/oauth paths
|
authModule = api.NewAuth(state, processor, idp, routerSession, sessionName, cookiePolicy) // auth/oauth paths
|
||||||
clientModule = api.NewClient(state, processor) // api client endpoints
|
clientModule = api.NewClient(state, processor) // api client endpoints
|
||||||
metricsModule = api.NewMetrics() // Metrics endpoints
|
|
||||||
healthModule = api.NewHealth(state.DB.Ready) // Health check endpoints
|
healthModule = api.NewHealth(state.DB.Ready) // Health check endpoints
|
||||||
fileserverModule = api.NewFileserver(processor) // fileserver endpoints
|
fileserverModule = api.NewFileserver(processor) // fileserver endpoints
|
||||||
robotsModule = api.NewRobots() // robots.txt endpoint
|
robotsModule = api.NewRobots() // robots.txt endpoint
|
||||||
|
|
@ -263,7 +262,6 @@ var Start action.GTSAction = func(ctx context.Context) error {
|
||||||
// these should be routed in order
|
// these should be routed in order
|
||||||
authModule.Route(route)
|
authModule.Route(route)
|
||||||
clientModule.Route(route)
|
clientModule.Route(route)
|
||||||
metricsModule.Route(route)
|
|
||||||
healthModule.Route(route)
|
healthModule.Route(route)
|
||||||
fileserverModule.Route(route)
|
fileserverModule.Route(route)
|
||||||
fileserverModule.RouteEmojis(route, instanceAccount.ID)
|
fileserverModule.RouteEmojis(route, instanceAccount.ID)
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue