-
Type:
Bug
-
Resolution: Fixed
-
Priority:
Medium
-
Component/s: Forge and Connect - App Permission Sync
-
Minor
Issue Summary:
When dynamic modules are created during Connect app installation lifecycle hooks during Connect to Forge upgrade process, the existing Connect dynamic modules are not handled properly that ends up breaking page loading.
Steps to Reproduce
- Create a Connect app using Spring Boot
- Capture the /install event with an EventListener (Controller)
@EventListener public void addonInstalled(AddonInstalledEvent event){ jiraRestCallService.callInstalled(event); }
- Call the Connect dynamic module API (POST /rest/atlassian-connect/1/app/module/dynamic) to create a custom field module (Service)
public void callInstalled(AddonInstalledEvent event){ String url = "/rest/atlassian-connect/1/app/module/dynamic"; JsonNodeFactory jnf = JsonNodeFactory.instance; ObjectNode payload = jnf.objectNode(); ObjectNode objects = jnf.objectNode(); ObjectNode description = jnf.objectNode(); ObjectNode name = jnf.objectNode(); ArrayNode arrayNode = jnf.arrayNode(); objects.put("key", "dynamic-custom-field"); objects.put("type", "number"); name.put("value", "Testing the SpringURL"); objects.put("name", name); description.put("value", "This is a dynamically registered custom number field"); objects.put("description", description); arrayNode.add(objects); payload.put("jiraIssueFields", arrayNode); ResponseEntity<String> responseEntity = atlassianHostRestClients .authenticatedAsAddon(event.getHost()) .postForEntity(url, payload, String.class); }
- Install the app in a Jira instance.
- Convert the app to Connect-on-Forge with the below command:
npx connect-to-forge@latest --type jira --url [your_descriptor_url_here]
- Register the app as a new Forge app, deploy it, and install it in the same instance where your Connect app is installed
forge register forge deploy forge install
- All should be working fine in your Jira instance.
- Deploy a new forge version of your app and run forge install as well
forge deploy forge install
The install command might fail, as the app is already installed.
Expected Results
Previous dynamic modules are mapped correctly to the new Forge app modules
Actual Results
Page fails to load due to errors loading Connect dynamic modules
![]()
Workaround
App can be uninstalled to restore page loads.