Commit Graph

8 Commits

Author SHA1 Message Date
Martin Molinero 7ab6a374cf Addressing reviews
- `TimeSliceFactory` `TimeZone` will now be a constructor parameter
2018-11-14 19:12:45 -03:00
Martin Molinero 251071ee73 Remove Security from Subscription
- Removing unneeded `CashBook` instance to create a new `TimeSlice`
- Adding new `TimeSliceFactory`, an instance base class that will
provide methods to create a new `TimeSlice`. Will own the `DateTimeZone`
property.
- Adding new `ISecurityPrice` and `IOptionPrice` that will provide a
reduced interface for accessing price properties and methods used when
creating a new `TimeSlice`
2018-11-14 18:28:18 -03:00
Stefano Raggi dbaf109c78 Post-review updates
- Renamed events in SubscriptionDataReader and IHistoryProvider
- Added HistoryProvider base class with events and event invocators
2018-10-14 22:29:06 +02:00
Stefano Raggi 9fad26bc8f Add events to IHistoryProvider and SubscriptionDataReader
The SubscriptionDataReaderHistoryProvider was using StubResultHandler, so no error messages were being shown or logged. By adding events to IHistoryProvider and SubscriptionDataReader, the dependency on IResultHandler could be removed completely and error messages are now pushed up the stack.
2018-10-14 22:29:04 +02:00
Stefano Raggi 77b37f4dfd Update IHistoryProvider.Initialize to use HistoryProviderInitializeParameters
This is only a mechanical refactor for the updated IHistoryProvider.Initialize method in all IHistoryProvider implementations, call sites and unit tests.
2018-10-14 22:29:02 +02:00
Michael Handschuh a5179bc6ab Add universe data to TimeSlice
Pipes universe data from the data feed, through TimeSlice.Create and adds
TimeSlice.UniverseData dictionary property for read access from the algo
manager, where the data will be placed onto the correct security object.
2018-04-24 18:23:00 -04:00
Michael Handschuh cee7ff7766 Move clone and tz conversion operations to DF thread
A large percentage of synchronization time is spent performing time zone conversions.
Previously, it was possible that we may compute the same tz conversion multiple times
on the same piece of data until it's emitted. This change moves the time zone conversion
logic onto the data feed thread right before it puts the data into enqueueable enumerator.
In addition, we're not performing the clone operation at the same moment. This removes
unnecessary computation while moving the necessary computation to the data feed thread to
lighten the load on the synchronization/algorithm thread.
2018-02-13 15:59:56 -05:00
Stefano Raggi cf2673f700 Synchronization of GetHistory results with multiple symbols in Live mode
Previously, in Live mode, requesting History for multiple symbols in a single call returned an IEnumerable<Slice> concatenating the results of each request, so every Slice only had one data point and the list was not sorted by time.

This problem has been solved in the following steps:
- Added a new BrokerageHistoryProvider, to be used in live mode with all brokerages
- Removed IHistoryProvider implementations from IB, Oanda, FXCM brokerages
- Added new GetHistory(request) method to IBrokerage interface and implementations
- Moved CreateSliceEnumerableFromSubscriptions method from SubscriptionDataReaderHistoryProvider to the new abstract base class SynchronizingHistoryProvider, to enable reuse in BrokerageHistoryProvider
2017-03-13 00:56:42 +01:00