Hello Everyone, Am trying to setup SigNoz locally,...
# support
a
Hello Everyone, Am trying to setup SigNoz locally, the system is starting fine, but when adding trace in golang service getting error " 2023/05/21 025832 traces export: the client is shutdown "
p
@Vishal Sharma can you look into this?
v
Looks like issue with instrumentation, how did you instrument? @ankit verma
m
hi ankit , clenup should not run before main ending. If you put it the wrong position such as a func inside main(), it may run after func runed. So you should put the cleanup code in main function.
cleanup := logger.InitTracer()
defer func() { err := cleanup(context.Background()) if err != nil { logger.Error(errors.Wrap(err, 2).ErrorStack()) } }()