Skip to content

Execute a process#9

Merged
mmacata merged 6 commits intomainfrom
execute_process
Feb 17, 2026
Merged

Execute a process#9
mmacata merged 6 commits intomainfrom
execute_process

Conversation

@mmacata
Copy link
Member

@mmacata mmacata commented Jan 29, 2026

This PR adds the "Execute a process" endpoint.

It can receive a valid execute-request-body, parses the inputs and translates it to an actinia process chain. Then it sends this process chain to actinia-core and finally returns a status info response.
As actinia needs to know in which project the job should run, there is a convention to add this project to the actinia module (see also actinia-org/actinia-module-plugin#64). This PR requests the process description and uses the project if found, else it will send the job to a configurable default project.

The output values for transmissionMode and response are not taken into account yet.

The job is not passed to the relatively new endpoint in the actinia-module-plugin actinia-org/actinia-module-plugin#64 as previously thougth but to the "normal" async processing export endpoint from the actinia-module-plugin which supports templates (and native process chains).

Successful example

Example usage with test_process_execution.json:

{
  "inputs": {
    "url_to_geojson_point": "https://raw.githubusercontent.com/mmacata/pagestest/gh-pages/pointInBonn.geojson"
  },
  "outputs": {
    "result": {
      "transmissionMode": "reference"
    }
  },
  "response": "document"
}
JSON=test_process_execution.json
curl -X POST -H 'Content-Type: application/json' -H 'accept: application/json' \
    -u actinia-gdi:actinia-gdi -d @$JSON \
    http://localhost:4044/processes/point_in_polygon/execution > resp.json && cat resp.json | jq

results in:

{
  "jobID": "d470774e-3e24-487d-a66a-347934a6c8b8",
  "status": "accepted",
  "type": "process",
  "message": "Resource accepted",
  "processID": "resource_id-d470774e-3e24-487d-a66a-347934a6c8b8",
  "created": "2026-01-29T12:58:02+00:00",
  "updated": "2026-01-29T12:58:02+00:00",
  "links": [
    {
      "href": "http://localhost:4044/jobs/d470774e-3e24-487d-a66a-347934a6c8b8",
      "rel": "status"
    }
  ]
}

Example with invalid process

Needed for tests to succeed:
actinia-org/actinia-module-plugin#70 (merged)
The response when requesting an invalid module is

curl -X POST -H 'Content-Type: application/json' -H 'accept: application/json' \
    -u actinia-gdi:actinia-gdi -d @$JSON \
    http://localhost:4044/processes/invalid_module/execution > resp.json && cat resp.json | jq;
{
  "type": "http://www.opengis.net/def/exceptions/ogcapi-processes-1/1.0/no-such-process",
  "title": "No Such Process",
  "status": 404,
  "detail": "Process 'invalid_module' not found"
}

@mmacata mmacata changed the base branch from main to job_list_parameters January 29, 2026 13:46
@mmacata mmacata changed the title Execute a process Execute a process (wrapper) Jan 29, 2026
@mmacata mmacata changed the title Execute a process (wrapper) Execute a process (Endpoint part)) Jan 29, 2026
@mmacata mmacata changed the base branch from job_list_parameters to main January 30, 2026 10:40
@mmacata mmacata marked this pull request as ready for review February 5, 2026 09:58
@mmacata mmacata changed the title Execute a process (Endpoint part)) Execute a process Feb 5, 2026
@mmacata mmacata merged commit 4f4e950 into main Feb 17, 2026
12 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants