Added mark price for Deribit
This commit is contained in:
1 parent
251b014604
commit
f66ab59f0d
2 files changed
+8
-3
No files matched your search
@@ -219,9 +219,10 @@ void MDProducerHandle::update_session_low_offer(TimeStamp, Price) {
|
||||
// cdata().misc_timestamp = TimeStamp::now();
|
||||
}
|
||||
|
||||
void MDProducerHandle::update_fixing_price(TimeStamp, Price) {
|
||||
// cdata().misc.fixing_price = price;
|
||||
// cdata().misc_timestamp = TimeStamp::now();
|
||||
void MDProducerHandle::update_fixing_price(TimeStamp, Price price) {
|
||||
LOG(md, Diag, "fixing_price:{}", price);
|
||||
cdata().misc.fixing_price = price;
|
||||
cdata().misc.misc_timestamp = TimeStamp::now();
|
||||
}
|
||||
|
||||
void MDProducerHandle::mark_deleted() {
|
||||
|
||||
@@ -367,6 +367,10 @@ void EmMDListener::on_security_statistics(
|
||||
sec_data->handle.update_settlement(
|
||||
now, IntPrice_from_double<8>(market_data_stats.settle.to_double()),
|
||||
date_temp);
|
||||
sec_data->handle.update_fixing_price(
|
||||
now, market_data_stats.mark_price.to_double());
|
||||
sec_data->handle.update_closing(
|
||||
now, market_data_stats.mark_price.to_double(), datetime::today());
|
||||
// since volume can also be passed in the handle.add_trade, therefore caching
|
||||
// it for that call
|
||||
auto &sud = get_sud(market_data_stats.sec_id, me->sec_map);
|
||||
|
||||
Reference in new issue
Block a user