bbotella commented on code in PR #3752:
URL: https://github.com/apache/cassandra/pull/3752#discussion_r1892355033
##########
src/java/org/apache/cassandra/service/snapshot/SnapshotManagerMBean.java:
##########
@@ -55,7 +55,17 @@ public interface SnapshotManagerMBean
void clearSnapshot(String tag, Map<String, Object> options, String...
keyspaceNames) throws IOException;
/**
- * Get the details of all the snapshots
+ * Get the details of all the snapshots. Options might be:
+ *
+ * <pre>
+ * no_ttl: "true" or "false"
+ * include_ephemeral: "true" or "false"
+ * keyspace: name of keyspace to get snapshots of
Review Comment:
From the server side logic, I see that keyspace, table and snapshot can be
null. Should we document here what's the behavior on those cases?
##########
test/distributed/org/apache/cassandra/distributed/test/SnapshotsTest.java:
##########
@@ -469,4 +526,13 @@ private void exoticSnapshotNamesInternal(String[]
exoticSnapshotNames)
waitForSnapshot(tag, true, true);
}
}
+
+ private List<String> extractSnapshots(String listSnapshotsStdOut)
+ {
+ return Arrays.stream(listSnapshotsStdOut.split("\n"))
+ .filter(line -> !line.isEmpty())
+ .filter(line -> !line.startsWith("Snapshot Details:") &&
!line.startsWith("There are no snapshots"))
Review Comment:
Curious: Is there any benefit from adding two filters with a `&&` operator
as opposed to four single filters on this stream?
--
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]