Login Page - Create Account

DTC Protocol Discussion Forum


Date/Time: Sat, 24 Aug 2019 17:58:03 +0000


Two DTC Servers, separate stream and historical, some questions.

Support Request:
[2019-01-29 12:25:35]
norvik_ - Posts: 61
Can not find on this site info about interaction client(SC) with DTC server when using separate real-time and historical data connection.
So some questions, firstly, can you submit, is it possible use 3 different TCP channels , trading, real-time and historical?
What means last point at DTC connection settings menu, named “Primary Connection Always Supports Historical Data”??

According to https://www.sierrachart.com/index.php?page=doc/DTC_TestClient.php, point 17:
To open a chart File >> Find Symbol. Manually type a symbol into the Selected Symbol box and press Open Intraday Chart or Open Historical Chart. This will cause the following messages to be sent to the DTC server:

1.  SECURITY_DEFINITION_FOR_SYMBOL_REQUEST
2.  HISTORICAL_PRICE_DATA_REQUEST
3.  MARKET_DATA_REQUEST

When I’m using separate real-time & historical server, first received request is s_SecurityDefinitionForSymbolRequest, second request is ALWAYS s_MarketDataRequest and last is
s_HistoricalPriceDataRequest.

So, there are different scenarios, I can use to execute this requests.

1.  After receiving s_MarketDataRequest immediately start real-time data for requested ticker
waiting s_HistoricalPriceDataRequest. When s_HistoricalPriceDataRequest received, stop real-time data updating, stop write data to historical file and cash incoming data to temp buffer. Read file and Send all requested historical tick to SC. If over, release temp buffer to file and send buffered data to SC at the same time.
2.   After receiving s_MarketDataRequest not send real-time data for requested ticker until
s_HistoricalPriceDataRequest received. When s_HistoricalPriceDataRequest received, stop write data to historical file and cash incoming data to temp buffer. Read file and Send all requested historical tick to SC. If over, release temp buffer to file and send buffered data to SC at the same time. Then start real-time updating.
3.   After receiving s_MarketDataRequest immediately start real-time data for requested ticker
waiting s_HistoricalPriceDataRequest. When s_HistoricalPriceDataRequest received, DO NOT stop real-time data updating, DO NOT stop write data to historical file. Read file (creating second std::fstream object) and Send all requested historical tick to SC.

May be 4,5…
Please give a correct way for server actions order in this situation.
thank in advance,
norvik
Date Time Of Last Edit: 2019-01-29 16:08:07
[2019-01-30 08:44:20]
norvik_ - Posts: 61
Hi DTC Team, need your help.
Looking at DTCProtocol.cpp, see that real-time market data structures (s_MarketDataUpdateTradeCompact) and historical, s_MarketDataUpdateLastTradeSnapshot,
s_HistoricalPriceDataTickRecordResponse,
has different date time format, historical data always contains DTC::t_DateTimeWithMilliseconds.
As I know, most data providers supply tick data without milliseconds and SC use milliseconds only for synchronization and this field inside SC is simply a sequence number of current trade with same second . I receive data from my data source with original timestamp with milliseconds. Sometimes, in real world,
many trades may has equal microsecond matching time.
So, what is better, in case of historical data for SierraChart, keep original milliseconds or replace it with sequence number inside each second?
[2019-02-01 09:00:15]
norvik_ - Posts: 61
Hi, is anybody here?
Please, give me know, may you need more detailed describtion?

Best regards,
norvik.
[2019-02-03 11:46:56]
norvik_ - Posts: 61
Looking like SierraChart create connection to another feeds, I see that price marker on a new chart begin moving immediately
after login is ok, but chart start to draw only after beginning of historical data receiving completed.

Is it mean that using two servers, I can start send real time data immediately after receiving MarketDataRequest, and then , when accept a HistoricalDataRequest, I'll have to send historical data messages exactly until trade message, which is first market data message?

Can you submit?
Still waiting your help..
[2019-02-03 12:38:35]
DTC Engineering - Posts: 276
We apologize for the delay. This board is not frequently monitored.

is it possible use 3 different TCP channels , trading, real-time and historical?
Yes.

In Sierra Chart when you have set Primary Connection Always Supports Historical Data to True, then whether the message field s_LogonResponse::HistoricalPriceDataSupported is set to true or not, historical data will be considered to be still supported by the primary server connected to.

3. After receiving s_MarketDataRequest immediately start real-time data for requested ticker
waiting s_HistoricalPriceDataRequest. When s_HistoricalPriceDataRequest received, DO NOT stop real-time data updating, DO NOT stop write data to historical file. Read file (creating second std::fstream object) and Send all requested historical tick to SC.
This is the right way to do this. You definitely do not want to stop sending the real-time data.


So, what is better, in case of historical data for SierraChart, keep original milliseconds or replace it with sequence number inside each second?
Definitely use the true milliseconds and Sierra Chart will handle this properly. Also Sierra Chart will be able to utilize the millisecond portion soon.



Is it mean that using two servers, I can start send real time data immediately after receiving MarketDataRequest, and then , when accept a HistoricalDataRequest, I'll have to send historical data messages exactly until trade message, which is first market data message?
Yes.
[2019-02-03 14:37:20]
norvik_ - Posts: 61
Okay, thanks a lot, clear.

To post a message in this thread, you need to login with your Sierra Chart account:

Login

Login Page - Create Account