Skip to content

Commit

Permalink
alter trace levels
Browse files Browse the repository at this point in the history
  • Loading branch information
maxcountryman committed Nov 26, 2024
1 parent 7011445 commit f4ad7ab
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion src/scheduler.rs
Original file line number Diff line number Diff line change
Expand Up @@ -258,7 +258,7 @@ impl<T: Task> Scheduler<T> {
pub async fn run(&self) -> Result {
let conn = self.queue.pool.acquire().await?;
let Some(guard) = try_acquire_advisory_lock(conn, &self.queue_lock).await? else {
tracing::debug!("Scheduler could not acquire lock, exiting");
tracing::trace!("Scheduler could not acquire lock, exiting");
return Ok(());
};

Expand Down
8 changes: 4 additions & 4 deletions src/worker.rs
Original file line number Diff line number Diff line change
Expand Up @@ -560,7 +560,7 @@ impl<T: Task + Sync> Worker<T> {
async fn handle_shutdown(&self, processing_tasks: &mut JoinSet<()>) -> Result {
let task_timeout = self.task.timeout();

tracing::info!(
tracing::debug!(
task.timeout = ?task_timeout,
"Waiting for all processing tasks or timeout"
);
Expand Down Expand Up @@ -624,7 +624,7 @@ impl<T: Task + Sync> Worker<T> {
processing_tasks: &mut JoinSet<()>,
) {
let Ok(permit) = concurrency_limit.try_acquire_owned() else {
tracing::debug!("Concurrency limit reached");
tracing::trace!("Concurrency limit reached");
return;
};

Expand Down Expand Up @@ -860,7 +860,7 @@ impl<T: Task + Sync> Worker<T> {
retry_count: RetryCount,
retry_policy: &RetryPolicy,
) -> Result {
tracing::info!("Retry policy available, scheduling retry");
tracing::debug!("Retry policy available, scheduling retry");

let delay = retry_policy.calculate_delay(retry_count);
in_progress_task.retry_after(&mut *conn, delay).await?;
Expand All @@ -873,7 +873,7 @@ impl<T: Task + Sync> Worker<T> {
conn: &mut PgConnection,
in_progress_task: &InProgressTask,
) -> Result {
tracing::info!("Retry policy exhausted, handling failed task");
tracing::debug!("Retry policy exhausted, handling failed task");

in_progress_task.mark_failed(&mut *conn).await?;

Expand Down

0 comments on commit f4ad7ab

Please sign in to comment.