You can import the triggers and flows from an exported app into an existing app or into a new app. The target app into which you want to import must exist. You can import an app by dragging and dropping its .json file into the UI.
Note: Flogo apps that are exported from Flogo Enterprise 2.5.0 and later cannot be imported into previous versions of Flogo Enterprise.
Here are a few things to keep in mind:
l If a flow in the app uses extensions developed by the community, those extensions must be available to the target app into which you are importing, at the time of the import. Flows that make use of extensions that are not available to the target app are not imported.
l Passwords or connection details configured in any activity within any flow or connection in the app to be exported are removed in the exported app. You must manually configure the credentials or VPN connections in the flows after importing such apps.
l Some apps created in Project Flogo use the any data type. The any data type is not supported in Flogo Enterprise. Such apps get imported successfully, but the element of type any gets converted into an empty object. You must explicitly use the mapper to populate the empty object with member elements.
l When importing an app, be aware that the long and double data types get converted to the number data type.
Note: When importing apps that were exported from Project Flogo, be aware of the following:
l If the apps being imported use an activity that is not supported in Flogo Enterprise, a validation erroris displayed.
l You can only import apps that were created in Project Flogo version 0.5.2 or above.
Note:
l In imported apps, the passwords and secrets for any connections configured in the app do not get imported. You must reconfigure any password or secret for the connection after the app has been imported.
l When you import an app that does not have a Return activity in any flow (main or branched flow), the Return activity is not added automatically by default. However, if an existing app already has Return activities in main or branched flows, the app is imported as expected.
Importing into a new or empty app
1. Create a new app if you do not already have one.
2. On the app details page, select Import app.
3. Navigate to or drag and drop the .json file for the app that you want to import.
4. Click Upload. The Import app dialog box displays some generic errors and warnings as well as any specific errors or warnings pertaining to the app you are importing. It validates whether all the activities and triggers used in the app are available on the Extensions tab.
5. You have the option to import all flows from the source app or selectively import flows.
l Import all - To import all the triggers and flows in the app, select Import All.
If any activities or triggers are missing on the Extensions tab, the import process ignores the flows that contain those activities resulting in those flows not being imported. If the existing app already has activities or triggers with the same name as the ones you are importing, you see a warning that they are overwritten. If you do not want to overwrite the flows, you can click Back and clear the selection then click Next. If you do so, the duplicate flows that you
de-selected do not get imported. You can rename the flows using the UI, app dialog box, hence you cannot select them to import. By default, all check boxes are selected. Clear the check box next to the triggers that you do not want to import. All flows associated with the selected trigger(s) get imported by default. If you do not select a trigger, the flows and their subflows
associated with the unselected trigger(s) are listed in the next screen.
6. Click Next.
If you had not selected a trigger in the previous dialog box, the flows associated with that trigger are displayed. You have the option to select one or more of these flows such that the flows get imported as blank flows that are not attached to any trigger.
By default, all flows are selected. Clear the check box for the flows that you do not want to import. If your flows have subflows, and you select only the main flow but do not select the subflow, the main flow gets imported without the subflow. Click Next.
7. After importing an app, you must reconfigure all the newly created connections.
Importing into an app that has existing flows
When importing the app into another app that has existing flows, keep the following in mind:
l If the existing app already has flows, activities, or triggers with the same name as the ones you are importing, a warning is displayed. You can opt not to import those flows, activities, or triggers. You can go back and rename them using the UI, export the app again, and re-import it.
l If any of the flows that were imported with the app had credentials such as a password or a connection, be sure to re-configure them.
1. Open the app details page by clicking the app name.
2. Click the shortcut menu ( ) and select Import.
3. Navigate to or drag and drop the .json file for the app that you want to import.
4. Click Upload. The Import app dialog box displays some generic errors and warnings as well as any specific errors or warnings pertaining to the app you are importing. It validates whether all the activities and triggers used in the app are available on the Extensions tab.
5. You have the option to import all flows from the source app or selectively import flows.
l Import all - To import all the triggers and flows in the app, select Import All.
If any activities or triggers are missing on the Extensions tab, the import process ignores the flows that contain those activities resulting in those flows not being imported. If the existing app already has activities or triggers with the same name as the ones you are importing, you see a warning that they are overwritten. If you do not want to overwrite the flows, you can click Back and clear the selection then click Next. If you do so, the duplicate flows that you de-selected do not get imported. You can rename the flows using the UI and export the app and re-import it.
l Selective import - Select Selective Import, to import only specific triggers and flows from the app. The Import app dialog box displays a list of triggers with a check box next to each one. If any activities or triggers are missing on the Extensions tab, the missing activities or triggers are not listed in the Import app dialog box, hence you cannot select them to import. By default, all check boxes are selected. Clear the check box next to the triggers that you do not want to import. All flows associated with the selected trigger(s) get imported by default. If you do not select a trigger, the flows and their subflows
associated with the unselected trigger(s) are listed in the next screen.
6. Click Next.
If you had not selected a trigger in the previous dialog box, the flows associated with that trigger are displayed. You have the option to select one or more of these flows such that the flows get imported as blank flows that are not attached to any trigger.
By default, all flows are selected. Clear the check box for the flows that you do not want to import. If your flows have subflows, and you select only the main flow but do not select the subflow, the main flow gets imported without the subflow.
7. Click Next.
8. After importing an app, you must reconfigure all the newly created connections.
Importing flows without importing the triggers that they are attached to
1. Select Selective Import when importing the app.
2. Clear the check box for the triggers that you do not want to import.
3. Click Next. A list of flows is displayed.
4. Select the flows that you would like to import and click Next. The flows are imported as blank flows without being attached to a trigger.
5. After importing an app, you must reconfigure all the newly created connections.
Handling connections when importing an app
After importing an app, you must reconfigure all the newly created connections.
Each connection in Flogo Enterprise contains a unique internal ID. The IDs are not exposed on the UI and are unique based on the user who created them.
When Flogo Enterprise compares connections, it does so by comparing their internal IDs.
It considers two connections identical if they have the same connection type and same connection ID. It considers two connections as similar if they have the same connection type, but different connection ID.
Hence, if the app you are importing was not created by you, then any connections used in that app cannot have the same ID as any existing connection of the same type that you might already have in your installation of Flogo Enterprise. For example, if you import an app created by some other user that has some Salesforce connections, even though your installation of Flogo Enterprise might already have some existing Salesforce connections, the connections are considered similar, because they are of the same type (Salesforce) but not identical because they do not have the same ID because they were not created by the same user.
When importing an app containing a connection, if your target app has an existing connection with an identical internal ID as the connection in the app being imported, a new connection does not get created. The imported app uses the existing connection in such a case. The connection credentials do not get exported with the app. If a new connection gets created, you must re-configure the connection credentials after the app has been imported.
Keep the following in mind when you import an app with connections:
Import all
If you had selected Import all when importing the app, you have the following options:
l If you are the owner who created the app to be imported, if identical connections exist in your environment, the existing connections are automatically re-used.
l If identical connections do not exist, then new connections get created without passwords. You must set the password for such connections after the app has been imported.
l If there are similar connections (same type but different IDs) in the host app, Flogo Enterprise does not re-use those connections. It creates new connections without passwords. You must set the password for such connections after the app has been imported.
Selective import
If you chose to do a selective import when importing an app, the Import app dialog box lists the connections that are used in the flows and triggers that you selected for import in the app to be imported. It displays a drop-down menu next to each connection. You have the following options:
l If you have any existing identical connections (same connection type and same connection ID) in the host app, that connection is automatically selected in the drop-down menu next to the connection. You have the option to re-use the existing identical connection by leaving it pre-selected.
l If there are any similar connections in the host app (same connection type but different connection ID), you can select the similar connection from the drop-down menu next to it.
l You always have the option to select Create new connection from the drop-down menus for any of the connections. Flogo Enterprise creates new connections with no passwords. You must manually create a password for the new connection after importing the app.