Kbase P15523: Is it possible to run procedure asynchronously without involving AppServer (for example locally).
Autor |
  Progress Software Corporation - Progress |
Acesso |
  Público |
Publicação |
  16/10/2008 |
|
Status: Unverified
GOAL:
Is it possible to run procedure asynchronously without involving AppServer (for example locally).
FIX:
No.
As specified in the documentation for the RUN statement, it is possible to execute something like:
DEF VAR hS AS HANDLE.
DEF VAR hA AS HANDLE.
...
IF wantToRunLocal THEN hS = SESSION.
ELSE DO:
CREATE SERVER hS.
hS:CONNECT(.......).
END.
RUN myProcedure.p
ON SERVER hS
ASYNCHRONOUS SET hA EVENT-PROCEDURE "procedureDone" IN THIS-PROCEDURE.
...
However, if the handle provided to the ON SERVER option in the RUN statement actually points to the SESSION handle, then the program will be run synchronously, that is, just like an ordinary RUN myProcedure.p statement.
The idea is that it's not possible to achieve any kind of parallel processing within one single 4GL client.