aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/main/java/com/google/devtools/build/lib/actions
diff options
context:
space:
mode:
authorGravatar tomlu <tomlu@google.com>2018-07-04 08:55:42 -0700
committerGravatar Copybara-Service <copybara-piper@google.com>2018-07-04 08:57:40 -0700
commit2348a75882bda4ed8b983fd4f8af2c45fa292e10 (patch)
tree50e6b82eb7c4d7ba1556a7696e266b630082e87f /src/main/java/com/google/devtools/build/lib/actions
parent9b6208c6d74a5d485bed43f4a214f331e32d8ef6 (diff)
Include more information about build events' referenced local files.
Instead of just a path, events now include information about the type of file (output, source file, stdout/stderr, test logs, etc.). This information can be used by the uploaders to determine a) whether to upload, b) what kind of lease to give the files. RELNOTES: None PiperOrigin-RevId: 203285549
Diffstat (limited to 'src/main/java/com/google/devtools/build/lib/actions')
-rw-r--r--src/main/java/com/google/devtools/build/lib/actions/ActionExecutedEvent.java14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/main/java/com/google/devtools/build/lib/actions/ActionExecutedEvent.java b/src/main/java/com/google/devtools/build/lib/actions/ActionExecutedEvent.java
index a4fa28be5e..372c5598ec 100644
--- a/src/main/java/com/google/devtools/build/lib/actions/ActionExecutedEvent.java
+++ b/src/main/java/com/google/devtools/build/lib/actions/ActionExecutedEvent.java
@@ -17,8 +17,8 @@ package com.google.devtools.build.lib.actions;
import com.google.common.base.MoreObjects;
import com.google.common.base.Preconditions;
import com.google.common.collect.ImmutableList;
-import com.google.common.collect.ImmutableSet;
import com.google.devtools.build.lib.buildeventstream.BuildEvent;
+import com.google.devtools.build.lib.buildeventstream.BuildEvent.LocalFile.LocalFileType;
import com.google.devtools.build.lib.buildeventstream.BuildEventContext;
import com.google.devtools.build.lib.buildeventstream.BuildEventId;
import com.google.devtools.build.lib.buildeventstream.BuildEventStreamProtos;
@@ -118,18 +118,18 @@ public class ActionExecutedEvent implements BuildEventWithConfiguration, Progres
}
@Override
- public ImmutableSet<Path> referencedLocalFiles() {
- ImmutableSet.Builder<Path> artifacts = ImmutableSet.builder();
+ public Collection<LocalFile> referencedLocalFiles() {
+ ImmutableList.Builder<LocalFile> localFiles = ImmutableList.builder();
if (stdout != null) {
- artifacts.add(stdout);
+ localFiles.add(new LocalFile(stdout, LocalFileType.STDOUT));
}
if (stderr != null) {
- artifacts.add(stderr);
+ localFiles.add(new LocalFile(stderr, LocalFileType.STDERR));
}
if (exception == null) {
- artifacts.add(action.getPrimaryOutput().getPath());
+ localFiles.add(new LocalFile(action.getPrimaryOutput().getPath(), LocalFileType.OUTPUT));
}
- return artifacts.build();
+ return localFiles.build();
}
@Override