Consider the following when configuring the Translator.
Configure each Translator instance so that its in-memory form cache can make full use of the memory available for each process.
Set the form cache size for a Translator instance by using the fcCacheSize
option, which determines how much memory is used for forms processes. For each Translator instance, the fcCacheSize
- the maximum number of forms that will be kept in the memory cache
- the number of users that can simultaneously access the Translator instance, at maximum performance
For example, if you set fcCacheSize
to 200, then a single Translator instance can support 200 users and keep 200 forms in the memory cache.
The size of a form in memory is larger than on disk. For example, a form that is 1 MB on disk may be 10 MB in memory. Total memory usage by the form cache is determined by multiplying the fcCacheSize
value with the size of a form in memory. If fcCacheSize
is 200 and the size of a form in memory is 10 MB, then the Translator instance will use 200 x 10 MB = 2 GB of memory for the form cache. For instructions on how to determine the size of a form in memory, see Measuring a form's size in memory
If you set the form cache size too small, then your Webform Server system will support fewer simultaneous users at maximum performance. But if you set the form cache size too large, then the Translator will try to make use of more memory than is available, causing the Translator JVM to exit with an “Out of Memory” error.
Consider the following examples, which illustrate the problems caused by setting the form cache size too large or too small. Assuming that there is 2.25 GB of available memory and that your form is 10 MB in memory:
- If you set fcCacheSize to 100, then you are allocating 100 x 10 MB = 1 GB of memory for the form cache, which is only half of the available memory. You can use a larger fcCacheSize setting to ensure better user support.
- If you set fcCacheSize to 300, then you are allocating 300 x 10 MB = 3 GB of memory for the form cache, which is more than the available memory. This would cause the Translator JVM to return an Out of Memory error.
Therefore, it is important to set an fcCacheSize
value that is appropriate for your system.
If you have more than one Translator instance, then the number of users that can be supported and the number of forms kept in the memory cache are both multiplied by the number of Translator instances. For example, if you set fcCacheSize
to 200 and your Webform Server system consists of 8 Translator instances, then your system can support 8 x 200 = 1600 simultaneous users at maximum performance. This means that if more than 1600 users try to use your system at the same time, then the Translator will write some form instances to the Shared File Cache, and performance will decrease. Make sure to have the right number of Translators and the appropriate fcCacheSize
setting to serve your expected user base.
to 60 seconds.
controls how frequently the Translator checks in-memory forms for updates, and writes them to the Shared File Cache. The default value is 10 seconds.
Lower values provide greater failover support, because in-memory forms are written to the Shared File Cache more frequently. Once a form is written to the Shared File Cache, any Translator instance can take over session interaction.
Higher values are recommended for high performance applications. However, the higher the value, the more user data will be lost during a failover, degrading the user experience.
Do not set contactFrequency
any lower than the default value: 900 seconds.
controls how often a form instance contacts the Access Control System to indicate that the form is still active. The Access Control System maintains the state of the form, and clears inactive forms from the Shared File Cache.
The default value is 180 seconds. If testing indicates that your application is I/O bound, experiment with higher acCleanerInterval
controls how often the Translator checks the Shared File Cache for old form instances that can be deleted.
Depending on your application, you may want to set focusNotificationItems
in order to increase overall performance.
can be turned on (set to all
) to indicate whether the user's cursor position is posted to the server.
Parent topic: Setting up the Translator