opengeospatial / ogcapi-routes

public repo for OGC API - Routes Standards Working Group
Other
10 stars 3 forks source link

Move Asynchronous Execution to future work #40

Closed cportele closed 2 years ago

cportele commented 2 years ago

The Asynchronous Execution requirements/conformance class should be moved outside of Core and to a future part.

Rationals: Current implementations all seem to focus on synchronous execution, which is much simpler to implement for both servers and clients. In that sense, asynchronous execution is not a core capability and that should be reflected in the scope of Part 1.

As discussed in #37, the parts of the current requirements class that deals with sharing and managing route resources (GET on /routes, /routes/{routeId} and /routes/{routeId}/definition as well as DELETE on /routes/{routeId}) should become part of a new requirements class "Sharing and managing routes" (or similar) in Part 1.

jeffharrison commented 2 years ago

Sounds reasonable.

Best Regards, Jeff

cportele commented 2 years ago

Related to this is also what the server does when it cannot compute a route.

In general, the HTTP related 4xx and 5xx status codes apply, including all the cases that are not triggered by a situation during the computation of the route. Examples: 401, 402, 405, 406, 415, 502, 503, 504, etc.

The spec distinguishes the following error situations when synchronously computing a route:

Like in all cases, a server would return a 500, if an internal issue occurred (e.g., the connection to the database was lost).

The Route Exchange Model currently still discusses different states of a route resource, inherited from Processes ("accepted", "running", "successful", "failed"). If we move the async execution to a future extension, we can and should also simplify the Route Exchange Model and remove the status information (either an error is returned or a valid route) and all statements related to the states "accepted", "running", and "failed". If/when needed, they could be re-introduced as part of the async extension. "accepted" and "running" do not occur in the synchronous execution, the route is returned once it has been successfully computed. "failure" is not needed, because an error situation will be reported by a 4xx or 5xx response as outlined above. A response according to RFC 7807 (application/problem+json) is recommended, see also Common, or an HTML representation of it.

cportele commented 2 years ago

Meeting 2021-12-09: The change has been agreed.