From 0b7e6da85bab52ff61f17839273c2516c213f2b1 Mon Sep 17 00:00:00 2001 From: Ishank Arora Date: Thu, 31 Mar 2022 09:14:03 +0200 Subject: [PATCH] Enabling tracing by default if not explicitly disabled (#2515) --- changelog/unreleased/enable-default-traces.md | 3 +++ cmd/revad/runtime/runtime.go | 9 +++++++++ 2 files changed, 12 insertions(+) create mode 100644 changelog/unreleased/enable-default-traces.md diff --git a/changelog/unreleased/enable-default-traces.md b/changelog/unreleased/enable-default-traces.md new file mode 100644 index 00000000000..9b96930b92c --- /dev/null +++ b/changelog/unreleased/enable-default-traces.md @@ -0,0 +1,3 @@ +Enhancement: Enabling tracing by default if not explicitly disabled + +https://github.com/cs3org/reva/pull/2515 \ No newline at end of file diff --git a/cmd/revad/runtime/runtime.go b/cmd/revad/runtime/runtime.go index 46c7bb83b49..d37732eb9bb 100644 --- a/cmd/revad/runtime/runtime.go +++ b/cmd/revad/runtime/runtime.go @@ -311,6 +311,15 @@ func parseCoreConfOrDie(v interface{}) *coreConf { os.Exit(1) } + // tracing defaults to enabled if not explicitly configured + if v == nil { + c.TracingEnabled = true + c.TracingEndpoint = "localhost:6831" + } else if _, ok := v.(map[string]interface{})["tracing_enabled"]; !ok { + c.TracingEnabled = true + c.TracingEndpoint = "localhost:6831" + } + return c }