[hw-7] add metrics, tracing

This commit is contained in:
Никита Шубин
2025-07-26 14:15:40 +00:00
parent 342bd3f726
commit 4396bebe80
38 changed files with 717 additions and 36 deletions

View File

@@ -11,9 +11,18 @@ import (
"github.com/rs/zerolog/log"
"route256/loms/internal/app"
"route256/loms/internal/infra/tracing"
)
func main() {
shut, err := tracing.InitOTLP(context.Background(), "cart", "jaeger:4318")
if err != nil {
log.Fatal().Err(err).Msg("tracing init failed")
}
defer func() {
_ = shut(context.Background())
}()
srv, err := app.NewApp(os.Getenv("CONFIG_FILE"))
if err != nil {
log.Fatal().Err(err).Msg("failed creating app")