EdColeman commented on code in PR #3508:
URL: https://github.com/apache/accumulo/pull/3508#discussion_r1240325907
##########
test/src/main/java/org/apache/accumulo/test/functional/MemoryStarvedScanIT.java:
##########
@@ -162,13 +173,11 @@ private void consumeServerMemory(BatchScanner scanner) {
assertTrue(iter.hasNext());
}
- static void freeServerMemory(AccumuloClient client, String table) throws
Exception {
- try (Scanner scanner = client.createScanner(table)) {
- scanner.addScanIterator(new IteratorSetting(11,
MemoryFreeingIterator.class, Map.of()));
- @SuppressWarnings("unused")
- Iterator<Entry<Key,Value>> iter = scanner.iterator(); // init'ing the
iterator should be
- // enough to free
the memory
- }
+ static void freeServerMemory(AccumuloClient client) throws Exception {
+ // Instantiating this class on the TabletServer will free the memory as it
+ // frees the buffers created by the MemoryConsumingIterator in its
constructor.
+
client.instanceOperations().testClassLoad(MemoryFreeingIterator.class.getName(),
+ WrappingIterator.class.getCanonicalName());
Review Comment:
Addressed in 55265e8199
--
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]