Examples of openReader()


Examples of org.apache.accumulo.core.file.FileOperations.openReader()

        FileSKVIterator reader;
       
        AccumuloConfiguration tableConf = AccumuloConfiguration.getTableConfiguration(HdfsZooInstance.getInstance().getInstanceID(), extent.getTableId()
            .toString());
       
        reader = fileFactory.openReader(mapFile, false, fs, conf, tableConf);
       
        readers.add(reader);
        iters.add(new ProblemReportingIterator(extent.getTableId().toString(), mapFile, false, reader));
       
      } catch (Throwable e) {
View Full Code Here

Examples of org.apache.accumulo.core.file.FileOperations.openReader()

      mfw = null; // set this to null so we do not try to close it again in finally if the close fails
      mfwTmp.close(); // if the close fails it will cause the compaction to fail
     
      // Verify the file, since hadoop 0.20.2 sometimes lies about the success of close()
      try {
        FileSKVIterator openReader = fileFactory.openReader(compactTmpName, false, fs, conf, tableConf);
        openReader.close();
      } catch (IOException ex) {
        log.error("Verification of successful major compaction fails!!!", ex);
        throw ex;
      }
View Full Code Here

Examples of org.apache.accumulo.core.file.FileOperations.openReader()

       
        mfw.close();
       
        // Verify the file, since hadoop 0.20.2 sometimes lies about the success of close()
        try {
          FileSKVIterator openReader = fileOps.openReader(dirname, false, fs, conf, tableConf);
          openReader.close();
        } catch (IOException ex) {
          log.error("Verification of successful file write fails!!!", ex);
          throw ex;
        }
View Full Code Here

Examples of org.apache.accumulo.core.file.FileOperations.openReader()

   
    Map<String,Pair<Key,Key>> falks = new HashMap<String,Pair<Key,Key>>();
   
    for (Entry<String,DataFileValue> entry : files.entrySet()) {
      String file = entry.getKey();
      FileSKVIterator openReader = fileFactory.openReader(file, true, fs, conf, acuTableConf);
      try {
        Key first = openReader.getFirstKey();
        Key last = openReader.getLastKey();
        falks.put(file, new Pair<Key,Key>(first, last));
      } finally {
View Full Code Here

Examples of org.hibernate.search.reader.ReaderProvider.openReader()

    DirectoryProvider[] directoryProviders = searchFactoryImplementor.getDirectoryProviders( clazz );
    ReaderProvider readerProvider = searchFactoryImplementor.getReaderProvider();

    int count = 0;
    for ( DirectoryProvider directoryProvider : directoryProviders ) {
      IndexReader reader = readerProvider.openReader( directoryProvider );
      IndexSearcher searcher = new IndexSearcher( reader );
      BooleanQuery boolQuery = new BooleanQuery();
      boolQuery.add( new MatchAllDocsQuery(), BooleanClause.Occur.MUST );
      boolQuery.add(
          new TermQuery( new Term( ProjectionConstants.OBJECT_CLASS, entity ) ), BooleanClause.Occur.MUST
View Full Code Here

Examples of org.hibernate.search.reader.ReaderProvider.openReader()

      // Here's how to get a reader from a FullTextSession
      SearchFactory searchFactory = s.getSearchFactory();
      DirectoryProvider provider = searchFactory.getDirectoryProviders(ElectricalProperties.class)[0];
      ReaderProvider readerProvider = searchFactory.getReaderProvider();
      IndexReader reader = readerProvider.openReader(provider);

      /**
       * Since there are so many combinations of results here, we are only going
       * to assert a few. - J.G.
       */
 
View Full Code Here

Examples of org.hibernate.search.reader.ReaderProvider.openReader()

      // Here's how to get a reader from a FullTextSession
      SearchFactory searchFactory = s.getSearchFactory();
      DirectoryProvider provider = searchFactory.getDirectoryProviders(Employee.class)[0];
      ReaderProvider readerProvider = searchFactory.getReaderProvider();
      IndexReader reader = readerProvider.openReader(provider);

      TermPositionVector vector = (TermPositionVector) reader.getTermFreqVector(0, "dept");
      assertNull("should not find a term position vector", vector);

      //cleanup
View Full Code Here

Examples of org.hibernate.search.reader.ReaderProvider.openReader()

    // Search and the record via Lucene directly
    tx = s.beginTransaction();

    DirectoryProvider directoryProvider = s.getSearchFactory().getDirectoryProviders( SpecialPerson.class )[0];
    ReaderProvider readerProvider = s.getSearchFactory().getReaderProvider();
    IndexReader reader = readerProvider.openReader( directoryProvider );
    IndexSearcher searcher = new IndexSearcher( reader );

    try {
      // we have to test using Lucene directly since query loaders will ignore hits for which there is no
      // database entry
View Full Code Here

Examples of org.hibernate.search.reader.ReaderProvider.openReader()

    // Search and the record via Lucene directly
    tx = s.beginTransaction();

    DirectoryProvider directoryProvider = s.getSearchFactory().getDirectoryProviders( SpecialPerson.class )[0];
    ReaderProvider readerProvider = s.getSearchFactory().getReaderProvider();
    IndexReader reader = readerProvider.openReader( directoryProvider );
    IndexSearcher searcher = new IndexSearcher( reader );

    try {
      // we have to test using Lucene directly since query loaders will ignore hits for which there is no
      // database entry
View Full Code Here

Examples of org.hibernate.search.reader.ReaderProvider.openReader()

    // Search and the record via Lucene directly
    tx = s.beginTransaction();

    DirectoryProvider directoryProvider = s.getSearchFactory().getDirectoryProviders( SpecialPerson.class )[0];
    ReaderProvider readerProvider = s.getSearchFactory().getReaderProvider();
    IndexReader reader = readerProvider.openReader( directoryProvider );
    IndexSearcher searcher = new IndexSearcher( reader );

    try {
      // we have to test using Lucene directly since query loaders will ignore hits for which there is no
      // database entry
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.