aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/main/java/com/google/devtools/build/lib/skyframe/FileStateFunction.java
diff options
context:
space:
mode:
authorGravatar Nathan Harmata <nharmata@google.com>2016-10-13 18:17:48 +0000
committerGravatar Yue Gan <yueg@google.com>2016-10-14 09:32:53 +0000
commit0c7a42a09d85ddffd9b860bcb31e4c43a00632c1 (patch)
treeec637fb0aedd23c75b066bbbc27f96ae0362324c /src/main/java/com/google/devtools/build/lib/skyframe/FileStateFunction.java
parent7c3d668a9c598110256495d2863b53c9d40befb1 (diff)
Slight refactor of ExternalFilesHelper:
-Make FileType and ExternalFileAction public. -Have producers use ExternalFileAction, rather than a boolean, to specify the desired behavior. And a big change in semantics (doesn't affect Bazel): -Replace ExternalFileAction.ERROR_OUT with ExternalFileAction.ASSUME_NON_EXISTENT_AND_IMMUTABLE, which does what it sounds like. This new action, like the old ERROR_OUT, is _not_ used in Bazel. -- MOS_MIGRATED_REVID=136063159
Diffstat (limited to 'src/main/java/com/google/devtools/build/lib/skyframe/FileStateFunction.java')
-rw-r--r--src/main/java/com/google/devtools/build/lib/skyframe/FileStateFunction.java8
1 files changed, 2 insertions, 6 deletions
diff --git a/src/main/java/com/google/devtools/build/lib/skyframe/FileStateFunction.java b/src/main/java/com/google/devtools/build/lib/skyframe/FileStateFunction.java
index f2dfff824c..dece88c313 100644
--- a/src/main/java/com/google/devtools/build/lib/skyframe/FileStateFunction.java
+++ b/src/main/java/com/google/devtools/build/lib/skyframe/FileStateFunction.java
@@ -50,8 +50,8 @@ public class FileStateFunction implements SkyFunction {
return null;
}
return FileStateValue.create(rootedPath, tsgm.get());
- } catch (FileOutsidePackageRootsException e) {
- throw new FileStateFunctionException(e);
+ } catch (ExternalFilesHelper.NonexistentImmutableExternalFileException e) {
+ return FileStateValue.NONEXISTENT_FILE_STATE_NODE;
} catch (IOException e) {
throw new FileStateFunctionException(e);
} catch (InconsistentFilesystemException e) {
@@ -76,9 +76,5 @@ public class FileStateFunction implements SkyFunction {
public FileStateFunctionException(InconsistentFilesystemException e) {
super(e, Transience.TRANSIENT);
}
-
- public FileStateFunctionException(FileOutsidePackageRootsException e) {
- super(e, Transience.PERSISTENT);
- }
}
}