I'm evolving from a single-instrument into multi-instrument strategy. As a single-instrument strategy, I know when the strategy is canceled, all open orders are also canceled.
I'm finding that with a multi-instrument strategy, only pending orders on the "primary" instrument are canceled. Pending orders on the "secondary" instrument are not.
So, two questions:
- is this a design feature, or a bug? Any way to automatically close out secondary open orders?
- alternatively, how do I implement this in my code? How do I "catch" a stopping strategy and cancel all of my open orders programmatically?
Comment