Compare commits

...
2 Commits
Author SHA1 Message Date
Pedro Pinto c2f8e92b10 Hopefully fixed the ilink3 filled qty reporting problem.
This was crashing the spreader.
2020-08-13 08:42:43 -04:00
Pedro Pinto 7ae0142dff Fixed reset of sequence numbers problem 2020-08-12 11:56:08 -04:00
5 changed files with 10 additions and 6 deletions

No files matched your search

+1 -1
View File
@@ -1 +1 @@
set(sources files/cert_secure_logon.txt;files/futures.coconut.xz;files/onixs_ice/ConnectivityConfiguration.APITest.xml;files/onixs_ice/ConnectivityConfiguration.PerfTest.xml;files/onixs_ice/ConnectivityConfiguration.Production.xml;files/perf_trace/compiled.css;files/perf_trace/index.html;files/perf_trace/jquery-3.3.1.min.js;files/perf_trace/main.js;files/perf_trace/perf_log.sql;files/perf_trace/perf_trace_analysis.sql;files/perf_trace/plotly-latest.min.js)
set(sources files/cert_secure_logon.txt;files/futures.coconut.xz;files/onixs_ice/ConnectivityConfiguration.APITest.xml;files/onixs_ice/ConnectivityConfiguration.APITest.xml.orig;files/onixs_ice/ConnectivityConfiguration.PerfTest.xml;files/onixs_ice/ConnectivityConfiguration.Production.xml;files/perf_trace/compiled.css;files/perf_trace/index.html;files/perf_trace/jquery-3.3.1.min.js;files/perf_trace/main.js;files/perf_trace/perf_log.sql;files/perf_trace/perf_trace_analysis.sql;files/perf_trace/plotly-latest.min.js)
+4
View File
@@ -101,6 +101,8 @@ void OrderStore::on_order_state_update(
for (auto const &ev : *u.events) {
auto &rec_info = me->known_orders[ev.key];
LOG(iLink3,Info, "Received order state update for {}",
ev.key.value());
auto &rec = rec_info.rec;
bts_assert(rec.has_def());
rec.set_key(ev.key.value());
@@ -123,6 +125,8 @@ void OrderStore::on_order_definition_update(
std::set<OrderKey> modified_orders;
if (u.events)
for (auto const &ev : *u.events) {
LOG(iLink3,Info, "Received order definition update for {}",
ev.key.value());
auto &rec_info = me->known_orders[ev.key];
auto &rec = rec_info.rec;
rec.set_key(ev.key.value());
+1 -1
View File
@@ -33,7 +33,7 @@ struct Session {
// cme->bts
uint32_t from_cme;
operator bool const() { return from_cme; }
operator bool const() { return to_cme || from_cme; }
};
struct Config {
@@ -108,7 +108,7 @@ void save_session(std::string const &path, Session const &session) {
}
Session load_session(jetfix::SessionName const &sn, std::string const &path) {
auto result = Session{sn.as_uint64_t, 1, 0};
auto result = Session{sn.as_uint64_t, 0, 0};
if (boost::filesystem::exists(path)) {
std::ifstream f(path);
uint64_t dummy;
+3 -3
View File
@@ -861,7 +861,7 @@ void GLBXNativeOrder::on_exe_report(const NewExecutionReportEvent &er) {
auto external_status = map_external_status(er.data->order_status);
// filled quantity is reset back to 0 when the order is canceled
if (external_status != ORDER_STATUS_CANCELED) {
if (external_status != ORDER_STATUS_CANCELED ) {
if (er.data->exec_type == api::orderman::EXEC_TYPE_PARTIAL_FILL ||
er.data->exec_type == api::orderman::EXEC_TYPE_FILL) {
@@ -876,9 +876,9 @@ void GLBXNativeOrder::on_exe_report(const NewExecutionReportEvent &er) {
(previous_sz + fill_sz);
state.set_avg_price(new_avg);
state.set_filled_quantity(er.data->filled_quantity.value());
state.set_last_price(er.data->last_price.value());
}
state.set_filled_quantity(er.data->filled_quantity.value());
state.set_last_price(er.data->last_price.value());
}
state.set_last_msg(er.data->msg);