mirror of
https://github.com/facebook/sapling.git
synced 2024-10-08 07:49:11 +03:00
Add logging for EdenServiceHandler::hgGetDirstateTuple
Summary: This was helpful when debugging interactions between Mercurial's dirstate and the related Thrift calls to Eden server. Reviewed By: simpkins Differential Revision: D5664872 fbshipit-source-id: 4e6ef3b034f4fc81f0d467974311a58f54b6e47b
This commit is contained in:
parent
43f27195b6
commit
45ae415877
@ -425,8 +425,21 @@ void EdenServiceHandler::hgGetDirstateTuple(
|
||||
auto dirstate = server_->getMount(*mountPoint)->getDirstate();
|
||||
DCHECK(dirstate != nullptr) << "Failed to get dirstate for "
|
||||
<< mountPoint.get();
|
||||
|
||||
auto filename = RelativePathPiece{*relativePath};
|
||||
out = dirstate->hgGetDirstateTuple(filename);
|
||||
try {
|
||||
out = dirstate->hgGetDirstateTuple(filename);
|
||||
// Print this before invoking hgGetDirstateTuple(), as it may throw.
|
||||
XLOG(DBG2) << "hgGetDirstateTuple(" << *relativePath << ") returning "
|
||||
<< _DirstateNonnormalFileStatus_VALUES_TO_NAMES.at(
|
||||
out.get_status())
|
||||
<< " "
|
||||
<< _DirstateMergeState_VALUES_TO_NAMES.at(out.get_mergeState());
|
||||
} catch (const std::exception& e) {
|
||||
XLOG(DBG2) << "hgGetDirstateTuple(" << *relativePath << ") failed with "
|
||||
<< e.what();
|
||||
throw;
|
||||
}
|
||||
}
|
||||
|
||||
void EdenServiceHandler::hgSetDirstateTuple(
|
||||
|
Loading…
Reference in New Issue
Block a user