Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Apex/Rithmic Multiple Entries Example Issue

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Apex/Rithmic Multiple Entries Example Issue

    Hello!

    Over the last 2 weeks or so I started receiving several messages of a strategy leaving behind a single order. This comes mainly from Apex/Rithmic users. I have also experienced this quite a bit over the last few weeks in my own trading.

    I have updated my strategy to match the Rithmic/IB friendly example provided on this thread (Managed - Multiple Entries):
    Hello, I see in the documentation you have fixed: 15048 Added Adapter, Rithmic Updated Rithmic API to version 11.3.0.0 Can you elaborate on that please? Will OnOrderUpdate() OnExecutionUpdate() and OnPositionUpdate() be called in the expected order?


    I spent several days updating everything I could, clearing a good chunk of my code to try and find the problem. Then I finally did what I should have done from the beginning. I loaded the example provided by itself and noticed the same problem was still happening with just the example.

    Here is a video of the problem happening: https://drive.google.com/file/d/16eJuPK0RhrvcQMauuDDG9QkmL5XIoP5G/view?usp=sharing


    I'm also uploading a screenshot of the Orders window. Green is Order 2 (Good) Red is Order 1 (Bad)


    Some additional info that may help:
    1. I noticed it tends to happen more if the Price moves and hits the target order (Don't move the target under the price).
    2. Doesn't happen all of the time. But only happens during live trading while using apex accounts. (Doesn't appear to be a problem on a SIM)
    3. It doesn't really matter on the order. Either Order 1 or 2 can fail. Usually depending which target is hit first.
    Please let me know if there is a known solution for this. Or if there is anything I can assist in figuring this out as it appears to only be an issue with those using Rithmic.

    Look forward to hearing from you guys.
    Thank you!
    Attached Files
    TradeSaber Inc.NinjaTrader Ecosystem Vendor - TradeSaber Inc.

    #2
    Hello TradeSaber,

    This may be due to how apex supplies events to the platform. I would suggest trying the unmanaged example instead to see if explicitly setting the OCO helps rather than using the managed order handlings signal name system. You may need to adjust the samples to work with apex events as those sample were created before apex was supported and are mainly focused on showing how to use the passed in variables to avoid problems with rithmic based connections. Those may not be fully complete samples as they were only tested on a very small range of connections and use cases.

    Comment


      #3
      Did switching to unmanaged help?

      Comment


        #4
        Yes, switching to unmanaged solved the issue. I used this example from Ninja:


        Stick to the UnmanagedRithmicIBFriendlyMultipleExamples. That is the sample I use for my Predator system and has been the most robust method so far.
        Don't waste time with the managed examples. They are prone to leave hanging orders. (At least they did when I was testing. Not sure about newer version of Ninja)
        TradeSaber Inc.NinjaTrader Ecosystem Vendor - TradeSaber Inc.

        Comment


          #5
          It's been some time, have you run into any issues with the Unmanaged example. I get all kinds of issues running on TopStep Rithmic connections. Do you by chance have any examples you could share?

          Comment


            #6
            I don't really have a simple working sample but here are a few things I've noticed while handling various connections/brokers that will help prevent errors.
            • Never update your order to the same price. (If trailing your stop, make sure to not submit a ChangeOrder() to the same price your stop is currently set at.)
            • Always ensure your Price value is rounded to the nearest Tick when changing your stop. Multiple decimal points values can cause weird issues with Orders.
            • Always make sure that your stop is (stopOrder.OrderState == OrderState.Accepted) before updating. This is specially true when dealing with Rithmic accounts that tend to have lagging orders. Updating an order that hasn't processed will cause problems.
            • Run some sort of a chart lag indicator to make sure your chart is not lagging. Lag will cause all sorts of issues and can send you on a goose chase.
            Lag and data issues will cause all sorts of issues. Running some sort of VPS with low latency will save you quite a bit. Nothing will ever be perfect and I'm not really sure what specific issues you are running into. But the steps above should help with a number of scenarios.
            Hope that helps!
            TradeSaber Inc.NinjaTrader Ecosystem Vendor - TradeSaber Inc.

            Comment


              #7
              Originally posted by TradeSaber View Post
              I don't really have a simple working sample but here are a few things I've noticed while handling various connections/brokers that will help prevent errors.
              • Never update your order to the same price. (If trailing your stop, make sure to not submit a ChangeOrder() to the same price your stop is currently set at.)
              • Always ensure your Price value is rounded to the nearest Tick when changing your stop. Multiple decimal points values can cause weird issues with Orders.
              • Always make sure that your stop is (stopOrder.OrderState == OrderState.Accepted) before updating. This is specially true when dealing with Rithmic accounts that tend to have lagging orders. Updating an order that hasn't processed will cause problems.
              • Run some sort of a chart lag indicator to make sure your chart is not lagging. Lag will cause all sorts of issues and can send you on a goose chase.
              Lag and data issues will cause all sorts of issues. Running some sort of VPS with low latency will save you quite a bit. Nothing will ever be perfect and I'm not really sure what specific issues you are running into. But the steps above should help with a number of scenarios.
              Hope that helps!
              So if we shouldn't update an order to the same price but need to change the quantity what do you do?

              Comment

              Latest Posts

              Collapse

              Topics Statistics Last Post
              Started by argusthome, 03-08-2026, 10:06 AM
              0 responses
              116 views
              0 likes
              Last Post argusthome  
              Started by NabilKhattabi, 03-06-2026, 11:18 AM
              0 responses
              61 views
              0 likes
              Last Post NabilKhattabi  
              Started by Deep42, 03-06-2026, 12:28 AM
              0 responses
              40 views
              0 likes
              Last Post Deep42
              by Deep42
               
              Started by TheRealMorford, 03-05-2026, 06:15 PM
              0 responses
              43 views
              0 likes
              Last Post TheRealMorford  
              Started by Mindset, 02-28-2026, 06:16 AM
              0 responses
              82 views
              0 likes
              Last Post Mindset
              by Mindset
               
              Working...
              X