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

What's difference between EmitData(data,true/false)
http://www.smartquant.com/forums/viewtopic.php?f=60&t=14956
Page 1 of 1

Author:  adam8560@163.com [ Sat Sep 21, 2019 6:45 am ]
Post subject:  What's difference between EmitData(data,true/false)

What's difference between EmitData(data,true) and EmitData(data,false)?

Author:  skuvv [ Mon Sep 23, 2019 4:47 pm ]
Post subject:  Re: What's difference between EmitData(data,true/false)

Hi,
Code:
EmitData(DataObject data, bool queued = true)

Queued=true means that event will be placed in queue.
Queued=false means that event will be pushed to EventServer directly, w/o queue.
Commonly queue need for sync.

Author:  adam8560@163.com [ Tue Sep 24, 2019 6:34 am ]
Post subject:  Re: What's difference between EmitData(data,true/false)

Thank u for your reply.

So I understand my problem that frequent EmitData(data) cause the queue size become more and more big and reach the upperlimit and delay the data, but EmitData(data,false) works very well.

EmitData(data,false) works better than EmitData(data,true). Why do we need EmitData(data,true)?

Author:  skuvv [ Tue Sep 24, 2019 9:51 am ]
Post subject:  Re: What's difference between EmitData(data,true/false)

Perhaps you are slowly processing new data in your strategy, and the queue reaches its limits.
You can profile strategy to find hot places.

However you can use EmitData with false.

Author:  adam8560@163.com [ Fri Sep 27, 2019 9:29 am ]
Post subject:  Re: What's difference between EmitData(data,true/false)

But when I use the EmitData(data,false), the strategy thread model changed and there are multi-threads go through the each InstrumentStrategy. why?

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