MAX_DOCS_PER_BUILDER = UnitUtils.parseInt(ApplicationSetup.getProperty("indexing.max.docs.per.builder", "0")); maxMemory = UnitUtils.parseLong(ApplicationSetup.getProperty("indexing.singlepass.max.postings.memory", "0")); final boolean boundaryDocsEnabled = BUILDER_BOUNDARY_DOCUMENTS.size() > 0; final int collections_length = collections.length;
@Test public void testDouble() { assertEquals(1000, UnitUtils.parseDouble("1000"), 0.0d); assertEquals(1000, UnitUtils.parseDouble("1K"), 0.0d); assertEquals(1000, UnitUtils.parseDouble("1K"), 0.0d); }
@Test public void testFloat() { assertEquals(1000, UnitUtils.parseFloat("1000"), 0.0f); assertEquals(1000, UnitUtils.parseFloat("1K"), 0.0f); assertEquals(1024, UnitUtils.parseFloat("1Ki"), 0.0f); }
MEMORY_THRESHOLD_SINGLEPASS = UnitUtils.parseInt(getProperty("memory.reserved", System.getProperty("sun.arch.data.model", "32").equals("64") ? "200Mi" : "50Mi")); DOCS_CHECK_SINGLEPASS = Integer.parseInt(getProperty("docs.check", "20"));
MEMORY_THRESHOLD_SINGLEPASS = UnitUtils.parseInt(getProperty("memory.reserved", System.getProperty("sun.arch.data.model", "32").equals("64") ? "200Mi" : "50Mi")); DOCS_CHECK_SINGLEPASS = Integer.parseInt(getProperty("docs.check", "20"));
/** * constructor * @param i */ public BlockInverted2DirectIndexBuilder(IndexOnDisk i) { super(i); directIndexClass = BitPostingIndex.class.getName(); directIndexInputStreamClass = BitPostingIndexInputStream.class.getName(); basicDirectIndexPostingIteratorClass = BlockIterablePosting.class.getName(); fieldDirectIndexPostingIteratorClass = BlockFieldIterablePosting.class.getName(); processTokens = UnitUtils.parseLong(ApplicationSetup.getProperty("inverted2direct.processtokens", "10000000")); }