This module provides hooks that are invoked at various points in the queue lifecycle.
Requirements
This module requires no modules outside of Drupal core.
Configuration
- Enable the module at Administration > Extend.
- Implement any of the hooks provided by the module in your custom modules.
Hooks
Every hook has a generic version that has the queue name passed as argument, and a queue-specific version where the queue name is part of the hook name. Please refer to queue_hooks.api.php for a full overview of available hooks.
| Hook | Description |
|---|---|
hook_queue_item_pre_create(object $item) |
Respond to an item about to be created in a queue. |
hook_queue_item_pre_create_alter(object &$item) |
Alter an item about to be created in a queue. |
hook_queue_item_create(object $item) |
Respond to an item being created in a queue. |
hook_queue_number_of_items_alter(int &$count) |
Alter the number of items reported in a queue. |
hook_queue_lease_time_alter(int &$lease_time) |
Alter the lease time when claiming an item from a queue. |
hook_queue_item_claim(object $item) |
Respond to an item being claimed from a queue. |
hook_queue_item_release(object $item) |
Respond to an item being released back to a queue. |
hook_queue_delay_time_alter(int &$delay_time) |
Alter the delay time when releasing an item back to a queue. |
hook_queue_item_delay(object $item) |
Respond to an item being delayed in a queue. |
hook_queue_item_delete(object $item) |
Respond to an item being deleted from a queue. |
hook_queue_empty() |
Respond to a queue being emptied. |
hook_queue_create() |
Respond to a queue being created. |
hook_queue_delete() |
Respond to a queue being deleted. |
hook_queue_garbage_collection() |
Respond to garbage collection being run on a queue. |
Supporting this Module
You can buy me a coffee through GitHub Sponsors or Ko-fi if you want to support my work.
Supporting organizations:
Development
Project information
- Project categories: Developer tools
- Created by dieterholvoet on , updated
Stable releases for this project are covered by the security advisory policy.
There are currently no supported stable releases.
