|
|
|
|
|
Optimizing the connection times to the HFSQL Client/Server databases
Available only with this kind of connection
This help page explains how to optimize the connection times to the HFSQL Client/Server databases by limiting the network traffic. Several function calls may be required in order for an application to connect by programming to a HFSQL Client/Server database: - HOpenConnection to specify the server address, the user, the database,
- HChangeConnection to associate some tables with a connection or with another one,
- HPass to specify the password of encrypted files,
- HChangeDir to specify a particular database folder,
- ...
The order in which these functions are called is important: it influences the time required to establish the connection. The gain is not significant for the connection of a desktop application accessing the server via a local network. But from a mobile application in iOS or Android, the impact can be significant if the connection goes through a mobile network with latency. Therefore, the following sequence should be used: - HChangeConnection
- HChangeDir
- HPass
- HOpenConnection
instead of: - HOpenConnection
- HChangeConnection
- HChangeDir
- HPass
Indeed, if HOpenConnection is called first, the connection is immediately opened with network traffic. Then, the other functions will trigger other exchanges between the application and the server in order to modify the parameters of the connection that was just opened. On the contrary, if HOpenConnection is called last, the information required to configure the connection is sent at once: limited network traffic, the performances are improved.
This page is also available for…
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|