diff --git a/eb_sqs/worker/worker.py b/eb_sqs/worker/worker.py index 7ffdc5b..61edf0d 100644 --- a/eb_sqs/worker/worker.py +++ b/eb_sqs/worker/worker.py @@ -38,17 +38,19 @@ def execute(self, msg): if settings.DEAD_LETTER_MODE: # If in dead letter mode only try to run callback. Do not execute task. logger.debug( - 'Task %s (%s) not executed (dead letter queue)', + 'Task %s (%s, retry-id: %s) not executed (dead letter queue)', worker_task.abs_func_name, worker_task.id, + worker_task.retry_id, ) self._remove_from_group(worker_task) else: logger.debug( - 'Execute task %s (%s) with args: %s and kwargs: %s', + 'Execute task %s (%s, retry-id: %s) with args: %s and kwargs: %s', worker_task.abs_func_name, worker_task.id, + worker_task.retry_id, worker_task.args, worker_task.kwargs ) @@ -60,9 +62,10 @@ def execute(self, msg): raise except Exception as ex: logger.exception( - 'Task %s (%s) failed to execute with args: %s and kwargs: %s: %s', + 'Task %s (%s, retry-id: %s) failed to execute with args: %s and kwargs: %s: %s', worker_task.abs_func_name, worker_task.id, + worker_task.retry_id, worker_task.args, worker_task.kwargs, ex @@ -93,10 +96,11 @@ def _enqueue_task(self, worker_task, delay, execute_inline, is_retry, count_retr self._add_to_group(worker_task) - logger.debug('%s task %s (%s): %s, %s (%s%s)', + logger.debug('%s task %s (%s, retry-id: %s): %s, %s (%s%s)', 'Retrying' if is_retry else 'Delaying', worker_task.abs_func_name, worker_task.id, + worker_task.retry_id, worker_task.args, worker_task.kwargs, worker_task.queue, @@ -119,9 +123,10 @@ def _enqueue_task(self, worker_task, delay, execute_inline, is_retry, count_retr except QueueClientException as ex: self._remove_from_group(worker_task) - logger.exception('Task %s (%s) failed to enqueue to %s: %s', + logger.exception('Task %s (%s, retry-id: %s) failed to enqueue to %s: %s', worker_task.abs_func_name, worker_task.id, + worker_task.retry_id, worker_task.queue, ex) diff --git a/setup.py b/setup.py index 065c906..19b2043 100644 --- a/setup.py +++ b/setup.py @@ -6,7 +6,7 @@ setup( name='django-eb-sqs', - version='0.94', + version='0.95', package_dir={'eb_sqs': 'eb_sqs'}, include_package_data=True, packages=find_packages(),