do not create a new ObjectMapper per entry
also read value with MappingIterator. This made reading 20-30 times faster. We can now read and index 100k-500k per second. The varianz might be due to LuDB slowness.
This commit is contained in:
@@ -91,7 +91,7 @@ public class PerformanceDb implements AutoCloseable {
|
||||
writer.write(entry);
|
||||
count++;
|
||||
|
||||
if (count == 10000) {
|
||||
if (count == 100000) {
|
||||
final long end = System.nanoTime();
|
||||
final double duration = (end - start) / 1_000_000.0;
|
||||
LOGGER.info("inserting the last " + count + " took " + duration + " ms; " + durationInManager
|
||||
|
||||
@@ -65,6 +65,7 @@ public class TagsToFile implements AutoCloseable, CollectionUtils {
|
||||
}
|
||||
} catch (final NullPointerException e) {
|
||||
// TODO @ahr ludb should handle unknown fields better
|
||||
e.printStackTrace();
|
||||
}
|
||||
|
||||
Collections.sort(result, PdbFileByTimeAsc.INSTANCE);
|
||||
|
||||
Reference in New Issue
Block a user