Remove legacy repair mechanism since HG and MG switched to new one (#602)

This commit is contained in:
Sergey Yelin 2021-09-17 14:06:37 +03:00 committed by GitHub
parent dddb717330
commit 6ade0aace9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 10 deletions

View File

@ -282,8 +282,7 @@ handle_function_('ProcessRepair', {Args}, #{ns := Ns} = _Opts) ->
-spec dispatch_signal(ns(), Signal, machine()) -> Result when
Signal ::
mg_proto_state_processing_thrift:'InitSignal'()
| mg_proto_state_processing_thrift:'TimeoutSignal'()
| mg_proto_state_processing_thrift:'RepairSignal'(),
| mg_proto_state_processing_thrift:'TimeoutSignal'(),
Result ::
mg_proto_state_processing_thrift:'SignalResult'().
dispatch_signal(Ns, #mg_stateproc_InitSignal{arg = Payload}, Machine) ->
@ -296,13 +295,6 @@ dispatch_signal(Ns, #mg_stateproc_TimeoutSignal{}, Machine) ->
_ = log_dispatch(timeout, Machine),
Module = get_handler_module(Ns),
Result = Module:process_signal(timeout, Machine),
marshal_signal_result(Result, Machine);
%% TODO delete after mg switch on 'ProcessRepair'
dispatch_signal(Ns, #mg_stateproc_RepairSignal{arg = Payload}, Machine) ->
Args = unwrap_args(Payload),
_ = log_dispatch(repair, Args, Machine),
Module = get_handler_module(Ns),
Result = Module:process_repair(Args, Machine),
marshal_signal_result(Result, Machine).
marshal_signal_result(Result = #{}, #{aux_state := AuxStWas}) ->

View File

@ -52,7 +52,7 @@
{<<"metrics">>,{pkg,<<"metrics">>,<<"1.0.1">>},2},
{<<"mg_proto">>,
{git,"https://github.com/rbkmoney/machinegun_proto.git",
{ref,"d814d6948d4ff13f6f41d12c6613f59c805750b2"}},
{ref,"f77367a05c89162bf1e6c3928d611343aba9717a"}},
0},
{<<"mimerl">>,{pkg,<<"mimerl">>,<<"1.2.0">>},2},
{<<"parse_trans">>,{pkg,<<"parse_trans">>,<<"3.3.1">>},2},