We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent fd6ac5d commit e0d7ed1Copy full SHA for e0d7ed1
1 file changed
cmd/containerd/command/main_windows.go
@@ -24,6 +24,7 @@ import (
24
"unsafe"
25
26
winio "github.com/Microsoft/go-winio"
27
+ "github.com/Microsoft/go-winio/pkg/etwlogrus"
28
"github.com/containerd/containerd/log"
29
"github.com/containerd/containerd/services/server"
30
"github.com/sirupsen/logrus"
@@ -89,3 +90,12 @@ func setupDumpStacks() {
89
90
}
91
}()
92
93
+
94
+func init() {
95
+ // Provider ID: {2acb92c0-eb9b-571a-69cf-8f3410f383ad}
96
+ // Hook isn't closed explicitly, as it will exist until process exit.
97
+ // GUID is generated based on name - see Microsoft/go-winio/tools/etw-provider-gen.
98
+ if hook, err := etwlogrus.NewHook("ContainerD"); err == nil {
99
+ logrus.AddHook(hook)
100
+ }
101
+}
0 commit comments