asobi_quests_rollover_worker (asobi_quests v0.2.2)

View Source

Deletes progress rows from windows nobody can advance or claim any more.

Nothing has to run for a daily quest to reset - the period key changing is the reset (see asobi_quests_period). This exists only so quest_progress does not grow one row per player per quest per day forever.

Discovered by nothing and registered nowhere: shigoto resolves the worker module named on the job row, so a background job in an extension needs no manifest entry at all. This is the one part of the extension contract that already worked before the contract existed.

Enqueue it from the host, on whatever schedule suits:

asobi_quests_rollover_worker:enqueue(#{retain_days => 30}).

Summary

Functions

enqueue(Args)

-spec enqueue(map()) -> {ok, term()} | {error, term()}.

max_attempts()

-spec max_attempts() -> pos_integer().

perform(Args)

-spec perform(map()) -> ok | {error, term()}.

queue()

-spec queue() -> binary().