Whether you are building your own “step-based” Cloud Connector, or simply configuring one for use in your Program Builder program, at some point the question of “timing” is going to come up.
When you create and enable a program containing a Cloud Connector step, it will execute every 15 minutes. When the program executes, it moves members from step to step, performing the action defined in each. When the program members reach the Cloud Connector step, they pause in that step, and wait for an external or “cloud” service to act on them. The program continues to cycle every 15 minutes, but the members will not move past the Cloud Connector step until the cloud service sets their status to complete.
What can sometimes cause a bit of confusion is the fact that even though the members show in the step in Program Builder, they are not necessarily visible to the Cloud Connector (through the ExternalActionService API).
Let’s take a look at the following program:
The Begin step contains 7 members. When the program is enabled, it will wait 15 minutes, then execute, moving the 7 members to the Validate Data step. The members will then show in the Validate Data step (a Cloud Connector step) in Program Builder, but will not show up if you attempt to count the members in the step using the ExternalActionService API. Only when the program executes in the next 15 minute interval, will the members become visible to the API. This is because the first cycle puts them into the step, but it's the second cycle that actually makes them visible to the API.
Program Builder will continue to cycle every 15 minutes while it waits for the Cloud Connector to perform its action, and mark the members complete. Once the members have been marked complete by the Cloud Connector, and Program Builder cycles again, they will be moved to the next step.
As you can see, when it comes to the length of time it takes for a program to complete, several factors can come into play. There is the execution interval of Program Builder itself, the way members are moved from step visibility to API visibility, and the length of time it takes the Cloud Connector to process the records before marking them complete.
Whether you’re an end user of the connector, or are building the connector and deciding how often to poll, it’s good to keep this “timing” in mind!