Dashboard fails to load with error 500 in Jira

お困りですか?

アトラシアン コミュニティをご利用ください。

コミュニティに質問

プラットフォームについて: Server および Data Center のみ。この記事は、Server および Data Center プラットフォームのアトラシアン製品にのみ適用されます。

Support for Server* products ended on February 15th 2024. If you are running a Server product, you can visit the Atlassian Server end of support announcement to review your migration options.

*Fisheye および Crucible は除く

Jira Cloud

The issue might be observed in the Jira Cloud Environment as well. Please contact Atlassian Support for further diagnosis and fix.


要約

Trying to load a dashboard page presents an error 500 page.

Expanding the details of the error page or scanning the logs, an IndexOutOfBoundsException error is present.


throws one of the following exceptions:

java.lang.IndexOutOfBoundsException: Index: 2, Size: 2
at java.util.ArrayList.rangeCheck(ArrayList.java:657) [?:1.8.0_202]
at java.util.ArrayList.get(ArrayList.java:433) [?:1.8.0_202]
at com.atlassian.jira.portal.DefaultPortalPageManager.getPortletConfigurations(DefaultPortalPageManager.java:288) [classes/:?]
at com.atlassian.jira.dashboard.JiraDashboardStateStoreManager.getDashboardState(JiraDashboardStateStoreManager.java:166) [classes/:?]
at com.atlassian.jira.dashboard.JiraDashboardStateStoreManager.retrieve(JiraDashboardStateStoreManager.java:143) [classes/:?]

java.lang.IndexOutOfBoundsException: Index: 1, Size: 1
	at java.util.ArrayList.RangeCheck(ArrayList.java:546)
	at java.util.ArrayList.get(ArrayList.java:321)
	at com.atlassian.jira.portal.AbstractPortalPageImpl$ConfigInfo.putInColumn(AbstractPortalPageImpl.java:365)
	at com.atlassian.jira.portal.AbstractPortalPageImpl$ConfigInfo.setPortletConfigurations(AbstractPortalPageImpl.java:291)
	at com.atlassian.jira.portal.AbstractPortalPageImpl.setPortletConfigurations(AbstractPortalPageImpl.java:162)
	at com.atlassian.jira.dashboard.JiraDashboardStateStoreManager$2.get(JiraDashboardStateStoreManager.java:89)


環境

All versions of Jira Core 7.x and later


診断

Apart from the error 500, either of the following errors can show up in the atlassian-jira.log located under <jira home>/log/ folder:

Evidence from the logs

[c.a.j.web.servlet.InternalServerErrorServlet] {errorId=da24ad8b-809a-4457-9015-6b13070603a1, interpretedMsg=, cause=java.lang.IndexOutOfBoundsException: Index: 2, Size: 2, stacktrace=java.lang.IndexOutOfBoundsException: Index: 2, Size: 2
[c.a.j.web.servlet.InternalServerErrorServlet] {errorId=da24ad8b-809a-4457-9015-6b13070603a1, interpretedMsg=, cause=java.lang.IndexOutOfBoundsException: Index: 1, Size: 1, stacktrace=java.lang.IndexOutOfBoundsException: Index: 1, Size: 1

Evidence from the database

You may also find the affected Dashboards and others by executing queries similar to these examples below:

MySQL example
select PC.ID as gadget_id,
       PP.ID as dashboard_id
from portletconfiguration PC,
     portalpage PP
where PC.PORTALPAGE = PP.ID AND
      column_number > length(layout) -1;
SQL Server example
select PC.ID as gadget_id,
       PP.ID as dashboard_id
from portletconfiguration PC,
     portalpage PP
where PC.PORTALPAGE = PP.ID AND
      column_number > len(layout) -1;


原因

Somehow, the Dashboard was configured to have only 2 columns and there's a Gadget configured to be in the 3rd column — or the Dashboard's 1 column and the Gadget's in column 2 or 3.


ソリューション

データベースの変更を行う場合は必ず事前にバックアップを取得してください。可能な場合は、まずステージング サーバーで SQL コマンドの変更、挿入、更新、または削除を行うようにします。

Update the database directly to set the Dashboard layout to 3 columns:

update portalpage set layout='AAA' where id=<dashboard_id>;

You can replace the <dashboad_id> by each result from the diagnostic query or by the "selectPageId" present in the URL: Dashboard.jspa?selectPageId=...

You should be able to access the Dashboards then and rearrange the gadgets and the layout as you see fit.



最終更新日 2023 年 9 月 27 日

この内容はお役に立ちましたか?

はい
いいえ
この記事についてのフィードバックを送信する
Powered by Confluence and Scroll Viewport.