Author |
Topic: Cancel Order failed error message (6 messages, Page 1 of 1) |
||||
---|---|---|---|---|---|
Moderators: VPfau | |||||
JGagnon Posts: 95 Joined: Apr 11, 2011 |
Could someone explain what this error means and how we should handle it?
Should we just attempt another trade cancellation? Another command is in execution #202648100 This happened when we attempted to cancel a working order, the order ended up getting filled and we had to manually close it out later. John Gagnon |
||||
VictorV Posts: 746 Joined: May 08, 2007 |
Hello,
generally, this error means that our server received a new command for an order that has in processing previous one. In your case, our simulation engine in API environment was very slow and processed the original order request during a minute. We are researching the reason of this slowdown. Victor Vins Lead Software Developer |
||||
JGagnon Posts: 95 Joined: Apr 11, 2011 |
Thanks Victor, I'll adjust our code to resend the cancellation request. My only concern is if we repeatedly get this message, as you noted the trade did not fill until a minute later. So possibly a bug on the OEC side or do you think this is specific to the simulation engine and should not be a concern in production?
John Gagnon |
||||
VictorV Posts: 746 Joined: May 08, 2007 |
John, this issue with slowdown execution is definitely limited to a simulation engine in this environment. But similar issues, not exactly this one, are possible in production too in the case of disasters or outages on our or exchange side. So, it is good idea to be prepared in production code.
Victor Vins Lead Software Developer |
||||
JGagnon Posts: 95 Joined: Apr 11, 2011 |
Still trying to understand how we should handle this.
We send an order that is waiting to be filled. We attempt to cancel the order and get this error message. What do we do next? Please see OECId: 202660204 I put in code to try to cancel the order again when we get this message, it ended up trying to send over 80 cancel order requests because we kept getting this error message. Please advise. John Gagnon |
||||
VictorV Posts: 746 Joined: May 08, 2007 |
I would check that order is in Working or Held status and Order.Commands.Pending == null before sending a cancel or modify request.
Victor Vins Lead Software Developer |
||||