Skip to content

Commit 3bcd208

Browse files
committed
ADD: async parameter to execution request
1 parent 03b3ba5 commit 3bcd208

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

wps/controllers/processes_exec_rest.classic.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,8 @@ public function post(): object
5656
'processes/'.
5757
$processID.
5858
'/execution'.
59-
'?map='.$project->getRelativeQgisPath();
59+
'?mode=async'.
60+
'&map='.$project->getRelativeQgisPath();
6061
$response = RequestHandler::curlRequestPOST($url, $data);
6162
} else {
6263
$response = Error::setJSONError($rep, '400', 'Process id not found.');

wps/lib/RequestHandler.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,7 @@ public static function curlRequestPOST(string $url, string $data): string
5252
curl_setopt($ch, CURLOPT_POSTFIELDS, $data);
5353
curl_setopt($ch, CURLOPT_HTTPHEADER, array(
5454
'Accept: application/json',
55+
'Prefer: respond-async',
5556
));
5657

5758
$response = curl_exec($ch);

0 commit comments

Comments
 (0)