Cloud Flow

Cloud Flow is similar to Page Flow, where you visually design logic using a collection of pre-designed blocks using a drag-and-drop interface.

While Page Flow logic is tailored for a page or form, Cloud Flow's logic operates in your app's server-side back-end on Zingy's cloud platform.

Your app's cloud flows can be managed through the Cloud Flow tab as shown below.


Types of Cloud Flow

Zingy has the following types of cloud flows:

Background Task

Requires Business or higher edition to function in the published version.

You can test this feature starting with the Standard edition.

A Background Task cloud flow is used to run something in the background, either periodically (at regular intervals) or upon database trigger events.

Web Hook

A Web Hook cloud flow lets your Zingy app securely receive requests from a page, form within your app, or even other applications, including third-party ones. Consider the Web Hook cloud flow as your custom-built API Call. It's a bridge through which your app, other Zingy applications, or external apps can interact and share data.

Use the Cloud Flow Invoke Hook block in Page Flow to communicate with the web hook from your app's pages and forms.


Adding a Cloud Flow

To add a new cloud flow use the New Cloud Flow icon and choose the type of the cloud flow.

Background Task

For a Background Task cloud flow, you simply need to provide a unique name.

Background Task Cloud Flows require Business or higher edition for use in the live/published version of your app. The Standard edition, allows you to test the feature.

Web Hook

If you are adding a Web Hook cloud flow, you need to set the Hook HTTP Method and the Response Streaming option in addition to the unique name.

Hook HTTP Method

Refer to this link to learn more about HTTP methods.

We recommend the POST method, but you can choose the GET method if required.

Response Streaming

By default the Response Streaming option is set to No. With this option, the response generated by this Cloud Flow is sent as one big chunk to the requesting client.

If your goal is to handle a substantial volume of data from an external source and relay this data in your response, opting for a Piped (Pass-through) approach enables streaming of the data concurrently with its receipt from the external source. This method is efficient in terms of conserving the memory usage on your server-side application.

Alternatively, if your application or logic produces the response in segments, utilizing the Chunked option enables the transmission of data in parts as each segment is created. For instance, when processing a CSV file, you have the ability to send the data that has been parsed in chunks, while the parsing of the CSV continues.

NOTE: Piped (Pass-through) and Chunked settings are advanced options and require the use of Javascript code using the Custom Code block. Click here for more information.


Editing a Cloud Flow

Clicking on a cloud flow will present a popup-menu with various options. Choose the Edit Flow option to launch the Cloud Flow Editor.

Please note that you need to re-publish your app for the flow changes to be reflected in the live version of the app.


Access (Security)

Similar to the access rules for pages, databases and connections, you can establish role-based access for your Web Hook cloud flows.

It's worth noting that Background Task cloud flows don't require access rules since they don't grant access to any app resources, be it within the app's pages or external applications.

Click on the desired cloud flow, and choose the Access (Security) option from the popup-menu.

By default all registered Users of the app and members of the Admin group are allowed to invoke or trigger the web hook. You can change this by clicking on the Edit button (highlighted below).

The image below shows the process of editing the access rules.

  • To allow a group, select it (1), choose the minimum role level (2) and click on the Add button (3).

  • To grant public access to an operation, select the "Public" group.

  • To remove a group click on the 'x' icon (4). Note: The "Admin" group cannot be removed.

Please note that you need to re-publish your app for the acsess changes to take effect in the live version of your app.


Load Order

By default, the Zingy cloud backend for your app loads the cloud flows in the order they were created. Although this arrangement suits most scenarios, there might be occasions when you want a specific cloud flow to load ahead of another.

By utilizing the Load Order - and Load Order + options from the popup menu that appears when you select a cloud flow, you can modify the sequence in which they load.

Please note that you need to re-publish your app for the ordering changes to be applied to the live version of the app.


Disabling a Cloud Flow

Cloud flows can be temporarily disabled, preventing them from loading and executing.

Choose the Disable option from the popup-menu that appears when you select the cloud flow.

If the cloud flow is already disabled, the menu will offer an Enable option, which you can use to reactivate it.

Please note that you need to re-publish your app for the deactivation/activation changes to be reflected in the live version of the app.


Deleting a Cloud Flow

If you do not need a cloud flow any more, you can delete it.

Select the cloud flow you want to delete, and choose the Delete option from the popup-menu.

Please note that you need to re-publish your app for the deleted cloud flow to be removed from the live version of your app.


See Also

Last updated