Details
-
Bug
-
Resolution: Fixed
-
High
-
None
-
None
-
None
-
32
-
Severity 3 - Minor
Description
Issue Summary
With JCMA version 1.6.6 (and also newer JCMA versions), when the customer is trying to select Advanced roadmap plan in the migration, it throws an error: Error communicating with Server
Steps to Reproduce
- Create a migration plan using JCMA and click on the edit button to select Advanced Roadmap plans, you will see the said error in UI.
Expected Results
There should be no errors and JCMA should allow selecting AR plans.
Actual Results
- JCMA throws an error: Error communicating with Server:
- In logs we see below error:
2022-02-07 14:22:00,772+0000 http-nio-8080-exec-33 url: /rest/migration/latest/advanced-roadmaps/projects; user: panol5 ERROR panol5 862x188344x4 o88p1n 62.220.165.241,2.21.240.61,104.123.68.196,172.31.6.204 /rest/migration/latest/advanced-roadmaps/projects [c.a.p.r.c.error.jersey.ThrowableExceptionMapper] Uncaught exception thrown by REST service: null java.lang.NullPointerException at com.atlassian.jira.migration.serverdataextractors.RelatedEntitiesDataReader.getAllProjectIdsReferencedByFilters(RelatedEntitiesDataReader.kt:73) at com.atlassian.jira.migration.serverdataextractors.RelatedEntitiesDataReader.getProjectIdsReferencedByBoardsFromPlans(RelatedEntitiesDataReader.kt:59) at com.atlassian.jira.migration.serverdataextractors.RelatedEntitiesDataReader.getProjectsFromPlans(RelatedEntitiesDataReader.kt:38) at com.atlassian.jira.migration.serverdataextractors.AdvancedRoadmapsDataResource.listProjectsForPlans(AdvancedRoadmapsDataResource.kt:30)
Workaround
Workaround 1: Safe but with potentially lot of manual labour
- Use the below given select query to find out all the plans that are affected by this issue
Query: DB query to see the issue source(s) without value(s):
SELECT "ID", "TITLE" FROM "AO_D9132D_PLAN" WHERE "ID" IN ( SELECT "PLAN_ID" FROM "AO_D9132D_ISSUE_SOURCE" WHERE "SOURCE_VALUE" IS NULL OR TRIM("SOURCE_VALUE") LIKE '' OR ("SOURCE_TYPE" = 'Project' AND "SOURCE_VALUE" NOT IN (SELECT CAST(id AS TEXT) FROM project)) OR ("SOURCE_TYPE" = 'Filter' AND "SOURCE_VALUE" NOT IN (SELECT CAST(id AS TEXT) FROM searchrequest)) OR ("SOURCE_TYPE" = 'Board' AND "SOURCE_VALUE" NOT IN (SELECT CAST("AO_60DB71_RAPIDVIEW"."ID" AS TEXT) FROM "AO_60DB71_RAPIDVIEW")) OR ("SOURCE_TYPE" = 'Board' AND (SELECT "SAVED_FILTER_ID" NOT IN (SELECT CAST(id AS BIGINT) FROM searchrequest) FROM "AO_60DB71_RAPIDVIEW" WHERE CAST("ID" AS TEXT) = "SOURCE_VALUE")) );
In the output from query, "TITLE" is the name of the plan as it appears in UI.
- Go to the affected plans one by one
- From the Roadmap tab, navigate to Settings > Configure
- Select Issue sources tab
- Change the type(s) of the issue source(s) without value(s)
Follow the video to understand how to remove those empty issue sources in case of any confusion.
broken_issue_sources_walkthrough.mov - Select <- Back to plan to save
- Once you have removed the empty issue sources from all affected plans, refresh JCMA and retry selecting AR plans on the tasklist page
Workaround 2: Delete issue sources with invalid values in Database
1. Use the below given Delete query to delete all the broken issue sources in plans.
Query:
DELETE FROM "AO_D9132D_PLANTEAM" WHERE "ISSUE_SOURCE_ID" IN ( SELECT "ID" FROM "AO_D9132D_ISSUE_SOURCE" WHERE "SOURCE_VALUE" IS NULL OR TRIM("SOURCE_VALUE") LIKE '' OR ("SOURCE_TYPE" = 'Project' AND "SOURCE_VALUE" NOT IN (SELECT CAST(id AS TEXT) FROM project)) OR ("SOURCE_TYPE" = 'Filter' AND "SOURCE_VALUE" NOT IN (SELECT CAST(id AS TEXT) FROM searchrequest)) OR ("SOURCE_TYPE" = 'Board' AND "SOURCE_VALUE" NOT IN (SELECT CAST("AO_60DB71_RAPIDVIEW"."ID" AS TEXT) FROM "AO_60DB71_RAPIDVIEW")) OR ("SOURCE_TYPE" = 'Board' AND (SELECT "SAVED_FILTER_ID" NOT IN (SELECT CAST(id AS BIGINT) FROM searchrequest) FROM "AO_60DB71_RAPIDVIEW" WHERE CAST("ID" AS TEXT) = "SOURCE_VALUE")) ); DELETE FROM "AO_D9132D_ISSUE_SOURCE" WHERE "SOURCE_VALUE" IS NULL OR TRIM("SOURCE_VALUE") LIKE '' OR ("SOURCE_TYPE" = 'Project' AND "SOURCE_VALUE" NOT IN (SELECT CAST(id AS TEXT) FROM project)) OR ("SOURCE_TYPE" = 'Filter' AND "SOURCE_VALUE" NOT IN (SELECT CAST(id AS TEXT) FROM searchrequest)) OR ("SOURCE_TYPE" = 'Board' AND "SOURCE_VALUE" NOT IN (SELECT CAST("AO_60DB71_RAPIDVIEW"."ID" AS TEXT) FROM "AO_60DB71_RAPIDVIEW")) OR ("SOURCE_TYPE" = 'Board' AND (SELECT "SAVED_FILTER_ID" NOT IN (SELECT CAST(id AS BIGINT) FROM searchrequest) FROM "AO_60DB71_RAPIDVIEW" WHERE CAST("ID" AS TEXT) = "SOURCE_VALUE"));
2. Post executing the query, refresh JCMA and retry selecting AR plans on the tasklist page
Attachments
Issue Links
- mentioned in
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...
-
Page Loading...