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

Atlassian Jira Diagnostics bundled plugin high memory usage




      Issue Summary

      DailyAlertAnalyticsJob is a part of Atlassian Diagnostics integration plugin.
      Its responsibility is to produce daily analytics summary on all alerts fired with Atlassian diagnostics framework.

      Its memory usage can get quite heavy with lots of alerts fired daily. Memory will be accumulated in Caesium-x-y thread

      Expected Results

      DailyAlertAnalyticsJob efficiently handles its memory footprint by properly streaming alerts instead of loading all into memory.

      Actual Results

      DailyAlertAnalyticsJob loads all alerts from a given day into memory causing high pressure on GC, eventually leading to OOMe on big instances.


      Option 1 - recommended

      Alerting thresholds are set by several application properties.
      Setting them high enough to produce less alerts per day is a viable workaround for the issue.

      Currently implemented alerting thresholds:

      Property Default value Explanation
      jira.diagnostics.thresholds.slow-query-millis 400 ms Alert for slow JQL query
      jira.diagnostics.thresholds.number-of-results 1000 Number of returned issues from a single JQL query
      jira.diagnostics.thresholds.query-complexity 1000 Lucene query complexity - number of claues the query is constructed of

      Setting these values high can reduce the number of alerts triggered daily.

      • These values can be modified either from the $JIRA_HOME/jira-config.properties. For example,
      • Or they can be modified using the following JVM parameters,

        Make sure there is no space between the equal sign in both methods.

      Option 2
 - recommended

      Retention period for alerts is 30 days by default. You can decrease database size by changing it to e.g. 1 day.

       In order to do that you can use the Jira property com.atlassian.jira.health.diagnostics.alerts.retention-period-days. To do this, open the jira-config.properties and add/edit the following metric:
       - com.atlassian.jira.health.diagnostics.alerts.retention-period-days: <number of days to retain Diagnostics Alerts> (It is 30 by default)

      Option 3

      You can temporary disable the plugin via UPM. However we do not recommend disabling it as problems with Diagnostics could be only a symptom of underlying root cause (it might be harder to track without Diagnostics plugin).


        Issue Links



              dwlizlo Dawid
              tzwierzchowski Tomasz Zwierzchowski
              24 Vote for this issue
              57 Start watching this issue