Sha256: 5ff11867ea2015386b9c7cb505093ebc3a6473a3cccb377c50610a2ef01b0316

Contents?: true

Size: 419 Bytes

Versions: 94

Compression:

Stored size: 419 Bytes

Contents

local previously_scheduled = redis.call('HGET', KEYS[1], ARGV[1])
redis.call('HSET', KEYS[1], ARGV[1], 'true')

if previously_scheduled ~= 'true' then
    local pcb_key = KEYS[1] .. '-pending_callbacks'
    redis.call('SADD', pcb_key, ARGV[1] .. '-finalize')
    if ARGV[2] == 'true' then
        redis.call('SADD', pcb_key, ARGV[1])
    end
    redis.call('EXPIRE', pcb_key, ARGV[3])
end

return previously_scheduled

Version data entries

94 entries across 94 versions & 1 rubygems

Version Path
canvas_sync-0.22.9 lib/canvas_sync/job_batches/schedule_callback.lua
canvas_sync-0.22.8 lib/canvas_sync/job_batches/schedule_callback.lua
canvas_sync-0.22.6 lib/canvas_sync/job_batches/schedule_callback.lua
canvas_sync-0.22.5 lib/canvas_sync/job_batches/schedule_callback.lua
canvas_sync-0.22.4 lib/canvas_sync/job_batches/schedule_callback.lua
canvas_sync-0.22.3 lib/canvas_sync/job_batches/schedule_callback.lua
canvas_sync-0.22.2 lib/canvas_sync/job_batches/schedule_callback.lua
canvas_sync-0.22.1 lib/canvas_sync/job_batches/schedule_callback.lua
canvas_sync-0.22.0 lib/canvas_sync/job_batches/schedule_callback.lua
canvas_sync-0.22.0.beta8 lib/canvas_sync/job_batches/schedule_callback.lua
canvas_sync-0.22.0.beta7 lib/canvas_sync/job_batches/schedule_callback.lua
canvas_sync-0.22.0.beta6 lib/canvas_sync/job_batches/schedule_callback.lua
canvas_sync-0.22.0.beta5 lib/canvas_sync/job_batches/schedule_callback.lua
canvas_sync-0.22.0.beta4 lib/canvas_sync/job_batches/schedule_callback.lua
canvas_sync-0.22.0.beta3 lib/canvas_sync/job_batches/schedule_callback.lua
canvas_sync-0.22.0.beta2 lib/canvas_sync/job_batches/schedule_callback.lua
canvas_sync-0.22.0.beta1 lib/canvas_sync/job_batches/schedule_callback.lua
canvas_sync-0.21.1 lib/canvas_sync/job_batches/schedule_callback.lua
canvas_sync-0.21.1.beta1 lib/canvas_sync/job_batches/schedule_callback.lua
canvas_sync-0.21.0 lib/canvas_sync/job_batches/schedule_callback.lua