yifan-c commented on code in PR #108:
URL: https://github.com/apache/cassandra-sidecar/pull/108#discussion_r1534658620
##########
CHANGES.txt:
##########
@@ -82,4 +83,4 @@
* Add integration tests task (CASSANDRA-15031)
* Add support for SSL and bindable address (CASSANDRA-15030)
* Autogenerate API docs for sidecar (CASSANDRA-15028)
- * C* Management process (CASSANDRA-14395)
\ No newline at end of file
+ * C* Management process (CASSANDRA-14395)
Review Comment:
what is the change? new line?
##########
src/main/java/org/apache/cassandra/sidecar/restore/StorageClient.java:
##########
@@ -257,10 +271,14 @@ CompletableFuture<GetObjectResponse>
subscribeRateLimitedWrite(Path destinationP
}
catch (FileAlreadyExistsException fileAlreadyExistsException)
{
+ LOGGER.debug("Skipping download, file already exists. jobId={},
s3_object={}",
Review Comment:
remove `,`
##########
src/main/java/org/apache/cassandra/sidecar/restore/StorageClient.java:
##########
@@ -156,6 +159,8 @@ public CompletableFuture<File>
downloadObjectIfAbsent(RestoreSlice slice)
File object = objectPath.toFile();
if (object.exists())
{
+ LOGGER.debug("Skipping download, file already exists. jobId={},
s3_object={}",
Review Comment:
remove `,`
```suggestion
LOGGER.debug("Skipping download, file already exists. jobId={}
s3_object={}",
```
##########
src/main/java/org/apache/cassandra/sidecar/restore/RestoreSliceTask.java:
##########
@@ -274,20 +264,16 @@ private CompletableFuture<File>
downloadSlice(Promise<RestoreSlice> event)
}
LOGGER.info("Begin downloading restore slice. sliceKey={}",
slice.key());
- CompletableFuture<File> future = s3Client
- .downloadObjectIfAbsent(slice)
- .whenComplete((file, cause) -> {
- if (cause != null)
+ Future<File> future =
+
fromCompletionStage(s3Client.downloadObjectIfAbsent(slice)).onFailure(cause -> {
Review Comment:
`onFailure` on new line.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]