Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Jobs and services: Define creation parameters #276 #471

Open
wants to merge 5 commits into
base: draft
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
- `recovery-form` to link to the credentials recovery page.
- `GET /me`: New Relation types `alternate` and `related` for user-specific external pages. [#404](https://github.com/Open-EO/openeo-api/issues/404)
- `GET /credentials/oidc`: Allow `authorization_code` and `urn:ietf:params:oauth:grant-type:device_code` (both without PKCE) as grants for `default_clients`. [#410](https://github.com/Open-EO/openeo-api/issues/410)
- Added `GET /processing_options` to define the parameters that can be submitted when creating jobs or services. [#276](https://github.com/Open-EO/openeo-api/issues/276)
- `GET /jobs` and `GET /jobs/{job_id}`: Added a links property that can for example link to results and logs. [#453](https://github.com/Open-EO/openeo-api/issues/453)
- `GET /jobs/{job_id}/results`:
- Recommendation to add a link with relation type `canonical` which points to a signed URL with the same content as the response. [#397](https://github.com/Open-EO/openeo-api/issues/397)
Expand Down
55 changes: 54 additions & 1 deletion openapi.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2397,6 +2397,43 @@ paths:
$ref: '#/components/responses/client_error_auth'
5XX:
$ref: '#/components/responses/server_error'
/processing_options:
get:
summary: Additional processing options
operationId: list-processing-options
description: |-
Lists additional custom processing options that a back-end offers for the
different processing modes (synchronous processing, batch jobs, secondary web services).

The options specified here can be added to the corresponding `POST` requests
at the top-level of the object that is sent as the payload.
All options SHOULD explicitly be made optional with reasonable defaults
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Couple of slightly related notes/questions:

  • are the defaults global or can they depend on user (e.g. subscription level or some other property)?
  • is it allowed to use a default like null in the public parameter specification which allows the backend to use a an actual fallback value that is not public or dynamic in some sense (e.g. user dependent, dependent on current cluster load, automatically derived from spatial/temporal extent, ...)?
  • is it necessary to cover these concerns in the description?

as otherwise the interoperability between the implementations decreases.
tags:
- Capabilities
- Data Processing
- Batch Jobs
- Secondary Services
security:
- {}
- Bearer: []
responses:
'200':
description: >-
An object with a list of parameters per processing mode.
content:
application/json:
schema:
description: Processing parameters per processing mode.
type: object
properties:
create_job_parameters:
$ref: '#/components/schemas/processing_create_parameters'
create_service_parameters:
$ref: '#/components/schemas/processing_create_parameters'
create_synchronous_parameters:
$ref: '#/components/schemas/processing_create_parameters'

/service_types:
get:
summary: Supported secondary web service protocols
Expand Down Expand Up @@ -5706,7 +5743,23 @@ components:
the same level. For example, if type is string, then default can be
"foo" but cannot be 1. See [JSON Schema draft-07](https://json-schema.org/draft-07/json-schema-validation.html#rfc.section.10.2).
allOf:
- $ref: '#/components/schemas/process_json_schema'
- $ref: '#/components/schemas/json_schema'
processing_create_parameters:
title: Creation Parameters
description: |-
List of additional custom parameters that a back-end offers during the creation
of batch jobs (`POST /jobs`) and secondary web services (`POST /services`) respectively.
type: array
items:
$ref: '#/components/schemas/parameter'
example:
- name: memory
description: Maximum amount of memory that will be allocated for processing, in gigabytes.
optional: true
default: 32
schema:
type: integer
minimum: 1
error:
title: General Error
description: >-
Expand Down