Fix miss to handle the error of allocating ts (#27264)

Signed-off-by: yah01 <yah2er0ne@outlook.com>
pull/27275/head
yah01 2023-09-20 18:43:23 +08:00 committed by GitHub
parent 916528f51a
commit 773080df24
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 0 deletions

View File

@ -99,6 +99,9 @@ func (s *Server) Flush(ctx context.Context, req *datapb.FlushRequest) (*datapb.F
ts, err := s.allocator.allocTimestamp(ctx)
if err != nil {
log.Warn("unable to alloc timestamp", zap.Error(err))
return &datapb.FlushResponse{
Status: merr.Status(err),
}, nil
}
timeOfSeal, _ := tsoutil.ParseTS(ts)