|
171 | 171 | "type": "string" |
172 | 172 | } |
173 | 173 | ], |
174 | | - "produces": [ |
175 | | - "application/json" |
176 | | - ], |
| 174 | + "produces": ["application/json"], |
177 | 175 | "responses": { |
178 | 176 | "200": { |
179 | 177 | "description": "Request succeeded. Returns boolean depicting if job is in cache.", |
|
198 | 196 | "get": { |
199 | 197 | "description": "This resource is not expecting parameters and it will return a list representing all active jobs in JSON format.", |
200 | 198 | "operationId": "get_jobs", |
201 | | - "produces": [ |
202 | | - "application/json" |
203 | | - ], |
| 199 | + "produces": ["application/json"], |
204 | 200 | "responses": { |
205 | 201 | "200": { |
206 | 202 | "description": "Request succeeded. The response contains the list of all active jobs.", |
|
209 | 205 | "jobs": { |
210 | 206 | "1612a779-f3fa-4344-8819-3d12fa9b9d90": { |
211 | 207 | "cmd": "date", |
212 | | - "cvmfs_mounts": [ |
213 | | - "atlas.cern.ch", |
214 | | - "atlas-condb.cern.ch" |
215 | | - ], |
| 208 | + "cvmfs_mounts": ["atlas.cern.ch", "atlas-condb.cern.ch"], |
216 | 209 | "docker_img": "docker.io/library/busybox", |
217 | 210 | "job_id": "1612a779-f3fa-4344-8819-3d12fa9b9d90", |
218 | 211 | "max_restart_count": 3, |
|
221 | 214 | }, |
222 | 215 | "2e4bbc1d-db5e-4ee0-9701-6e2b1ba55c20": { |
223 | 216 | "cmd": "date", |
224 | | - "cvmfs_mounts": [ |
225 | | - "atlas.cern.ch", |
226 | | - "atlas-condb.cern.ch" |
227 | | - ], |
| 217 | + "cvmfs_mounts": ["atlas.cern.ch", "atlas-condb.cern.ch"], |
228 | 218 | "docker_img": "docker.io/library/busybox", |
229 | 219 | "job_id": "2e4bbc1d-db5e-4ee0-9701-6e2b1ba55c20", |
230 | 220 | "max_restart_count": 3, |
|
245 | 235 | "summary": "Returns list of all active jobs." |
246 | 236 | }, |
247 | 237 | "post": { |
248 | | - "consumes": [ |
249 | | - "application/json" |
250 | | - ], |
| 238 | + "consumes": ["application/json"], |
251 | 239 | "description": "This resource is expecting JSON data with all the necessary information of a new job.", |
252 | 240 | "operationId": "create_job", |
253 | 241 | "parameters": [ |
|
261 | 249 | } |
262 | 250 | } |
263 | 251 | ], |
264 | | - "produces": [ |
265 | | - "application/json" |
266 | | - ], |
| 252 | + "produces": ["application/json"], |
267 | 253 | "responses": { |
268 | 254 | "201": { |
269 | 255 | "description": "Request succeeded. The job has been launched.", |
|
304 | 290 | "type": "string" |
305 | 291 | } |
306 | 292 | ], |
307 | | - "produces": [ |
308 | | - "application/json" |
309 | | - ], |
| 293 | + "produces": ["application/json"], |
310 | 294 | "responses": { |
311 | 295 | "200": { |
312 | 296 | "description": "Request succeeded. The response contains details about the given job ID.", |
313 | 297 | "examples": { |
314 | 298 | "application/json": { |
315 | 299 | "job": { |
316 | 300 | "cmd": "date", |
317 | | - "cvmfs_mounts": [ |
318 | | - "atlas.cern.ch", |
319 | | - "atlas-condb.cern.ch" |
320 | | - ], |
| 301 | + "cvmfs_mounts": ["atlas.cern.ch", "atlas-condb.cern.ch"], |
321 | 302 | "docker_img": "docker.io/library/busybox", |
322 | 303 | "job_id": "cdcf48b1-c2f3-4693-8230-b066e088c6ac", |
323 | 304 | "max_restart_count": 3, |
|
344 | 325 | }, |
345 | 326 | "/jobs/{job_id}/": { |
346 | 327 | "delete": { |
347 | | - "consumes": [ |
348 | | - "application/json" |
349 | | - ], |
| 328 | + "consumes": ["application/json"], |
350 | 329 | "description": "This resource expects the `job_id` of the job to be deleted.", |
351 | 330 | "operationId": "delete_job", |
352 | 331 | "parameters": [ |
|
365 | 344 | "type": "string" |
366 | 345 | } |
367 | 346 | ], |
368 | | - "produces": [ |
369 | | - "application/json" |
370 | | - ], |
| 347 | + "produces": ["application/json"], |
371 | 348 | "responses": { |
372 | 349 | "204": { |
373 | 350 | "description": "Request accepted. A request to delete the job has been sent to the\n compute backend." |
|
405 | 382 | "type": "string" |
406 | 383 | } |
407 | 384 | ], |
408 | | - "produces": [ |
409 | | - "application/json" |
410 | | - ], |
| 385 | + "produces": ["application/json"], |
411 | 386 | "responses": { |
412 | 387 | "200": { |
413 | 388 | "description": "Request succeeded. The response contains the logs for the given job.", |
|
431 | 406 | }, |
432 | 407 | "/shutdown": { |
433 | 408 | "delete": { |
434 | | - "consumes": [ |
435 | | - "application/json" |
436 | | - ], |
| 409 | + "consumes": ["application/json"], |
437 | 410 | "description": "All running jobs will be stopped and no more jobs will be scheduled. Kubernetes will call this endpoint before stopping the pod (PreStop hook).", |
438 | 411 | "operationId": "shutdown", |
439 | | - "produces": [ |
440 | | - "application/json" |
441 | | - ], |
| 412 | + "produces": ["application/json"], |
442 | 413 | "responses": { |
443 | 414 | "200": { |
444 | 415 | "description": "Request successful. All jobs were stopped.", |
|
0 commit comments