Merge branch 'master' into bts-admin-permissions

This commit is contained in:
Pedro Pinto committed 2019-10-07 08:38:07 -04:00
commit d0cce84d2e
9 files changed
+27 -1

No files matched your search

+4
View File
@@ -4,6 +4,10 @@ weight = 3
sort_by = "weight"
insert_anchor_links = "right"
+++
## 2.11.0
### Internal Changes
- Added support for tag 1031. Currently defaults to Y, can it be override through config.
## 2.10.0
### User Visible Changes
- Fills now include information about the algo that originated the fill
+1
View File
@@ -327,6 +327,7 @@ message RoutingRecord {
string smp_id = 6 ;
SelfMatchPreventionInstruction smp_instruction = 7;
string location = 8;
string cust_order_handling_inst = 9;
}
message NativeOrderState {
+1
View File
@@ -9,4 +9,5 @@ message OrdermanCfg {
}
repeated Executor executor = 1;
optional uint32 default_iceberg_pause_secs = 2 [default = 0];
optional string fallback_cust_order_handling_inst = 3 [default = "Y"];
}
+1
View File
@@ -9,6 +9,7 @@ namespace jetfix {
namespace fix {
typedef BoolField<1028> ManualOrderIndicator;
typedef StringField<1031> CustOrderHandlingInst;
typedef BoolField<123> GapFillFlag;
typedef BoolField<43> PossDupFlag;
typedef BoolField<9768> InFlightMitigation;
+2 -1
View File
@@ -45,7 +45,8 @@ typedef FIXMsg<MessageTypes::ExecutionReport,
Text,
TargetSubID,
MsgSeqNum,
TransactTimeStr>
TransactTimeStr,
CustOrderHandlingInst >
ExecutionReportMsg;
typedef FIXMsg<MessageTypes::BusinessMessageReject,Text>
@@ -260,6 +260,10 @@ void ExecutionGateway::on_exe_report(
if (msg.has<fix::ExecID>())
str_to(msg.get<fix::ExecID>(), &data->exchange_fill_id);
str_to(msg.get<fix::TransactTimeStr>(), &data->transact_time);
if (msg.has<fix::CustOrderHandlingInst>())
data->cust_order_handling_inst = msg.get<fix::CustOrderHandlingInst>();
data->cfg = &me->cfg;
data->msg = text_msg;
me->on_exe_report(*data, msg.trace());
@@ -34,6 +34,7 @@ public:
ExchangeFillID exchange_fill_id;
mercury::TimeStampStr transact_time;
config::JetFIX::Connection const *cfg;
std::string cust_order_handling_inst;
std::string msg;
};
+12
View File
@@ -15,6 +15,7 @@
#include "lib/orderman/securities/ISecurityDB.h"
#include "lib/utils/PBUtils.h"
#include "lib/utils/bts_chrono.h"
#include "lib/config/protos/orderman_cfg.pb.h"
#include "lib/orderman/actors/order_manager/OrderServices.h"
@@ -336,6 +337,7 @@ NativeOrder::on_init_from_exe_report(ExecutionReport const &er,
rr.set_cti_code(CTICode(er.cfg->cti_code()[0]));
rr.set_customer_or_firm(CustomerOrFirm(er.cfg->customer_or_firm()));
rr.set_location(er.cfg->sender_locationid());
rr.set_cust_order_handling_inst(er.cust_order_handling_inst);
on_init_recovered(orecord, os);
return orecord.def();
}
@@ -1102,6 +1104,13 @@ void NativeOrder::report_state() {
me->services->report_state(me->state);
}
std::string NativeOrder::get_cust_order_handling_inst(api::orderman::RoutingRecord const&rr) {
if (rr.cust_order_handling_inst().size())
return rr.cust_order_handling_inst();
else
return config::get<config::OrdermanCfg>().fallback_cust_order_handling_inst();
}
void NativeOrder::init_fix() {
bts_assert(me->sec);
@@ -1129,6 +1138,8 @@ void NativeOrder::init_fix() {
create_encoding.add<fix::CtiCode>(rr.cti_code());
create_encoding.add<fix::SecurityDesc>(sec.glbx().security_desc());
create_encoding.add<fix::ClOrdID>(clordid);
create_encoding.add<fix::CustOrderHandlingInst> (get_cust_order_handling_inst(rr));
if (rr.smp_id().size()) {
create_encoding.add<fix::SelfMatchPreventionID>(rr.smp_id());
if (rr.smp_instruction() != SELF_MATCH_PREVENTION_INSTRUCTION_UNDEFINED)
@@ -1158,6 +1169,7 @@ void NativeOrder::init_fix() {
update_encoding.add<fix::OrigClOrdID>(clordid);
update_encoding.add<fix::CorrelationClOrdID>(clordid);
update_encoding.add<fix::InFlightMitigation>(true);
update_encoding.add<fix::CustOrderHandlingInst> (get_cust_order_handling_inst(rr));
// Self Match Protection
if (rr.smp_id().size()) {
update_encoding.add<fix::SelfMatchPreventionID>(rr.smp_id());
+1
View File
@@ -71,6 +71,7 @@ class NativeOrder : public Order {
void ignore_or_cancel(std::string const &,
api::orderman::OrderError,
OrderOpResult *out) ;
std::string get_cust_order_handling_inst(api::orderman::RoutingRecord const&) ;
};
} // namespace orderman