Uploaded image for project: 'Maven Indexer'
  1. Maven Indexer
  2. MINDEXER-63

NullPointerException at org.apache.maven.index.context.DefaultIndexingContext.acquireIndexSearcher

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Critical
    • Resolution: Auto Closed
    • 5.0.0
    • None
    • None
    • netbeans 7.3 dev builds.

    Description

      see issue http://netbeans.org/bugzilla/show_bug.cgi?id=219645

      for some reason (unknown to me yet) the index files cannot be deleted. The codebase then gets into bad state.

      possibly wrong code in DefaultIndexingContext:

      public synchronized void replace( Directory directory )
           throws IOException
        {
              final Date ts = IndexUtils.getTimestamp( directory );
              closeReaders();
              deleteIndexFiles( false );
              IndexUtils.copyDirectory( directory, indexDirectory );
              openAndWarmup();
              // reclaim the index as mine
              storeDescriptor();
              updateTimestamp( true, ts );
              optimize();
       }
      
      

      when deleteIndexFiles(0 fails, openAndWarmup() is not called. also closeReaders() ignores indexWriter..

      Attachments

        Activity

          People

            Unassigned Unassigned
            mkleint Milos Kleint
            Votes:
            1 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: