question

Upvotes
Accepted
97 10 12 13

redi .net api performance (sending orders)

I created 100 orders and difference between timestamp of first order and last order is 24 seconds.

When I send 500 stocks in the portfolio trader, it takes less than a second to send all.

what am i doing wrong? I am simply calling the following function 100 times with change in prices by penny.

public void SendOrder(string sym, string side, int quantity, double price, string exch, string acct)
{
ORDER hOrder = new ORDER();
Object err = null;
Object result; hOrder.Side = side;
hOrder.Symbol = sym;
hOrder.Quantity = quantity>1000.0? quantity=1: quantity;
hOrder.PriceType = "Limit";
hOrder.Price = price;
hOrder.Exchange = exch;
hOrder.TIF = "Day";
hOrder.Ticket = "Bypass";
hOrder.Account = acct;
hOrder.ClientData = string.Format("RAPI{0}", c);
c++; result = hOrder.Submit(err);
}


redi-apiperformance
icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Upvotes
Accepted
410 1 1 3

Hi

Sending orders via Portfolio Trader and the API order entry are different. The latter sends orders one by one, which could take that long for 100 orders.

We have a FIX API available, which is faster. I suggest reaching out to your account manager for more info to see if it would work with your workflow.

Thanks,

Brian

icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Upvotes
46 2 2 6

Instead of using Submit method, if we used Submit2 , will it send faster?. as per document, submit2 is async menthod .

icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Upvotes
410 1 1 3

Hi @JManoharan,

Yes, I'd give Submit2 a try.

Thanks,

Brian

icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Upvotes
97 10 12 13

it was faster but still took 6 seconds or so.

icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Upvotes
97 10 12 13

Additionally, while sending through REDI API my REDI app froze for half a minute.

icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

I think you should try a FIX API as mentioned by Brian.Mullane.

Upvotes
1 0 0 2

I am having a similar problem as newuser. Each individual order takes 2 seconds to register on REDIPlus, i.e 10 orders takes 20 seconds. I have the REDIFix and I am using Submit2. From my analysis it seems that it takes REDIPlus 2 seconds to send me a confirmation message for each order.

What are the recommended solutions?

icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

I've noticed that I am possibly running an old version of REDIPlus but need confirmation for this. I am running:

Version 16.1.0

File Version 11.0.123.40.40

Build 10:09:19 Aug 5 2016.

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.