Solr
  1. Solr
  2. SOLR-3591 Startup error not reflected in Solr web view
  3. SOLR-3634

make CoreAdminHandler STATUS action report back info about core initialization failures

    Details

    • Type: Sub-task Sub-task
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 4.0-BETA, 6.0
    • Component/s: None
    • Labels:
      None

      Description

      see parent issue for context.

      • CoreContainer should keep a record of failures related to core initialization, keyed off of the core name
      • failures should be recorded for both solr.xml initialzation, as well as explicit CREATE/RELOAD requests that fail
      • record of failures should be tracked indefinitely until some valid core begins using that name
        • ie: actions which register a SolrCore with a name (RELOAD, CREATE, SWAP, ALIAS) should "reset" any existing failures associated with that name
      • failures should be available to clients via CoreAdminHandler STATUS actions
      1. SOLR-3634.patch
        23 kB
        Hoss Man
      2. SOLR-3634.patch
        15 kB
        Hoss Man

        Issue Links

          Activity

          Hide
          Hoss Man added a comment -

          quick patch with all the major functionality and some tests.

          lots of nocommits in here, basicly all falling into three categories:

          • refactoring - the changes to CoreContainer are all complete and relatively trivial, but involved renaming create/reload to doCreate/doReload which are wrapped in new stub methods that call them in try blocks where the "finally" does all the real work. This was just for convinience to keep the patch easy to read w/o a lot of re-indenting, and these methods should be refactored away before committing.
          • more tests - the key stuff is already covered in the patch, and i did manual testing with CoreAdminHandler, but i definitely want more tests before committing.
          • "Directory not closed" - something about this test is causing MockDirWrapper to complain it's never closed - buti don't think this is a bug in the new code or the test. I suspect we have an existing bug where SolrCore initialization failures after the Directory has already been opened aren't closing the Directory – so we should get to hte bottom of that (probably in a new issue if i'm correct)
          Show
          Hoss Man added a comment - quick patch with all the major functionality and some tests. lots of nocommits in here, basicly all falling into three categories: refactoring - the changes to CoreContainer are all complete and relatively trivial, but involved renaming create/reload to doCreate/doReload which are wrapped in new stub methods that call them in try blocks where the "finally" does all the real work. This was just for convinience to keep the patch easy to read w/o a lot of re-indenting, and these methods should be refactored away before committing. more tests - the key stuff is already covered in the patch, and i did manual testing with CoreAdminHandler, but i definitely want more tests before committing. "Directory not closed" - something about this test is causing MockDirWrapper to complain it's never closed - buti don't think this is a bug in the new code or the test. I suspect we have an existing bug where SolrCore initialization failures after the Directory has already been opened aren't closing the Directory – so we should get to hte bottom of that (probably in a new issue if i'm correct)
          Hide
          Hoss Man added a comment -

          Updated patch...

          • lots of new tests, this covers all the cases i can think of except for what we can't test because of SOLR-3665
          • added detailed javadocs for the new public CoreContainer.getCoreInitFailures method
          • the directory not closed problem vanished on it's own – i suspect SOLR-3656 fixed it.

          There are still some nocommits in this patch because of the previously mentioned refactoring (left as is so the patch is readable – all the refactoring will really do is indent a ton of code inside a try/catch)

          I think this is good to go, but i'd appreciate some feedback

          Show
          Hoss Man added a comment - Updated patch... lots of new tests, this covers all the cases i can think of except for what we can't test because of SOLR-3665 added detailed javadocs for the new public CoreContainer.getCoreInitFailures method the directory not closed problem vanished on it's own – i suspect SOLR-3656 fixed it. There are still some nocommits in this patch because of the previously mentioned refactoring (left as is so the patch is readable – all the refactoring will really do is indent a ton of code inside a try/catch) I think this is good to go, but i'd appreciate some feedback
          Hide
          Hoss Man added a comment -

          Committed revision 1366241. - trunk
          Committed revision 1366249. - trunk fix nocommit refactoring i forgot about
          Committed revision 1366254. - 4x

          Show
          Hoss Man added a comment - Committed revision 1366241. - trunk Committed revision 1366249. - trunk fix nocommit refactoring i forgot about Committed revision 1366254. - 4x
          Hide
          Hoss Man added a comment -

          @Ignore("SOLR-3634: some errors are localized and tests fail in non en, disabling temporarily")

          Committed revision 1366460. - trunk
          Committed revision 1366464. - 4x

          Show
          Hoss Man added a comment - @Ignore(" SOLR-3634 : some errors are localized and tests fail in non en, disabling temporarily") Committed revision 1366460. - trunk Committed revision 1366464. - 4x
          Hide
          Hoss Man added a comment -

          change test to work even on java7 where SAXParseException.getMessage() returns a localized msg even though that defeats the whole point of Throwable.getLocalizedMessage()

          Committed revision 1366568. - trunk
          Committed revision 1366569. - 4x

          Show
          Hoss Man added a comment - change test to work even on java7 where SAXParseException.getMessage() returns a localized msg even though that defeats the whole point of Throwable.getLocalizedMessage() Committed revision 1366568. - trunk Committed revision 1366569. - 4x

            People

            • Assignee:
              Hoss Man
              Reporter:
              Hoss Man
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Development