Skip to content
GitLab
Projects
Groups
Topics
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
hpc
gekkofs
Compare revisions
a61ab03a210b22aba3dc6111b0c56b16f520caed to ce08e512e6614cb27a193594938804fe09648d53
Commits on Source (2)
SQUASH Revert previous commit and handle notfoundexception instead.
· 38d47351
Marc Vef
authored
Apr 24, 2024
38d47351
Adding proxy operation to remove directory
· ce08e512
Marc Vef
authored
Apr 24, 2024
ce08e512
Hide whitespace changes
Inline
Side-by-side
src/client/gkfs_functions.cpp
View file @
ce08e512
...
...
@@ -1347,7 +1347,11 @@ gkfs_rmdir(const std::string& path) {
errno
=
ENOTEMPTY
;
return
-
1
;
}
err
=
gkfs
::
rpc
::
forward_remove
(
path
,
CTX
->
get_replicas
());
if
(
gkfs
::
config
::
proxy
::
fwd_remove
&&
CTX
->
use_proxy
())
{
err
=
gkfs
::
rpc
::
forward_remove_proxy
(
path
);
}
else
{
err
=
gkfs
::
rpc
::
forward_remove
(
path
,
CTX
->
get_replicas
());
}
if
(
err
)
{
errno
=
err
;
return
-
1
;
...
...
src/daemon/backend/metadata/rocksdb_backend.cpp
View file @
ce08e512
...
...
@@ -145,7 +145,7 @@ void
RocksDBBackend
::
remove_impl
(
const
std
::
string
&
key
)
{
auto
s
=
db_
->
Delete
(
write_opts_
,
key
);
if
(
!
s
.
ok
()
&&
!
s
.
IsNotFound
()
)
{
if
(
!
s
.
ok
())
{
throw_status_excpt
(
s
);
}
}
...
...
src/daemon/handler/srv_metadata.cpp
View file @
ce08e512
...
...
@@ -253,6 +253,11 @@ rpc_srv_remove_metadata(hg_handle_t handle) {
GKFS_DATA
->
storage
()
->
destroy_chunk_space
(
in
.
path
);
}
}
catch
(
const
gkfs
::
metadata
::
NotFoundException
&
e
)
{
GKFS_DATA
->
spdlogger
()
->
warn
(
"{}(): path '{}' message '{}'. Continuing, setting out.err 0."
,
__func__
,
in
.
path
,
e
.
what
());
out
.
err
=
0
;
}
catch
(
const
gkfs
::
metadata
::
DBException
&
e
)
{
GKFS_DATA
->
spdlogger
()
->
error
(
"{}(): path '{}' message '{}'"
,
__func__
,
in
.
path
,
e
.
what
());
...
...