Details
-
Bug
-
Resolution: Fixed
-
Medium
-
1.12.7, 2.0.2, 2.0.4
-
None
Description
Summary
Unable to create Live Plans with more than 1000 versions in Oracle due to ORA-01795: maximum number of expressions in a list is 1000
Environment
- Oracle Database 11g
- Large JIRA applications installations with thousands of versions.
Steps to Reproduce
- Navigate to Portfolio > Create Plan.
- Enter any name and click Next.
- Select a board or a filter whose referenced projects contain more than 1000 versions (e.g. a JQL filter referencing 3 projects with 400 versions in each project).
- Click Next.
Expected Results
The Live Plan is created successfully.
Actual Results
You get an error banner with the message Bummer, something has gone terribly wrong here...:
Clicking on 'Show Details', the following error is displayed:
Error reading enrichment information for versions
com.atlassian.jpo.common.PersistenceException: Error reading enrichment information for versions at com.atlassian.jpo.version.sql.QueryDslVersionEnrichmentPersistence.getVersionEnrichments:85 at com.atlassian.jpo.version.DefaultVersionService.enrichEnvironmentProjects:268 at com.atlassian.jpo.project.ProjectService.getDeepProjects:122 at com.atlassian.jpo.project.ProjectService.getDeepProjectsById:101 at com.atlassian.rm.jpo.issueloading.lucene.issuesource.context.DefaultIssueSourceContextService.getProjectInfosForIssueSources:60 at com.atlassian.jpo.rest.service.plan.setup.projects.PlanSetupProjectsRestEndpoint.getProjects:56 (...) Caused by com.mysema.query.QueryException: Caught SQLSyntaxErrorException for select "versionRankItem"."ID", "versionRankItem"."ENV_ID", "versionRankItem"."DELTA" from "AO_D9132D_VERSION_ENRICHMENT" "versionRankItem" where "versionRankItem"."ENV_ID" in (?, ?, (...), ?, ?) at com.mysema.query.sql.DefaultSQLExceptionTranslator.translate:38 at com.mysema.query.sql.Configuration.translate:514 (...) Caused by java.sql.SQLSyntaxErrorException: ORA-01795: maximum number of expressions in a list is 1000 at oracle.jdbc.driver.T4CTTIoer.processError:440 at oracle.jdbc.driver.T4CTTIoer.processError:396 (...)
The full exception can also be found in the catalina.out file.
Notes
This was tested on JIRA 6.4.12.
I've attached the full stack trace to this bug: exception.txt