mirror of
https://github.com/kevin-DL/services.git
synced 2026-01-11 19:04:35 +00:00
Tracing (#156)
This commit is contained in:
@@ -4,6 +4,7 @@ import (
|
||||
"github.com/micro/micro/v3/service"
|
||||
"github.com/micro/micro/v3/service/logger"
|
||||
"github.com/micro/services/helloworld/handler"
|
||||
"github.com/micro/services/pkg/tracing"
|
||||
)
|
||||
|
||||
func main() {
|
||||
@@ -14,6 +15,8 @@ func main() {
|
||||
|
||||
// Register Handler
|
||||
srv.Handle(new(handler.Helloworld))
|
||||
traceCloser := tracing.SetupOpentracing("helloworld")
|
||||
defer traceCloser.Close()
|
||||
|
||||
// Run the service
|
||||
if err := srv.Run(); err != nil {
|
||||
|
||||
Reference in New Issue
Block a user