Dukascopy
 
 
Wiki JStore Search Login

Attention! Read the forum rules carefully before posting a topic.

    Submit JForex API bug reports in this forum only.
    Submit Converter issues in Converter Issues.
    Off topics are strictly forbidden.

Any topics which do not satisfy these rules will be deleted.

Order per second max limit is exceeded
 Post subject: Order per second max limit is exceeded Post rating: 0   New post Posted: Fri 31 Mar, 2023, 21:37 

User rating: 18
Joined: Thu 20 Apr, 2017, 22:42
Posts: 165
Location: Russian Federation,
Hello,

I'm trying to batch-change take profit for multiple positions. Operation fails on 3+ position (first two changes are processed OK).

The symptoms are:
- IOrder.setTakeProfitPrice() succeeds
- After that I do not receive expected notification ORDER_CHANGED_OK
- Order is silently NOT changed - take profit stays the same
- In the log I see message “Order per second max limit is exceeded” - I can't catch that notification in my code

The JavaDoc for IOrder.setTakeProfitPrice() says “By default, may not be called on the same order more often than once per second

I remember API was working as stated some time ago - i.e. limit was applied only “on the same order” and I was able to change multiple different positions at once (actually – with a regular network latency of around 50+ms per request = 20 reqs/second).

Now batch-change works only if I make a delay of around 1 second per each invocation of setTakeProfitPrice() even if this invoked on different orders.

Can this be fixed to work according to JavaDoc?


 
 Post subject: Re: Order per second max limit is exceeded Post rating: 0   New post Posted: Wed 24 May, 2023, 11:27 
User avatar

User rating:
Joined: Fri 31 Aug, 2007, 09:17
Posts: 6139
Hello!

You can only update one order per second per sub-account. Any adjustments are impossible because updating orders more often may negatively impact execution of other traders.

If these are unidirectional/multidirectional positions on one instrument, you can use Merge of these positions and later change the take profit of one position.

Sincerely,
Dukascopy Bank


 

Jump to:  

  © 1998-2024 Dukascopy® Bank SA
On-line Currency forex trading with Swiss Forex Broker - ECN Forex Brokerage,
Managed Forex Accounts, introducing forex brokers, Currency Forex Data Feed and News
Currency Forex Trading Platform provided on-line by Dukascopy.com