forked from taskcluster/taskcluster
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path0068.yml
30 lines (30 loc) · 1.04 KB
/
0068.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
version: 68
description: add queue_artifact_present
methods:
queue_artifact_present:
serviceName: queue
description: |-
Mark the given queue artifact as present, returning the updated artifact. Returns
nothing if no such artifact exists.
mode: write
args: task_id_in text, run_id_in integer, name_in text
returns: table(task_id text, run_id integer, name text, storage_type text, content_type text, details jsonb, present boolean, expires timestamptz)
body: |-
begin
return query
update queue_artifacts
set present = true
where
queue_artifacts.task_id = task_id_in and
queue_artifacts.run_id = run_id_in and
queue_artifacts.name = name_in
returning
queue_artifacts.task_id,
queue_artifacts.run_id,
queue_artifacts.name,
queue_artifacts.storage_type,
queue_artifacts.content_type,
queue_artifacts.details,
queue_artifacts.present,
queue_artifacts.expires;
end