keith-turner commented on code in PR #3874:
URL: https://github.com/apache/accumulo/pull/3874#discussion_r1369261708
##########
core/src/main/java/org/apache/accumulo/core/file/blockfile/impl/CachableBlockFile.java:
##########
@@ -69,11 +66,10 @@ public static String pathToCacheId(Path p) {
public static class CachableBuilder {
String cacheId = null;
- IoeSupplier<InputStream> inputSupplier = null;
+ IoeSupplier<FSDataInputStream> inputSupplier = null;
Review Comment:
What was the reason for changing this type?
##########
core/src/main/java/org/apache/accumulo/core/conf/Property.java:
##########
@@ -589,11 +589,7 @@ public enum Property {
TSERV_COMPACTION_SERVICE_ROOT_PLANNER("tserver.compaction.major.service.root.planner",
DefaultCompactionPlanner.class.getName(), PropertyType.CLASSNAME,
"Compaction planner for root tablet service", "2.1.0"),
-
TSERV_COMPACTION_SERVICE_ROOT_RATE_LIMIT("tserver.compaction.major.service.root.rate.limit",
"0B",
- PropertyType.BYTES,
- "Maximum number of bytes to read or write per second over all major"
- + " compactions in this compaction service, or 0B for unlimited.",
- "2.1.0"),
+ // ELASTICITY_TODO: Deprecate TSERV_COMPACTION_SERVICE_ROOT_RATE_LIMIT in 3.x
Review Comment:
Is there an issue opened for this?
##########
core/src/main/java/org/apache/accumulo/core/summary/SummaryReader.java:
##########
@@ -177,7 +179,11 @@ private static SummaryReader load(CachableBlockFile.Reader
bcReader,
public static SummaryReader load(Configuration conf, RFileSource source,
String cacheId,
Predicate<SummarizerConfiguration> summarySelector, SummarizerFactory
factory,
CryptoService cryptoService) throws IOException {
- CachableBuilder cb = new CachableBuilder().input(source.getInputStream(),
cacheId)
+ InputStream input = source.getInputStream();
+ if (!(input instanceof FSDataInputStream)) {
+ throw new IllegalArgumentException("Input stream is not a
FSDataInputStream");
+ }
Review Comment:
If this code were omitted, then the cast would fail with an exception if its
not an instance of. Why not just let that fail?
--
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]