OAPI: add mass-task-refresh option to SocketIO job updates

Add `JobUpdate.refresh_tasks` property, to signal to SocketIO clients that
the job update is so big, all the job's tasks should be refreshed.

This is much faster than sending individual task updates one by one.
This commit is contained in:
Sybren A. Stüvel 2022-05-17 14:47:33 +02:00
parent 163611ff19
commit 9d9ff77ee0

View File

@ -1236,7 +1236,13 @@ components:
"previous_status": { $ref: "#/components/schemas/JobStatus" } "previous_status": { $ref: "#/components/schemas/JobStatus" }
"type": { type: string } "type": { type: string }
"priority": { type: integer, default: 50 } "priority": { type: integer, default: 50 }
required: [id, updated, status, type, priority] "refresh_tasks":
type: boolean
description: >
Indicates that the client should refresh all the job's tasks. This
is sent for mass updates, where updating each individual task would
generate too many updates to be practical.
required: [id, updated, status, type, priority, refresh_tasks]
SocketIOTaskUpdate: SocketIOTaskUpdate:
type: object type: object