@@ -70,8 +70,8 @@ handle_cast(init, State = #state{config = Config0}) ->
7070 % % rabbitmq/rabbitmq-shovel#54 for context.
7171 gen_server2 :cast (self (), connect_dest ),
7272 {noreply , State # state {config = Config }}
73- catch _ : _ ->
74- rabbit_log_shovel :error (" Shovel ~ts could not connect to source" , [human_readable_name (maps :get (name , Config0 ))]),
73+ catch E : R ->
74+ rabbit_log_shovel :error (" Shovel ~ts could not connect to source: ~p ~p " , [human_readable_name (maps :get (name , Config0 )), E , R ]),
7575 {stop , shutdown , State }
7676 end ;
7777handle_cast (connect_dest , State = # state {config = Config0 }) ->
@@ -80,8 +80,8 @@ handle_cast(connect_dest, State = #state{config = Config0}) ->
8080 rabbit_log_shovel :debug (" Shovel ~ts connected to destination" , [human_readable_name (maps :get (name , Config ))]),
8181 gen_server2 :cast (self (), init_shovel ),
8282 {noreply , State # state {config = Config }}
83- catch _ : _ ->
84- rabbit_log_shovel :error (" Shovel ~ts could not connect to destination" , [human_readable_name (maps :get (name , Config0 ))]),
83+ catch E : R ->
84+ rabbit_log_shovel :error (" Shovel ~ts could not connect to destination: ~p ~p " , [human_readable_name (maps :get (name , Config0 )), E , R ]),
8585 {stop , shutdown , State }
8686 end ;
8787handle_cast (init_shovel , State = # state {config = Config }) ->
0 commit comments