From 31e2396a5f59990fa5a135dcd6b28e23f603b693 Mon Sep 17 00:00:00 2001 From: Dmitrii Stepanov Date: Tue, 12 Mar 2024 18:57:38 +0300 Subject: [PATCH] [#1043] control: Add ResetEvacuationStatus implementation Signed-off-by: Dmitrii Stepanov --- pkg/local_object_storage/engine/evacuate.go | 10 +++++++ .../engine/evacuate_limiter.go | 15 ++++++++++ .../engine/evacuate_test.go | 12 ++++++++ pkg/services/control/server/evacuate_async.go | 26 ++++++++++++++++++ pkg/services/control/service.pb.go | Bin 235756 -> 246837 bytes pkg/services/control/service.proto | 19 +++++++++++++ pkg/services/control/service_frostfs.pb.go | Bin 107919 -> 113136 bytes pkg/services/control/service_grpc.pb.go | Bin 37157 -> 39311 bytes 8 files changed, 82 insertions(+) diff --git a/pkg/local_object_storage/engine/evacuate.go b/pkg/local_object_storage/engine/evacuate.go index 45600fe66..81fe47e65 100644 --- a/pkg/local_object_storage/engine/evacuate.go +++ b/pkg/local_object_storage/engine/evacuate.go @@ -733,3 +733,13 @@ func (e *StorageEngine) EnqueRunningEvacuationStop(ctx context.Context) error { return e.evacuateLimiter.CancelIfRunning() } + +func (e *StorageEngine) ResetEvacuationStatus(ctx context.Context) error { + select { + case <-ctx.Done(): + return ctx.Err() + default: + } + + return e.evacuateLimiter.ResetEvacuationStatus() +} diff --git a/pkg/local_object_storage/engine/evacuate_limiter.go b/pkg/local_object_storage/engine/evacuate_limiter.go index 63960e238..1e6b9ccb1 100644 --- a/pkg/local_object_storage/engine/evacuate_limiter.go +++ b/pkg/local_object_storage/engine/evacuate_limiter.go @@ -204,3 +204,18 @@ func (l *evacuationLimiter) CancelIfRunning() error { l.cancel() return nil } + +func (l *evacuationLimiter) ResetEvacuationStatus() error { + l.guard.Lock() + defer l.guard.Unlock() + + if l.state.processState == EvacuateProcessStateRunning { + return logicerr.New("there is running evacuation task") + } + + l.state = EvacuationState{} + l.eg = nil + l.cancel = nil + + return nil +} diff --git a/pkg/local_object_storage/engine/evacuate_test.go b/pkg/local_object_storage/engine/evacuate_test.go index 32582cd2a..e8d9a449f 100644 --- a/pkg/local_object_storage/engine/evacuate_test.go +++ b/pkg/local_object_storage/engine/evacuate_test.go @@ -386,6 +386,8 @@ func TestEvacuateObjectsAsync(t *testing.T) { require.ElementsMatch(t, expectedShardIDs, st.ShardIDs(), "invalid running shard ids") require.Equal(t, "", st.ErrorMessage(), "invalid init error message") + require.Error(t, e.ResetEvacuationStatus(context.Background())) + close(blocker) require.Eventually(t, func() bool { @@ -401,6 +403,16 @@ func TestEvacuateObjectsAsync(t *testing.T) { require.Equal(t, "", st.ErrorMessage(), "invalid final error message") require.NoError(t, eg.Wait()) + + require.NoError(t, e.ResetEvacuationStatus(context.Background())) + st, err = e.GetEvacuationState(context.Background()) + require.NoError(t, err, "get state after reset failed") + require.Equal(t, EvacuateProcessStateUndefined, st.ProcessingStatus(), "invalid state after reset") + require.Equal(t, uint64(0), st.ObjectsEvacuated(), "invalid count after reset") + require.Nil(t, st.StartedAt(), "invalid started at after reset") + require.Nil(t, st.FinishedAt(), "invalid finished at after reset") + require.ElementsMatch(t, []string{}, st.ShardIDs(), "invalid shard ids after reset") + require.Equal(t, "", st.ErrorMessage(), "invalid error message after reset") } func TestEvacuateTreesLocal(t *testing.T) { diff --git a/pkg/services/control/server/evacuate_async.go b/pkg/services/control/server/evacuate_async.go index cd7e8a2c7..42ae2635b 100644 --- a/pkg/services/control/server/evacuate_async.go +++ b/pkg/services/control/server/evacuate_async.go @@ -102,3 +102,29 @@ func (s *Server) StopShardEvacuation(ctx context.Context, req *control.StopShard } return resp, nil } + +func (s *Server) ResetShardEvacuationStatus(ctx context.Context, req *control.ResetShardEvacuationStatusRequest) (*control.ResetShardEvacuationStatusResponse, error) { + err := s.isValidRequest(req) + if err != nil { + return nil, status.Error(codes.PermissionDenied, err.Error()) + } + + err = s.s.ResetEvacuationStatus(ctx) + if err != nil { + var logicalErr logicerr.Logical + if errors.As(err, &logicalErr) { + return nil, status.Error(codes.Aborted, err.Error()) + } + return nil, status.Error(codes.Internal, err.Error()) + } + + resp := &control.ResetShardEvacuationStatusResponse{ + Body: &control.ResetShardEvacuationStatusResponse_Body{}, + } + + err = SignMessage(s.key, resp) + if err != nil { + return nil, status.Error(codes.Internal, err.Error()) + } + return resp, nil +} diff --git a/pkg/services/control/service.pb.go b/pkg/services/control/service.pb.go index 261065b58594b21fa19ad6a7140a425808ad1580..5866197672f36e5add62a70ade224728a481486c 100644 GIT binary patch delta 13405 zcmbt)d0f>+_y22V-~yNB0wRcP*9B$gE^q-;#4R;7vBk^@u>x!{Ck&9cp@Ru zoaEX3)wVqp^Qi?h)PJez)Yo(crWxb36|X5xae~g;jjIo7jX#tyd7e0J*VItgia71% z9;389ZZf@O?*PmnB;17x^Xen#2 z9b0xq+r8>EHCD5>WWK=-+SF&0XzUwc-Z{2Jo4F=f@zuSzqN~upuTiVoYRzx?YD3?; zqK#ayRz_(pFD1)GZPZNVJH?vchbFmDvDU@Cn<})2KQ7jCYa_JA6L)FV_@B4gN3*P2 zs{OR_v{t)%Cv#|)+IUcnT5f;ey4p2KLc92Bab0e0G}C5oJ+1ZJuv?3-H$g_6mVDH| zuJ?ysgjV%=F;zO5E;ViACJ?-|c3+;N6`NTEmBk8!cA_ak3*Pjswtc%vXLW6%71T#) z&CUH4u`X}($6RaJ?WOhDRU|1f+Nj!oTH3}4t#F+|+gcl|4f!-qtFQIeS{980<7v4= zj5c~hB82Nq+qON#a;U<|lC}K*1lASQTZMLh|3u1dfSm_q57b6~;RL~3d-}j>3fc~P z=SM@oif>Xd6Rj0)pP;234Aa>Q4u;TA4~q6wR?ob(s)M~0xo-AXpK|S^@0858n)y55 zx9fK?t=ExXrMxI@!1t*Tr6#nXJrlIc-z#xCVRV9jUCo}}LK}9XnC2f~QFUdFMy4G( zd76T|GA}x|n?-Bo->lc>HJjADR@UfKS9tJ#q5bf0wW5Qzb=N>`TVsUWSu5P_tu=3n z(CQCAt4%(w3(=Cl-^c7U=KxFBMkWMmlMY5{mO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{~zUl12+Hw diff --git a/pkg/services/control/service.proto b/pkg/services/control/service.proto index 1377965e6..8501e952f 100644 --- a/pkg/services/control/service.proto +++ b/pkg/services/control/service.proto @@ -36,6 +36,9 @@ service ControlService { // GetShardEvacuationStatus returns evacuation status. rpc GetShardEvacuationStatus (GetShardEvacuationStatusRequest) returns (GetShardEvacuationStatusResponse); + // ResetShardEvacuationStatus resets evacuation status if there is no running evacuation process. + rpc ResetShardEvacuationStatus (ResetShardEvacuationStatusRequest) returns (ResetShardEvacuationStatusResponse); + // StopShardEvacuation stops moving all data from one shard to the others. rpc StopShardEvacuation (StopShardEvacuationRequest) returns (StopShardEvacuationResponse); @@ -426,6 +429,22 @@ message GetShardEvacuationStatusResponse { Signature signature = 2; } +// ResetShardEvacuationStatus request. +message ResetShardEvacuationStatusRequest { + message Body {} + + Body body = 1; + Signature signature = 2; +} + +// ResetShardEvacuationStatus response. +message ResetShardEvacuationStatusResponse { + message Body {} + + Body body = 1; + Signature signature = 2; +} + // StopShardEvacuation request. message StopShardEvacuationRequest { // Request body structure. diff --git a/pkg/services/control/service_frostfs.pb.go b/pkg/services/control/service_frostfs.pb.go index 56b2bd54c81d324e9d283726bff6fa7aa03aa2c8..b90749269d07b5b821f47929c2a7570f74b99575 100644 GIT binary patch delta 225 zcmeA_&Gz9l+XmLJ%t5KelQ+JV+`RYlRYn+R^4`lrlh>Wz0_Xp`!!h~(4c1M~Don^? zoA2M~LJ^q0JB#ruBiO*n|L(9)uD_Ftr2Yt$Ek8NuCGU3mT*jk}V6`B=_H^BR#u<#o zn>W7oh8d~8`P{iy7)NRHnNOFY1}IKGEdn!GX?jc<${yb5LsW!z;*_6dIH@byLkuaJ$A6c8!e^W zic?F96;jI*lS>mzGV}8kic1npN{baT(-cZFQj1a*GK&@R@)e3o^YSwD(vcMw6y+zU z78mPraf02;Dn9w7iWJybK`Xh*K7z7Pw&WyFzR3c@tdkS0;wJkFNNwg5QWJst3y&V5 z$rqHlVMa_YP&ELtH!oD(57A3yr*H5OhT5eBvlHs<%?Vca{9v(#Krdod=LweHXeqHd z$ws4DJP_a*KqM}+33Z=p+zI1r8#E#R(L zaF~aZ&aq+%^gAZPEQLX!{O#TXpA8EQHH)d*mU#|at6{`Ae1&4D{kjjWj@Msn={31; z`F6WnNGT{5uu9Be`iSHl$*#|?|Q_l${tCmj`;Nu9m{HH1vO