diff --git a/src/lib/orderman/orders/algo/algo_orders/LeanAlgo.cpp b/src/lib/orderman/orders/algo/algo_orders/LeanAlgo.cpp index 4c0810c28..e69ca3e62 100644 --- a/src/lib/orderman/orders/algo/algo_orders/LeanAlgo.cpp +++ b/src/lib/orderman/orders/algo/algo_orders/LeanAlgo.cpp @@ -54,6 +54,10 @@ void LeanAlgo::do_launch(IAlgoServices& algo) { me->algo_services = &algo; bts_assert(me->child_template); me->child_key = algo.launch_child(*me->child_template, algo.price(), algo.quantity()); + LOG(OrderMan, Info, + "LeanAlgo::do_launch key:{} child_key:{} price:{} qty:{}", + algo.order_key().value(),me->child_key, + algo.price(),algo.quantity()); algo.subscribe_book(SecurityKey(algo.definition().security_key())); } void LeanAlgo::do_launch_attached(IAlgoServices&algo,OrderKey k, ChildState st) { @@ -110,7 +114,12 @@ void LeanAlgo::on_book(SecurityKey, const Book &book) { break; } } -void LeanAlgo::on_child_change(OrderKey, const ChildState &st) { +void LeanAlgo::on_child_change(OrderKey key, const ChildState &st) { + LOG(OrderMan, Info, + "LeanAlgo::on_child_change key:{} child_key:{} status:{} total_fills:{} " + "last_price:{}", + algo().order_key().value(),key, + static_cast(st.status),st.total_fills,st.last_price); algo().update_fill_state(st.total_fills, st.last_price); switch (st.status) { case ChildStatus::WORKING: @@ -254,6 +263,10 @@ bool LeanAlgo::_try_cross() { Update child_update; child_update.set_price(me->observed_price.value()), child_update.set_quantity(algo().quantity().value()); + LOG(OrderMan, Info, "LeanAlgo::_try_cross updating child " + "key:{} child_key:{} price:{} qty:{}", + algo().order_key().value(),me->child_key, + child_update.price(),child_update.quantity()); algo().update_child(me->child_key, child_update); return true; }