Package io.druid.segment

Examples of io.druid.segment.QueryableIndexSegment


  public Segment getSegment(DataSegment segment) throws SegmentLoadingException
  {
    File segmentFiles = getSegmentFiles(segment);
    final QueryableIndex index = factory.factorize(segmentFiles);

    return new QueryableIndexSegment(segment.getIdentifier(), index);
  }
View Full Code Here


            continue;
          }

          hydrants.add(
              new FireHydrant(
                  new QueryableIndexSegment(
                      DataSegment.makeDataSegmentIdentifier(
                          schema.getDataSource(),
                          sinkInterval.getStart(),
                          sinkInterval.getEnd(),
                          versioningPolicy.getVersion(sinkInterval),
View Full Code Here

              new File(computePersistDir(schema, interval), String.valueOf(indexToPersist.getCount()))
          );
        }

        indexToPersist.swapSegment(
            new QueryableIndexSegment(
                indexToPersist.getSegment().getIdentifier(),
                IndexIO.loadIndex(persistedFile)
            )
        );
        return numRows;
View Full Code Here

        new Object[][]{
            {
                new IncrementalIndexSegment(rtIndex, null)
            },
            {
                new QueryableIndexSegment(null, mMappedTestIndex)
            },
            {
                new QueryableIndexSegment(null, mergedRealtimeIndex)
            }
        }
    );
  }
View Full Code Here

        new Object[][]{
            {
                new IncrementalIndexSegment(rtIndex, null)
            },
            {
                new QueryableIndexSegment(null, mMappedTestIndex)
            },
            {
                new QueryableIndexSegment(null, mergedRealtimeIndex)
            }
        }
    );
  }
View Full Code Here

        new Object[][]{
            {
                makeQueryRunner(factory, new IncrementalIndexSegment(rtIndex, segmentId))
            },
            {
                makeQueryRunner(factory, new QueryableIndexSegment(segmentId, mMappedTestIndex))
            },
            {
                makeQueryRunner(factory, new QueryableIndexSegment(segmentId, mergedRealtimeIndex))
            },
            {
                makeQueryRunner(factory, new IncrementalIndexSegment(rtIndexOffheap, segmentId))
            }
        }
View Full Code Here

        new Object[][]{
            {
                makeUnionQueryRunner(factory, new IncrementalIndexSegment(rtIndex, segmentId))
            },
            {
                makeUnionQueryRunner(factory, new QueryableIndexSegment(segmentId, mMappedTestIndex))
            },
            {
                makeUnionQueryRunner(factory, new QueryableIndexSegment(segmentId, mergedRealtimeIndex))
            },
            {
                makeUnionQueryRunner(factory, new IncrementalIndexSegment(rtIndexOffheap, segmentId))
            }
        }
View Full Code Here

      QueryRunnerFactory factory
  )
  {
    return QueryRunnerTestHelper.makeQueryRunner(
        factory,
        new QueryableIndexSegment(QueryRunnerTestHelper.segmentId, TestIndex.getMMappedTestIndex())
    );
  }
View Full Code Here

  @Test
  public void testMappedWorks() throws Exception
  {
    final List<SegmentAnalysis> results = getSegmentAnalysises(
        new QueryableIndexSegment("test_1", TestIndex.getMMappedTestIndex())
    );

    Assert.assertEquals(1, results.size());

    final SegmentAnalysis analysis = results.get(0);
View Full Code Here

    );
    testCaseMap.put(
        TestCases.mMappedTestIndex,
        QueryRunnerTestHelper.makeQueryRunner(
            factory,
            new QueryableIndexSegment(segmentId, TestIndex.getMMappedTestIndex())
        )
    );
    testCaseMap.put(
        TestCases.mergedRealtimeIndex,
        QueryRunnerTestHelper.makeQueryRunner(
            factory,
            new QueryableIndexSegment(segmentId, TestIndex.mergedRealtimeIndex())
        )
    );
    testCaseMap.put(
        TestCases.rtIndexOffheap,
        QueryRunnerTestHelper.makeQueryRunner(
View Full Code Here

TOP

Related Classes of io.druid.segment.QueryableIndexSegment

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.