Uploaded image for project: 'Jira Data Center'
  1. Jira Data Center
  2. JRASERVER-72235

Jira Lucene Reindexing message is misleading.

    XMLWordPrintable

Details

    • 9
    • We collect Jira feedback from various sources, and we evaluate what we've collected when planning our product roadmap. To understand how this piece of feedback will be reviewed, see our Implementation of New Features Policy.

    Description

      Issue Summary

      The message that is shown if there are any errors with Indexing is misleading and causes concern.

      2018-11-13 10:00:27,704 IssueIndexer:thread-31 INFO admin 1139x124894x1 1s 127.0.0.1 /secure/admin/IndexReIndex.jspa [c.a.j.w.a.admin.index.IndexAdminImpl] Re-indexing is 98% complete. Current index: Issue
      2018-11-13 10:01:07,436 JiraTaskExectionThread-1 ERROR admin 1139x124894x1 1s 127.0.0.1 /secure/admin/IndexReIndex.jspa [c.a.j.util.index.CompositeIndexLifecycleManager] Reindex All FAILED. Indexer: DefaultIndexManager: paths: [/jira/caches/indexes/comments, /jira/caches/indexes/issues, /jira/caches/indexes/changes, /jira/caches/indexes/worklogs, /jira/caches/indexes/plugins/jira-git-files, /jira/caches/indexes/plugins/jira-git-pullrequestinfos, /jira/caches/indexes/plugins/jira-git-revisions]
      com.atlassian.jira.index.IndexingFailureException: Indexing completed with 2 errors
      

      Specifically the two sections:

      Reindex All FAILED
      ........
      Indexing completed with 2 errors

      The message Reindex All FAILED makes users worried and leads them to believe that the whole indexing process has not been successful. The actuality is that the indexing process has completed but ran into some errors along the way, hence (Indexing completed with 2 errors).

      We also note this in our documentation:
      From Troubleshoot a Reindex failure in Jira

      When JIRA applications perform a reindex, errors can happen throughout that process. If an error occurs, exceptions will typically be thrown for individual issues. This means the index can fail for a single issue; however, it does not fail for the entire instance because one issue is causing problems. If the above exception and stack trace is displayed after indexing has finished, it means one or more of the issues failed during the process; however, the entire process did not. It's highly likely that part of the instance has been successfully indexed.

      Expected Results

      Change this to(Or something similar)

      2018-11-13 10:01:07,436 JiraTaskExectionThread-1 ERROR admin 1139x124894x1 1s 127.0.0.1 /secure/admin/IndexReIndex.jspa [c.a.j.util.index.CompositeIndexLifecycleManager] Reindex All complete but ran into [x] errors Indexer: DefaultIndexManager: paths: [/jira/caches/indexes/comments, /jira/caches/indexes/issues, /jira/caches/indexes/changes, /jira/caches/indexes/worklogs, /jira/caches/indexes/plugins/jira-git-files, /jira/caches/indexes/plugins/jira-git-pullrequestinfos, /jira/caches/indexes/plugins/jira-git-revisions] com.atlassian.jira.index.IndexingFailureException: Indexing completed with 2 errors
      •  Removing the Reindex All Failed
        • Changing this to Reindex Complete but ran into [X] errors
        • Where X is the number of errors if possible 

      Actual Results

      The below exception is thrown in the atlassian-jira.log file:

      2018-11-13 10:01:07,436 JiraTaskExectionThread-1 ERROR admin 1139x124894x1 1s 127.0.0.1 /secure/admin/IndexReIndex.jspa [c.a.j.util.index.CompositeIndexLifecycleManager] Reindex All FAILED. Indexer: DefaultIndexManager: paths: [/jira/caches/indexes/comments, /jira/caches/indexes/issues, /jira/caches/indexes/changes, /jira/caches/indexes/worklogs, /jira/caches/indexes/plugins/jira-git-files, /jira/caches/indexes/plugins/jira-git-pullrequestinfos, /jira/caches/indexes/plugins/jira-git-revisions] com.atlassian.jira.index.IndexingFailureException: Indexing completed with 2 errors
      

      Steps to reproduce

      • Start a Full Reindex in Jira
      • Encounter an error during the indexing process
      • This message will be shown at the end. 

      Workaround

      Currently, there is no known workaround for this behavior. A workaround will be added here when available

      Fix

      Logging corrections have been made to improve message clarity.
      From now on, any non-critical error during reindexing will add the following entry to the logs:

      Reindexing encountered an error for one of the indexers. Reindex all continues. Error for indexer: ...

      In some cases, a critical error may occur resulting in the following message:

      Reindex All - fatal error. Indexer: ...

      The whole reindexing process can end with one of two messages depending on whether there are any errors:

      Reindex All COMPLETED without any errors. Total time: [time] ms. Reindex run: ...

      Or

      Indexing completed with X errors

       

      Some changes have also been made to the UI layer. If any error is encountered during the process, the following message will be displayed to the user:

      "The re-index was completed but encountered some errors. Please refer to Jira logs for more details."

      Attachments

        Issue Links

          Activity

            People

              3e387befff2c Patryk Latkowski
              clevine Chris Levine
              Votes:
              10 Vote for this issue
              Watchers:
              18 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: