internal Tracing()
        {
            IEventQueue eventQueue = new SimpleEventQueue();

            TraceConfig = new Config.TraceConfig();

            SpanExporter = Export.SpanExporter.Create();

            IStartEndHandler startEndHandler =
                new StartEndHandler(
                    SpanExporter,
                    eventQueue);

            tracer = new Tracer(startEndHandler, TraceConfig);
        }
Exemplo n.º 2
0
        /// <summary>
        /// Initializes a new instance of the <see cref="TraceComponent"/> class.
        /// </summary>
        /// <param name="randomHandler">Random numbers generator.</param>
        /// <param name="eventQueue">Event queue to use before the exporter.</param>
        public TraceComponent(IRandomGenerator randomHandler, IEventQueue eventQueue)
        {
            this.TraceConfig = new Config.TraceConfig();

            // TODO(bdrutu): Add a config/argument for supportInProcessStores.
            if (eventQueue is SimpleEventQueue)
            {
                this.ExportComponent = Export.ExportComponent.CreateWithoutInProcessStores(eventQueue);
            }
            else
            {
                this.ExportComponent = Export.ExportComponent.CreateWithInProcessStores(eventQueue);
            }

            IStartEndHandler startEndHandler =
                new StartEndHandler(
                    this.ExportComponent.SpanExporter,
                    ((ExportComponent)this.ExportComponent).RunningSpanStore,
                    ((ExportComponent)this.ExportComponent).SampledSpanStore,
                    eventQueue);

            this.Tracer = new Tracer(randomHandler, startEndHandler, this.TraceConfig, null);
        }
Exemplo n.º 3
0
        internal Tracing()
        {
            IEventQueue eventQueue = new SimpleEventQueue();

            TraceConfig = new Config.TraceConfig();

            // TODO(bdrutu): Add a config/argument for supportInProcessStores.
            if (eventQueue is SimpleEventQueue)
            {
                ExportComponent = Export.ExportComponent.CreateWithoutInProcessStores(eventQueue);
            }
            else
            {
                ExportComponent = Export.ExportComponent.CreateWithInProcessStores(eventQueue);
            }

            IStartEndHandler startEndHandler =
                new StartEndHandler(
                    ExportComponent.SpanExporter,
                    eventQueue);

            tracer = new Tracer(startEndHandler, TraceConfig);
        }
 public InProcessRunningSpanStoreTest()
 {
     startEndHandler = new StartEndHandler(sampledSpansServiceExporter, activeSpansExporter, null, new SimpleEventQueue());
 }