4D v13.4Client/Server page |
||
|
4D v13.4
Client/Server page
Client/Server page
4D allows you to build customized client-server applications that are homogenous, cross-platform and with an automatic update option. Client and server applications are configured on the Client/Server page of the Build Application dialog box. A client-server application comes from the combination of three items:
Once built, a client-server application is composed of two customized parts: the Server portion (unique) and the Client portion (to install on each client machine). For comparison reasons, remember that a standard deployment using 4D Server requires the 4D Server application, the database structure file, the database data file and the 4D application in remote mode. Also, the client-server application is customized and its handling simplified:
Finally, a client/server application can be set so that the client portion can be updated automatically over the network. This function is detailed in the Copy of client applications in the server application section.
During the build of the executable client/server application, 4D duplicates the contents of the 4D Server folder in the Server subfolder of the destination folder and the contents of the 4D Volume Desktop folder in the Client subfolder of the destination folder. You can then totally customize the contents of the original 4D Server and 4D Volume Desktop folders as necessary. For example, you can:
Note: Under Mac OS, 4D Server is provided as a package. You must first display its contents (Control+click on its icon) to be able to modify it. You use the options of this area to set up the mechanism for updating the client parts of your client/server applications using the network each time a new version of the application is generated.
Updating the client application is necessary when you want to use a new version of 4D Server or one of the components. Note that the changes made to the custom application (development and/or data) are always transmitted automatically to each client machine. Updating the client application prevents the developer from having to manually install new versions of 4D on each client machine. The client application update notification is actually carried out automatically following the server application update. This works as follows: when a new version of the client/server application is built using the application builder, the new client portion is copied as a compressed file in the Upgrade4DClient subfolder of the ApplicationName Server folder (under Mac OS, these folders are included in the server package). If you have followed the process for generating a cross-platform client application, an update file is available for each platform: To trigger client application update notifications, simply replace the old version of the server application with the new one and then execute it. The rest of the process is automatic. On the client side, when the “old” client application tries to connect to the updated server application, a dialog box is displayed on the client machine, indicating that a new version is available. The user can either update their version or cancel the dialog box.
In some cases, you may want to prevent client applications from being able to cancel the update download. For example, if you used a new version of the 4D Server source application, the new version of the client application must absolutely be installed on each client machine. To force the update, simply exclude the current version number of client applications (X-1 and earlier) in the version number range compatible with the server application. In this case, the update mechanism will not allow non-updated client applications to connect. For example, if the new version of the client-server application is 6, you can stipulate that any client application with a version number lower than 6 will not be allowed to connect. The current version number is set on the Client-Server page of the Build Application dialog box (see above). The intervals of authorized numbers are set in the application project using specific XML keys. For more information about this, refer to . If 4D cannot carry out the update of the client application, the client machine displays the following error message: “The update of the client application failed. The application is now going to quit.” There are many possible causes for this error. When you get this message, it is advisable to check the following parameters first off:
Once a client/server application is built, you will find a new folder in the destination folder named Client Server executable. This folder contains two subfolders, ApplicationName Client and ApplicationName Server: Note: These folders are not generated if an error occurs. In this case, open the log file (see Log file) in order to find out the cause of the error. The ApplicationName Client folder contains the client portion of the application corresponding to the execution platform of the application builder. This folder must be installed on each client machine. The ApplicationName Server folder contains the server portion of the application. The contents of these folders vary depending on the current platform:
Note: The Mac OS packages built contain the same items as the Windows subfolders. You can display their contents (Control+click on the icon) in order to be able to modify them. If you check the “Allow automatic update of client application” option, an additional subfolder called Upgrade4DClient is added in the ApplicationName Server folder/package. This subfolder contains the client application in Mac OS and/or Windows format as a compressed file. This file is used during the automatic client application update. If the server and/or client part of your double-clickable application is used as a Web server, the files and folders required by the server must be installed in specific locations. These items are the following:
|
PROPERTIES
Product: 4D |