Skip to content
This repository was archived by the owner on Sep 2, 2024. It is now read-only.

Commit 6b643d9

Browse files
svc-excavator-botmccheah
authored andcommitted
Excavator: Upgrades Baseline to the latest version (#4)
1 parent 0167a21 commit 6b643d9

File tree

5 files changed

+7
-20
lines changed

5 files changed

+7
-20
lines changed

async-shuffle-upload-core/src/main/java/com/palantir/spark/shuffle/async/s3/client/basic/HadoopShuffleClient.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -185,7 +185,7 @@ private Optional<ShuffleUploadTaskMetrics> doWriteFilesAndClose(
185185
SafeArg.of("attemptId", attemptId));
186186
return Optional.empty();
187187
}
188-
} catch (Exception e) {
188+
} catch (RuntimeException e) {
189189
LOGGER.error("Exception encountered while checking for existence of shuffle.",
190190
SafeArg.of("appId", appId),
191191
SafeArg.of("shuffleId", shuffleId),

async-shuffle-upload-core/src/main/java/com/palantir/spark/shuffle/async/s3/client/merging/MergingShuffleUploadCoordinator.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -132,7 +132,7 @@ private void uploadEligibleBatches() {
132132
}
133133
}
134134
LOGGER.trace("Finished checking for uploading shuffle files to the backing store.");
135-
} catch (Exception e) {
135+
} catch (RuntimeException e) {
136136
LOGGER.warn("Failed to process outstanding uploads for shuffle files.", e);
137137
}
138138
}

async-shuffle-upload-core/src/main/java/com/palantir/spark/shuffle/async/s3/reader/FallbackToS3ShuffleIterator.java

Lines changed: 2 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,6 @@
2929
import org.apache.spark.io.CompressionCodec;
3030
import org.apache.spark.palantir.shuffle.async.ShuffleDriverEndpointRef;
3131
import org.apache.spark.serializer.SerializerManager;
32-
import org.apache.spark.shuffle.FetchFailedException;
3332
import org.apache.spark.shuffle.api.ShuffleBlockInfo;
3433
import org.apache.spark.shuffle.api.ShuffleBlockInputStream;
3534
import org.apache.spark.storage.BlockId;
@@ -94,16 +93,8 @@ public ShuffleBlockInputStream next() {
9493
BlockId resultBlock = resultStream.getBlockId();
9594
ShuffleBlockId resolvedBlockId = convertBlockId(resultBlock);
9695
remainingAttemptsByBlock.remove(resolvedBlockId);
97-
} catch (Throwable e) {
98-
if (e instanceof FetchFailedException) {
99-
LOG.warn(
100-
"Failed to fetch block the regular way, due to a fetch failed"
101-
+ " exception. Fetching from the hadoop file system instead.",
102-
e);
103-
ShuffleBlockInfo blockInfo =
104-
remainingAttemptsByBlock.get(((FetchFailedException) e).getShuffleBlockId());
105-
driverEndpointRef.blacklistExecutor(blockInfo.getShuffleLocation().get());
106-
}
96+
} catch (RuntimeException | Error e) {
97+
10798
throw e;
10899
}
109100
} else if (!s3FetcherIterator.isInitialized()) {

async-shuffle-upload-data-generator/src/main/java/com/palantir/spark/shuffle/async/s3/client/AsyncShuffleBenchmark.java

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -127,18 +127,14 @@ public double runRead() throws ExecutionException, InterruptedException {
127127
for (int j = 0; j < numPartitions; j++) {
128128
int reduceId = j;
129129
downloadFutures.add(downloadService.submit(() -> {
130-
ListenableFuture<InputStream> future = client.getBlockData(
131-
SHUFFLE_ID,
132-
mapId,
133-
reduceId,
134-
ATTEMPT_ID);
130+
ListenableFuture<InputStream> future = client.getBlockData(SHUFFLE_ID, mapId, reduceId, ATTEMPT_ID);
135131
byte[] bytes = new byte[READ_BUFFER_SIZE];
136132
try (InputStream stream = future.get()) {
137133
while (stream.read(bytes) != -1) {
138134
// do nothing
139135
}
140136
return true;
141-
} catch (Exception e) {
137+
} catch (ExecutionException | IOException | InterruptedException | RuntimeException e) {
142138
throw new RuntimeException(e);
143139
}
144140
}));

build.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ buildscript {
2424
classpath 'com.netflix.nebula:gradle-info-plugin:5.2.0'
2525
classpath 'com.netflix.nebula:nebula-publishing-plugin:14.1.1'
2626
classpath 'com.palantir.gradle.consistentversions:gradle-consistent-versions:1.12.4'
27-
classpath 'com.palantir.baseline:gradle-baseline-java:2.35.2'
27+
classpath 'com.palantir.baseline:gradle-baseline-java:2.40.1'
2828
classpath 'com.palantir.gradle.gitversion:gradle-git-version:0.12.2'
2929
classpath 'gradle.plugin.org.inferred:gradle-processors:3.1.0'
3030
classpath 'com.palantir.sls-packaging:gradle-sls-packaging:4.3.3'

0 commit comments

Comments
 (0)