Skip to content

Commit

Permalink
ignore handled errors when creating spaces (cs3org#2439)
Browse files Browse the repository at this point in the history
Signed-off-by: Jörn Friedrich Dreyer <jfd@butonic.de>
  • Loading branch information
butonic committed Feb 14, 2022
1 parent 8a956f3 commit 1ed9c9f
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 6 deletions.
5 changes: 5 additions & 0 deletions changelog/unreleased/ignore-known-erros.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
Enhancement: ignore handled errors when creating spaces

The CreateStorageSpace no longer logs all error cases with error level logging

https://github.com/cs3org/reva/pull/2439
12 changes: 6 additions & 6 deletions internal/grpc/services/storageprovider/storageprovider.go
Original file line number Diff line number Diff line change
Expand Up @@ -507,13 +507,13 @@ func (s *service) CreateStorageSpace(ctx context.Context, req *provider.CreateSt
st = status.NewAlreadyExists(ctx, err, "already exists")
default:
st = status.NewInternal(ctx, "error listing spaces")
appctx.GetLogger(ctx).
Error().
Err(err).
Interface("status", st).
Interface("request", req).
Msg("failed to create storage space")
}
appctx.GetLogger(ctx).
Error().
Err(err).
Interface("status", st).
Interface("request", req).
Msg("failed to create storage space")
return &provider.CreateStorageSpaceResponse{
Status: st,
}, nil
Expand Down

0 comments on commit 1ed9c9f

Please sign in to comment.