Why does Metaquotes push MT5 instead of MT4? - page 4

 
fxsaber:

Strange that over the years no one has put asynchronous Order functions into the MT4 kodobase.

How is it? Orders from different terminals?

 
Andrei:

How's that? Orders from different terminals?

Chartow.

 
fxsaber:

Charts.

Do the orders from the individual chart go asynchronously into MT4?
 
fxsaber:

This option, unfortunately, only works for one symbol at a time.


It's strange that no one has put asynchronous Order-functions into MT4 kodobase over the years.


I would call them multi-threaded but synchronous because they wait for a response from the server anyway. There was such a product in the Market. You can search for it.

 
Andrey Barinov:

I would call them multi-threaded, but also synchronous, as they are waiting for a response from the server anyway. There was such a product in the Market. You can look it up.

You can, of course, nerd out on the names.
 
fxsaber:

It's strange that no one has ever put asynchronous Order functions into the MT4 kodobase over the years.

Technically, it is not difficult to create such a scalable system of auxiliary Expert Advisors to send orders, but is it worth it?

After all, there is only one trade flow anyway. While one order from one EA is being processed, IsTradeContextBusy will return true and the next ("parallel") orders will hang in the queue.

 
Stanislav Korotky:

Technically it is not difficult to make such a scalable system of auxiliary EAs to send orders, but is it worth it?

After all, there is only one trade thread anyway. While one order from one Expert Advisor is being processed, IsTradeContextBusy will return true and the next ("parallel") orders will hang in the queue.

Not so. IsTradeContextBusy will return true if 9 orders are sent before at least one of them is processed. Checked. 8 - yes, everything works. Nine in parallel - yes, "thread busy".

 
Vladimir:

Not so. IsTradeContextBusy will return true if 9 orders are sent before at least one of them is processed. Checked. 8 - yes, everything works. Nine in parallel - yes, "thread is busy".

Is there a link to some official source of information? Then, the returned value doesn't guarantee anything, even if the behavior is exactly the same - most likely, it means that there is a buffer for 8 orders but there is still one thread sending them to the server.

 
Stanislav Korotky:

Is there a link to some official source of information? Then, the return value does not guarantee anything, even if the behaviour is exactly that - it most likely means there is a buffer for 8 orders, but there is still one thread sending them to the server.

The thread is the same for one EA. Eight EAs in an account will work without interfering with each other.

I find it strange that you still don't know this. It has been said many times, including by Renat.

 
Stanislav Korotky:

Technically it is not difficult to make such a scalable system of auxiliary EAs to send orders, but is it worth it?

When trading the same portfolio, we need such asynchrony like air. Since Expert Advisors/Scripts can be launched on pure MQL4 and new charts can be opened for them, we just need to write a literate biblue for MT4 once - connect it to the source code in one line and all Order-functions become asynchronous, with OnTrade through CustomEvent and when the Expert Advisor starts, the eight universal Expert Advisors will be automatically loaded in the background.

Reason: