Critical: If you want to drive your strategy logic based on order fills you must use OnExecutionUpdate() instead of OnOrderUpdate(). OnExecutionUpdate() is always triggered after OnOrderUpdate(). There is internal strategy logic that is triggered after OnOrderUpdate() is called but before OnExecutionUpdate() that can adversely affect your strategy if you are relying on tracking fills within OnOrderUpdate().
What I understand is OnOrderUpdate is called before OnExecutionUpdate but can adversely affect your strategy this because of internal strategy logic.
Can someone explain why such adverse condition?
What are those internal strategy logic?
The main differences that I notice belonging to OnExecutionUpdate are related to the execution itself.
Is this meant that OrderState values cannot be trusted at the time that OnOrderUpdate is triggered?
Thank you.
Dan
Comment