Proca.Stage.Support (proca v3.4.1)
Support functions for job processing in Broadway. Most imporatntly functions to build RabbitMQ events containing enough data to be processed internally (system) or externally (custom).
Link to this section Summary
Functions
Turn the case of keys in the map to camel case
Flattens the nested map keys so that there is only one nesting level of keys and values. The resulting keys are joined by underscore to form a snake-case key name.
Convert map atom keys to strings
Unpack this AMQP metadata headers: [ {"x-death", :array,
Link to this section Functions
action_data(action, stage \\ :deliver, org_id \\ nil)
action_stage(action)
bulk_actions_data(action_ids, stage \\ :deliver, org_id \\ nil)
camel_case_keys(map)
Turn the case of keys in the map to camel case
confirm_link(confirm, op)
double_opt_in_link(action)
double_opt_in_link(action_id, contact_ref)
ensure_string(a)
failed_partially(messages, statuses)
flatten_keys(map, nil_to \\ nil)
Flattens the nested map keys so that there is only one nesting level of keys and values. The resulting keys are joined by underscore to form a snake-case key name.
ignore(message, reason \\ "ignored")
stringify_keys(map)
Convert map atom keys to strings
supporter_link(action, op)
supporter_link(action_id, contact_ref, op)
times_retried(arg1)
Unpack this AMQP metadata headers: [ {"x-death", :array,
[
table: [
{"count", :long, 55613},
{"exchange", :longstr, "org.320.deliver"},
{"queue", :longstr, "cus.320.deliver"},
{"reason", :longstr, "rejected"},
{"routing-keys", :array, [longstr: "register.fur_free_europe"]},
{"time", :timestamp, 1664450213}
],
table: [
{"count", :long, 55612},
{"exchange", :longstr, "org.320.fail"},
{"queue", :longstr, "org.320.fail"},
{"reason", :longstr, "expired"},
{"routing-keys", :array, [longstr: "cus.320.deliver"]},
{"time", :timestamp, 1664450243}
]
]},
{"x-first-death-exchange", :longstr, "org.320.deliver"}, {"x-first-death-queue", :longstr, "cus.320.deliver"}, {"x-first-death-reason", :longstr, "rejected"} ],