Execution Blocks

SKA needs a way to link data to the observations that create the data. To summarise the purpose of Execution Blocks (EBs), EBs exist to link SDP data to the observing session that created the data, be it an observation driven by the OET using an SB Instance or an interactive session where control was exerted via other interface.

The Execution Block defined in the PDM is used to record references to the OSO entities whose execution created the data (Scheduling Block Instances, Scheduling Block Definitions, etc.), the sequence of commands and responses that led to the data, and to link to the SBD Status entity, which is the OSO entity that defines the current state of the SB Definition within the SB Definition lifecycle.

A current example of the Execution Block json, with examples of handling success and error responses from commands, can be seen below:

{
  "interface": "https://schema.skao.int/ska-oso-pdm-eb/0.1",
  "eb_id": "eb-mvp01-20220923-00001",
  "telescope": "ska_mid",
  "sbd_ref": "sbd-mvp01-20220923-00001",
  "sbd_version": 1,
  "sbi_ref": "sbi-mvp01-20220923-00001",
  "metadata": {
    "version": 1,
    "created_by": "TestUser",
    "created_on": "2022-09-23T15:43:53.971548+00:00",
    "last_modified_on": "2022-09-23T15:43:53.971548+00:00",
    "last_modified_by": "TestUser"
  },
  "request_responses": [
    {
      "request": "ska_oso_scripting.functions.devicecontrol.release_all_resources",
      "request_args": "{'args': None, 'kwargs': {'subarray_id': '1'}}",
      "status": "OK",
      "response": {
        "result": "this is a result"
      },
      "request_sent_at": "2022-09-23T15:43:53.971548+00:00",
      "response_received_at": "2022-09-23T15:43:53.971548+00:00"
    },
    {
      "request": "ska_oso_scripting.functions.devicecontrol.scan",
      "status": "ERROR",
      "error": {
        "detail": "this is an error"
      },
      "request_sent_at": "2022-09-23T15:43:53.971548+00:00"
    }
  ]
}