private Tracer(IScopeManager scopeManager, IPropagator propagator, Options options, ISpanRecorder spanRecorder, ILightStepHttpClient client) { ScopeManager = scopeManager; _spanRecorder = spanRecorder; _propagator = propagator; _options = options; _logger.Debug( $"Creating new tracer with GUID {_options.TracerGuid}. Project Access Token: {_options.AccessToken}, Report Period: {_options.ReportPeriod}, Report Timeout: {_options.ReportTimeout}."); var protocol = _options.Satellite.UsePlaintext ? "http" : "https"; var url = $"{protocol}://{_options.Satellite.SatelliteHost}:{_options.Satellite.SatellitePort}/{LightStepConstants.SatelliteReportPath}"; _httpClient = client ?? new LightStepHttpClient(url, _options); _logger.Debug($"Tracer is reporting to {url}."); _reportLoop = new Timer(e => Flush(), null, TimeSpan.Zero, _options.ReportPeriod); _firstReportHasRun = false; }
public Tracer(Options options, ISpanRecorder spanRecorder, ILightStepHttpClient client) : this( new AsyncLocalScopeManager(), Propagators.TextMap, options, spanRecorder, client) { }
/// <inheritdoc /> public Tracer(Options options, IPropagator propagator, ILightStepHttpClient client) : this( new AsyncLocalScopeManager(), propagator, options, new LightStepSpanRecorder(), client) { }