Summary

      The atlassian-jira.log is flooded with WARN like these:

      2013-07-26 22:50:05,585 http-bio-8604-exec-22 WARN admin 1370x16x1 18zayv8 0:0:0:0:0:0:0:1 /rest/api/1.0/menus/greenhopper_menu [service.rapid.view.RapidViewDao] could not find entity of type interface com.atlassian.greenhopper.service.rapid.view.RapidViewAO with key 2
      2013-07-26 22:50:05,588 http-bio-8604-exec-22 WARN admin 1370x16x1 18zayv8 0:0:0:0:0:0:0:1 /rest/api/1.0/menus/greenhopper_menu [service.rapid.view.RapidViewDao] could not find entity of type interface com.atlassian.greenhopper.service.rapid.view.RapidViewAO with key 1
      
      Diagnosis

      Even when a rapid board was deleted, the id is somehow being highlighted in the atlassian-jira.log, when Agile is accessed. This happens only once; as soon as JIRA is started.

      Implication

      These WARN are harmless, but it will populate the log file with id of the boards that has been deleted since the use of GreenHopper.

            [JSWSERVER-9591] WARN in logs regarding missing entity

            MattS added a comment - - edited

            Indeed, why not fix the bug instead of reducing the log level? Or at least change the resolution to Incomplete or some such.

            MattS added a comment - - edited Indeed, why not fix the bug instead of reducing the log level? Or at least change the resolution to Incomplete or some such.

            Why not an actual fix by purging invalid history items when a board is removed?
            In that case the warning would make sense since this would mean purge has failed.

            Guillaume Perrot added a comment - Why not an actual fix by purging invalid history items when a board is removed? In that case the warning would make sense since this would mean purge has failed.

            There is a limit in the storage of "history items", which by default is set to 50 items. Boards which have been removed will inevitably find their way out of the history items list per user, as the user will probably go on to view other boards more recently.

            The reason the logging level was bumped down to DEBUG, instead of being removed entirely, is because the class responsible is a generic data access object, used for all manner of database record retrieval (not just RapidViewAO records). We felt it was useful to keep it in place.

            Apologies for taking a while with this fix, but the good news is that it is done. You can expect the release to be available within a couple of weeks.

            Regards,
            JIRA Agile Team

            Michael Tokar added a comment - There is a limit in the storage of "history items", which by default is set to 50 items. Boards which have been removed will inevitably find their way out of the history items list per user, as the user will probably go on to view other boards more recently. The reason the logging level was bumped down to DEBUG, instead of being removed entirely, is because the class responsible is a generic data access object, used for all manner of database record retrieval (not just RapidViewAO records). We felt it was useful to keep it in place. Apologies for taking a while with this fix, but the good news is that it is done. You can expect the release to be available within a couple of weeks. Regards, JIRA Agile Team

            My initial response is outrage, shortly followed by "I guess we've all been there."

            Andrew Freer added a comment - My initial response is outrage, shortly followed by "I guess we've all been there."

            Fixed by reducing the logging level down to DEBUG.

            Michael Tokar added a comment - Fixed by reducing the logging level down to DEBUG .

            Guillaume Perrot added a comment - - edited

            Andrew Freer, you made my day!
            I also get this error a lot and deleting dead references in userhistoryitem seems to work.

            Guillaume Perrot added a comment - - edited Andrew Freer, you made my day! I also get this error a lot and deleting dead references in userhistoryitem seems to work.

            I tracked down the source of the bug, and a workaround. We like to keep our logs clean so we can just look for the anomalies.

            It looks like the issue is fundamentally in the Agile dropdown menu, which is populated by /rest/api/1.0/menus/greenhopper_menu. Ultimately, this is supported via a common JIRA component, UserHistoryManager, which GreenHopper utilizes. The relevant JIRA database table is userhistoryitem:

            SELECT * from userhistoryitem WHERE entitytype = "RapidView"

            When GreenHopper/Agile Scrum Boards are deleted, they are removed from the relevant ao_60db71_rapidview table, but not from the userhistoryitem table. So the error is related to the Agile dropdown menu looking for Scrum Boards which no longer exist. You can find this with the following query:

            SELECT * from userhistoryitem WHERE entitytype = "RapidView" AND NOT entityid in (SELECT DISTINCT id from ao_60db71_rapidview)

            The proper fix, I assume, involves a GreenHopper patch that properly clears the userhistoryitem table when a rapidview / Scrum Board is deleted. You could accomplish this via a database constraint of some sort (cascade delete).

            The workaround is to delete the above invalid items (above query) from userhistoryitem. You can get as fancy as you want here.

            Ultimately, the warning is rather harmless, although it does obscure true errors in the logs.

            Andrew Freer added a comment - I tracked down the source of the bug, and a workaround. We like to keep our logs clean so we can just look for the anomalies. It looks like the issue is fundamentally in the Agile dropdown menu, which is populated by /rest/api/1.0/menus/greenhopper_menu. Ultimately, this is supported via a common JIRA component, UserHistoryManager, which GreenHopper utilizes. The relevant JIRA database table is userhistoryitem: SELECT * from userhistoryitem WHERE entitytype = "RapidView" When GreenHopper/Agile Scrum Boards are deleted, they are removed from the relevant ao_60db71_rapidview table, but not from the userhistoryitem table. So the error is related to the Agile dropdown menu looking for Scrum Boards which no longer exist. You can find this with the following query: SELECT * from userhistoryitem WHERE entitytype = "RapidView" AND NOT entityid in (SELECT DISTINCT id from ao_60db71_rapidview) The proper fix, I assume, involves a GreenHopper patch that properly clears the userhistoryitem table when a rapidview / Scrum Board is deleted. You could accomplish this via a database constraint of some sort (cascade delete). The workaround is to delete the above invalid items (above query) from userhistoryitem. You can get as fancy as you want here. Ultimately, the warning is rather harmless, although it does obscure true errors in the logs.

            I have been seeing this WARN in my logs since January 2013, when I was running v6.1.1.

            I currently have over 3600 log entries - they happen continiously, not "only once, as soon as JIRA is started".

            Mark Symons added a comment - I have been seeing this WARN in my logs since January 2013, when I was running v6.1.1. I currently have over 3600 log entries - they happen continiously, not "only once, as soon as JIRA is started".

              mtokar Michael Tokar
              cchan Chung Park Chan
              Affected customers:
              28 This affects my team
              Watchers:
              30 Start watching this issue

                Created:
                Updated:
                Resolved: