github.com/blend/go-sdk@v1.20220411.3/datadog/use_tracing.go (about)

     1  /*
     2  
     3  Copyright (c) 2022 - Present. Blend Labs, Inc. All rights reserved
     4  Use of this source code is governed by a MIT license that can be found in the LICENSE file.
     5  
     6  */
     7  
     8  package datadog
     9  
    10  // UseTracing returns if tracing is enabled and the trace address is configured.
    11  //
    12  // It should be used to gate if you should create tracers with `NewTracer`.
    13  func UseTracing(cfg Config) bool {
    14  	return cfg.TracingEnabledOrDefault() && cfg.GetTraceAddress() != ""
    15  }