Fail during migrating CLOB type column with missing index in Oracle DB

Description

Summary

Environment

Tested

Very likely

Jira 7.7.0 (AO 1.5.0)

Any Jira using AO version > 0.28.5

Oracle 12c

Any Oracle supported version

Steps to Reproduce

  1. Start Jira

  2. Install Portfolio 2.13.1

  3. Stop Jira

  4. In database table AO_D9132D_SCENARIO_ISSUE_LABEL:

    1. Remove index from LABEL column

    2. Remove LABEL column

    3. Add LABEL column with CLOB type (don't add index)

  5. Start Jira

Expected Results

Jira runs successfully despite different column type.

Actual Results

Error can be seen in the log:

AO tries to change column type. This opration fails, because it tries to remove missing index in the middle of migration. Temporary column is left in the table that makes it impossible to repeat the process. Next and subsequent Jira starts will report error:

Workaround

While having both original and temporary columns created by AO you can finish migration manually by:

  1. Dropping original column. e.g.

  2. Renaming temporary column back to actual column

Notes

It can happen when migrating from Cloud to Server.
Code behind the problem: source

Environment

None

Testing Notes

Add notes...

Assignee

Unassigned

Reporter

Przemyslaw Czuj

Labels

None

Add-on Type

Server

Team

None

CC

None

Risk factor

None

QA Kickoff Status

None

QA Demo Status

None

Components

Affects versions

Priority

Minor
Configure