Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
eos
QuarkDB
Commits
fd57f456
Commit
fd57f456
authored
Mar 17, 2020
by
Georgios Bitzes
Browse files
Show timestamps when ParanoidManifestChecker reports an error
parent
2fdce764
Pipeline
#1492364
failed with stages
in 98 minutes and 58 seconds
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
src/storage/ParanoidManifestChecker.cc
View file @
fd57f456
...
...
@@ -54,6 +54,10 @@ bool operator<(struct timespec &one, struct timespec &two) {
return
one
.
tv_sec
<
two
.
tv_sec
;
}
std
::
string
timespecToString
(
struct
timespec
&
spec
)
{
return
SSTR
(
spec
.
tv_sec
<<
"."
<<
spec
.
tv_nsec
);
}
Status
ParanoidManifestChecker
::
checkDB
(
std
::
string_view
path
)
{
DirectoryIterator
iter
(
path
);
struct
dirent
*
entry
=
nullptr
;
...
...
@@ -76,7 +80,7 @@ Status ParanoidManifestChecker::checkDB(std::string_view path) {
}
int
secDiff
=
sstMtime
.
tv_sec
-
manifestMtime
.
tv_sec
;
std
::
string
diff
=
SSTR
(
secDiff
<<
" sec
"
);
std
::
string
diff
=
SSTR
(
secDiff
<<
" sec
, "
<<
timespecToString
(
sstMtime
)
<<
" vs "
<<
timespecToString
(
manifestMtime
)
);
// 1 hour should be more than enough (?)
if
(
secDiff
>=
3600
)
{
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment