System overview: xfNetLink Synergy
xfNetLink Synergy is a set of routines distributed with Synergy/DE Professional Series. These routines work in conjunction with xfServerPlus to execute Synergy routines stored on a remote machine. Using xfNetLink Synergy, you can create a two-tier distributed application consisting of a Synergy user interface on the client accessing Synergy logic residing on a remote Synergy server as shown in figure 1. A Synergy front-end provides your users with a familiar look. Because the client API is provided by Synergy DBL, you can use it on all supported Synergy platforms. The Synergy runtime must be deployed on the client.
Figure 1 shows the primary components of a distributed Synergy application using xfServerPlus and xfNetLink Synergy. The diagram describes two logical machines:
- A Synergy client running a Synergy application that includes the xfNetLink Synergy API and contains the user interface. A single client session may create multiple sessions on one server machine.
- A Synergy server running xfServerPlus, which handles the remote execution of Synergy routines. The routines are made available for remote execution by including them in an ELB or shared image and defining them in the Synergy Method Catalog (SMC). You can populate the SMC with routine information by entering it manually through the Method Definition Utility or by attributing your code, running dbl2xml to create an XML file, and then loading that file into the SMC. You may use multiple servers; each machine requires an xfServerPlus license
xfNetLink Synergy enables you to use your existing Synergy code without rewriting it, provided that the code is already written in the form of an external subroutine or function. If the routine requires input from or sends messages to the user, or if it might generate untrapped errors, it must be adjusted to work as server-level logic.
|
To access Synergy logic remotely with a Synergy client, you must establish a connection between the client and the server using %RX_START_REMOTE. This routine handles the creation of a socket connection between the Synergy client and a dedicated xfServerPlus session running on the server. The use of a dedicated session means that context is maintained from one remote routine call to the next until a shutdown signal is received. Once the connection has been established, your remote routines are available to the client application. You can access them using %RXSUBR (and the xfNetLink Synergy API) or the routine call block API.