Event Timeline
Comment Actions
Other load-git migration tryouts (to keep a reference on):
select json_build_object('args', '[]', 'kwargs', json_build_object('url', arguments#>>'{args,0}'))
from task
where type = 'load-git' and
status != 'disabled' and
policy ='recurring'
limit 10;
-- tryout 1: no
update task
set arguments = json_build_object('args', '[]', 'kwargs', json_build_object('url', arguments#>>'{args,0}'))
where type = 'load-git' and
status != 'disabled' and
policy ='recurring';
-- tryout 2: no
for i in $(seq 0 100000 241824959); do
cat <<EOF
update task
set arguments = json_build_object('args', '[]', 'kwargs', json_build_object('url', arguments#>>'{args,0}'))
where type = 'load-git' and
status != 'disabled' and
policy = 'recurring' and
$i <= id and id < $((i + 100000));
EOF
done > migrate-load-git.sql
-- tryout 3: neither
create table git_task as
select id, type,
json_build_object('args', '[]', 'kwargs', json_build_object('url', arguments#>>'{args,0}')),
next_run,
current_interval,
status,
policy,
retries_left,
priority
from task
where type = 'load-git' and
status != 'disabled';
-- stop because slow