Accessing resources with Remote Subprocesses
It is common that some resources required for integration are behind a firewall so they cannot be accessed from the public internet. For example, it is a good practice to secure databases behind a firewall for extra protection against threats. To access these resources you have to have an Agent connected to Frends which is behind the same firewall as those resources and the Agent has to be connected to those resources. You can then execute Processes using that Agent.
In some cases you only want to execute Process steps using that Agent when it is necessary to connect to resources behind a firewall, but otherwise you want to use Cloud Agents. For example, you have multiple Processes which need to fetch data from a secured database but you cannot execute all the Processes using that Agent since it would generate a load to the Agent which it cannot handle. To solve this problem you should consider using a Remote Subprocess to handle steps of the Process which require a connection to the database.
For a quick recap, Remote Subprocesses are Subprocess calls which allow you to select the Agent Group that will execute the Subprocess in each of your Environments. Usually if you call a Subprocess in a Process, the Agent executing the Process will also execute the Subprocess. Using Remote Subprocesses you can move the execution from one Agent to another Agent. The command to trigger the Subprocess is transferred using a Service Bus, so there might be some latency if you need to pass a lot of data to the Subprocess or if the Subprocess returns a lot of data back to the calling Process.
So, you have a case where you have to connect to a database which is behind a firewall, but you cannot execute the whole Process using an Agent which has access to the database. In this case, you should create a Subprocess which only handles the retrieval or the sending of data to or from the database. You can then call that Subprocess remotely from a Process. This way you can run the whole Process in any of your Agents and only execute actions related to the database using the Agent which has access to the database. The requirement for this solution is that the Agent Group which contains the Agent, which has access to the database, exists in the same Environment as the Agent Group which is executing the Process which calls the Remote Subprocess. This is necessary since you cannot call a Subprocess remotely between Environments, only between Agent Groups in an Environment.
The next article is Best practices on Simplifying Processes with Subprocesses