@@ -437,10 +437,16 @@ process_command(Cmd) ->
437437process_command ([], _Cmd ) ->
438438 {error , coordinator_unavailable };
439439process_command ([Server | Servers ], Cmd ) ->
440- case ra :process_command (Server , Cmd , ? CMD_TIMEOUT ) of
440+ case ra :process_command (Server , Cmd , cmd_timeout () ) of
441441 {timeout , _ } ->
442+ CmdLabel = case Cmd of
443+ {sac , SacCmd } ->
444+ element (1 , SacCmd );
445+ _ ->
446+ element (1 , Cmd )
447+ end ,
442448 rabbit_log :warning (" Coordinator timeout on server ~w when processing command ~W " ,
443- [element (2 , Server ), element ( 1 , Cmd ) , 10 ]),
449+ [element (2 , Server ), CmdLabel , 10 ]),
444450 process_command (Servers , Cmd );
445451 {error , noproc } ->
446452 process_command (Servers , Cmd );
@@ -450,6 +456,9 @@ process_command([Server | Servers], Cmd) ->
450456 Reply
451457 end .
452458
459+ cmd_timeout () ->
460+ application :get_env (rabbit , stream_cmd_timeout , ? CMD_TIMEOUT ).
461+
453462ensure_coordinator_started () ->
454463 Local = {? MODULE , node ()},
455464 ExpectedMembers = expected_coord_members (),
0 commit comments