public void GetLiveBars()
        {
            var watch = Stopwatch.StartNew();

            _fetchData.ReadData(_barDataRequest);

            watch.Stop();
            var elapsedMs = watch.ElapsedMilliseconds;

            Logger.Debug("Time consumer: " + elapsedMs, "SimulatorControler.Test.Unit", "GetLiveBars");
        }
 /// <summary>
 /// Creats a seprate thread for each request.
 /// </summary>
 /// <param name="request"></param>
 public void FetchData(BarDataRequest request)
 {
     try
     {
         Task.Factory.StartNew(() => _fetchMarketData.ReadData(request));
     }
     catch (Exception exception)
     {
         _classLogger.Error(exception, _type.FullName, "FetchData");
     }
 }
        /// <summary>
        /// Creats a seprate thread for each request.
        /// </summary>
        /// <param name="request"></param>
        public void FetchData(BarDataRequest request)
        {
            try
            {
                var task = Task.Factory.StartNew(() => _fetchMarketData.ReadData(request));

                _tasksCollection.Add(task);

                //_marketDataList=_fetchMarketData.ReadData(request,true);
                //_persistanceDataCount=_marketDataList.Count;
                //Task.Factory.StartNew(UseLocalData1);
            }
            catch (Exception exception)
            {
                _classLogger.Error(exception, _type.FullName, "FetchData");
            }
        }