prjfs: remove check for ERROR_ACCESS_DENIED during invalidation

Summary:
Due to changes in EdenFS architecture, recursive calls into EdenFS will no
longer lead to ERROR_ACCESS_DENIED errors, thus this is dead code, let's remove
it.

Reviewed By: chadaustin

Differential Revision: D34464273

fbshipit-source-id: e52560d11bf2b3e11742c6bf7b63b6550ffd3cc4
This commit is contained in:
Xavier Deguillard 2022-03-07 16:18:46 -08:00 committed by Facebook GitHub Bot
parent 286b47b712
commit 153b5b54d3

View File

@ -1242,21 +1242,6 @@ folly::Try<folly::Unit> PrjfsChannel::addDirectoryPlaceholder(
if (FAILED(result)) {
if (result == HRESULT_FROM_WIN32(ERROR_REPARSE_POINT_ENCOUNTERED)) {
// This is already a placeholder, not an error.
} else if (result == HRESULT_FROM_WIN32(ERROR_ACCESS_DENIED)) {
// TODO(T78476916): The access denied are coming from
// PrjMarkDirectoryAsPlaceholder recursively calling into EdenFS, which
// is denied by the BAIL_ON_RECURSIVE_CALL macro.
//
// In theory this means that EdenFS is invalidating a directory that
// isn't materialized, ie: doing useless work. Despite having a negative
// performance impact, this doesn't affect correctness, so ignore for now.
//
// A long term fix will need to not issue invalidation on directories
// that aren't materialized.
XLOG_EVERY_MS(WARN, 100) << fmt::format(
FMT_STRING(
"Couldn't add a placeholder for: {}, as it triggered a recursive EdenFS call"),
path);
} else if (result == HRESULT_FROM_WIN32(ERROR_PATH_NOT_FOUND)) {
// If EdenFS happens to be invalidating a directory that is no longer
// present in the destination commit, PrjMarkDirectoryAsPlaceholder would