SmartQuant Discussion
http://www.smartquant.com/forums/

Get Historical Bars - Threading Error
http://www.smartquant.com/forums/viewtopic.php?f=44&t=9620
Page 1 of 2

Author:  ivb73077 [ Fri Aug 19, 2011 7:03 pm ]
Post subject:  Get Historical Bars - Threading Error

Hello,

I use GetHistoricalBars to import trades since market open into my TradeSeries. I am periodically getting the error below. It happens if I stop and restart my strategy and I have no idea how to fix this. I am only importing tick-level data for ~15 hours. Can someone on the SQ development team please provide some guidance as to the source of this error and how to correct it? Thank you.

System.Threading.SemaphoreFullException: Adding the specified count to the semaphore would cause it to exceed its maximum count.
at System.Threading.Semaphore.Release(Int32 releaseCount)

at System.Threading.Semaphore.Release()

at bOx13NJnY4b3cgWcZa.LeJgj0Ei5bWdvvHe5H.rmm6mUZs1()

at SmartQuant.Instruments.DataManager.RfJDC0sH0(IHistoricalDataProvider , Instrument , EDataSeries , DateTime , DateTime , Int64 )

at SmartQuant.Instruments.DataManager.GetHistoricalBars(IHistoricalDataProvider provider, Instrument instrument, DateTime datetime1, DateTime datetime2, Int64 barSize)

at OpenQuant.API.DataManager.GetHistoricalBars(String provider, Instrument instrument, DateTime begin, DateTime end, Int32 size)

Author:  ivb73077 [ Mon Aug 22, 2011 6:25 pm ]
Post subject:  Re: Get Historical Bars - Threading Error

Any word on this? I would like to know if there is anything I can do to prevent this error, or to resolve if when it occurs. Thank you.

Author:  Alexei Kurov [ Tue Aug 23, 2011 11:06 am ]
Post subject:  Re: Get Historical Bars - Threading Error

Hi,

It seems that the provider processes historical data requests incorrectly.
What the provider do you use?

Regards,
Alex

Author:  ivb73077 [ Wed Aug 24, 2011 3:52 am ]
Post subject:  Re: Get Historical Bars - Threading Error

We import prices from the start of the trading day (the time of the FX market daily rollover) until we begin trading from NFIQ Feed. After this, we use MB Trading or Hotspot as our live pricing source.

Author:  Alexei Kurov [ Wed Aug 24, 2011 9:38 am ]
Post subject:  Re: Get Historical Bars - Threading Error

I would like to know what provider is used for historical data requests - is it NFIQ Feed?

Author:  ivb73077 [ Wed Aug 24, 2011 2:58 pm ]
Post subject:  Re: Get Historical Bars - Threading Error

Yes. NFIQ for historicals. Thank you.

Author:  Alexei Kurov [ Wed Aug 24, 2011 3:14 pm ]
Post subject:  Re: Get Historical Bars - Threading Error

Unfortunately, we do not support third party plugins, but I think that the reason of the problem is the plugin sends some events(completed,cancelled,error) twice. For example, it may send error+completed events, but there is only one (error) event is needed.

Author:  ivb73077 [ Wed Aug 24, 2011 4:17 pm ]
Post subject:  Re: Get Historical Bars - Threading Error

Thank you. Can you recommend a historical price source for FX (Eur/Usd) that is supported by SQ? All I need is historicals each day from the FX market rollover.

Author:  Alexei Kurov [ Wed Aug 24, 2011 4:50 pm ]
Post subject:  Re: Get Historical Bars - Threading Error

Hi,

We support all historical data providers included into standard OQ package, but I dont know which of them provides historical FX data.

Author:  Dr. Anton Fokin [ Wed Aug 24, 2011 4:53 pm ]
Post subject:  Re: Get Historical Bars - Threading Error

IB ?

Author:  ivb73077 [ Wed Aug 24, 2011 4:55 pm ]
Post subject:  Re: Get Historical Bars - Threading Error

If I use IB, I will no longer get the threading/semaphore error?

Author:  Dr. Anton Fokin [ Wed Aug 24, 2011 4:57 pm ]
Post subject:  Re: Get Historical Bars - Threading Error

Sure, though I'm not sure IB provides historical data for FX... I know they only send FX quotes in the live feed.

Author:  ivb73077 [ Wed Aug 24, 2011 5:21 pm ]
Post subject:  Re: Get Historical Bars - Threading Error

Ok. Per my previous question, are you aware of any provider that will have historicals and is supported by SQ? I only need historicals for 8 hours. Thanks.

Author:  Dr. Anton Fokin [ Wed Aug 24, 2011 5:25 pm ]
Post subject:  Re: Get Historical Bars - Threading Error

Could you check with IB?

Author:  ivb73077 [ Wed Aug 24, 2011 5:27 pm ]
Post subject:  Re: Get Historical Bars - Threading Error

I will inquire with them. Thanks.

Page 1 of 2 All times are UTC + 3 hours
Powered by phpBB® Forum Software © phpBB Group
https://www.phpbb.com/