From 6a0f625da7414dde5ddf17a9f4e119ac01ca1410 Mon Sep 17 00:00:00 2001 From: Luke Imhoff Date: Thu, 13 Dec 2018 10:00:09 -0600 Subject: [PATCH] Port fix for InvalidConsensus to Uncataloged They have a similar style where Uncataloged could also receive :queue_unavailable. --- .../indexer/lib/indexer/token_transfer/uncataloged/worker.ex | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/apps/indexer/lib/indexer/token_transfer/uncataloged/worker.ex b/apps/indexer/lib/indexer/token_transfer/uncataloged/worker.ex index 0d053895ee..8bc689cf9d 100644 --- a/apps/indexer/lib/indexer/token_transfer/uncataloged/worker.ex +++ b/apps/indexer/lib/indexer/token_transfer/uncataloged/worker.ex @@ -76,7 +76,10 @@ defmodule Indexer.TokenTransfer.Uncataloged.Worker do end def handle_info({ref, {:error, reason}}, %{task_ref: ref, retry_interval: millis} = state) do - Logger.error(fn -> inspect(reason) end) + case reason do + :queue_unavailable -> :ok + _ -> Logger.error(fn -> inspect(reason) end) + end Process.demonitor(ref, [:flush]) Process.send_after(self(), :push_front_blocks, millis)