mirror of
https://github.com/3ybactuk/marketplace-go-service-project.git
synced 2025-10-30 14:03:45 +03:00
[hw-7] add metrics, tracing
This commit is contained in:
@@ -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")
|
||||
|
||||
Reference in New Issue
Block a user