ORA-01461 error when using JIRA Agile with Oracle

お困りですか?

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

コミュニティに質問

症状

You get an error similar to the following when trying to use JIRA Agile with Oracle:

SQL Exception while executing the following:UPDATE propertytext SET propertyvalue=? WHERE ID=? (ORA-01461: can bind a LONG value only for insert into a LONG column
))
	at com.opensymphony.module.propertyset.ofbiz.OFBizPropertySet.setImpl(OFBizPropertySet.java:185)
	at com.opensymphony.module.propertyset.AbstractPropertySet.set(AbstractPropertySet.java:570)
	at com.opensymphony.module.propertyset.AbstractPropertySet.setText(AbstractPropertySet.java:380)
	at com.atlassian.jira.propertyset.JiraCachingPropertySet.setText(JiraCachingPropertySet.java:533)

原因

As mentioned in this page of JIRA's documentation, when using JIRA with Oracle, the Oracle 10g JDBC driver needs to have the SetBigStringTryClob property set to 'true' to store text of unlimited size in the database. If this property is not set, you will have problems modifying JIRA workflows and storing large (over 32k) text strings.

Furthermore, JIRA Agile stores configuration information, preferences, contexts, etc. in the PropertyText table. By default JIRA is configured to use a VARCHAR2 for this table and JIRA Agile needs a CLOB.

ソリューション

Here is the suggested way to proceed:

1. Follow the Upgrading to JIRA Safely procedure.
2. Before restarting, you will need to update your (JIRA Installation Directory)\atlassian-jira\WEB-INF\classes\entitydefs\entitymodel.xml
Existing code:

      <entity entity-name="OSPropertyText" table-name="propertytext" package-name="">
         <field name="id" type="numeric"/>
         <field name="value" col-name="propertyvalue" type="very-long"/>
         <prim-key field="id"/>
      </entity>

Change code to:

      <entity entity-name="OSPropertyText" table-name="propertytext" package-name="">
         <field name="id" type="numeric"/>
         <field name="value" col-name="propertyvalue" type="extremely-long"/>
         <prim-key field="id"/>
      </entity>

So basically once again,

  1. Backup via JIRA -> 'Administration' -> 'Import & Export' (Verify that you have your backup on your disk)
  2. Jira を停止します。
  3. Drop the existing JIRA database.
  4. Change the entitymodel.xml (the type needs to be changed from "very-long" to "extremely-long").
  5. Jira を再起動します。
  6. Restore your backup via JIRA -> 'Administration' -> 'Import & Export'

Additionally this should only affect JIRA Agile running on versions of JIRA before 4.0. JIRA 4.0 has corrected the column definitions by default so this problem should no longer occur.

最終更新日 2013 年 8 月 26 日

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

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