Measuring a form's size in memoryAdded by IBM on November 25, 2011 | Version 1 (Original)
|You can measure the size of a form in memory, and use this value to determine an appropriate setting for the Translator's form cache (fcCacheSize).
You can measure the size of a form in memory, and use this value to determine an appropriate setting for the Translator's form cache (fcCacheSize
One way to approximate the size of a form in memory is to load the form in the Viewer, fill in all the form data and attach any files, and monitor the process memory usage. However, you should use this value only as a starting point. Subsequent testing will help you refine your setting for optimum performance.
The following procedure is for Windows
To measure a form's size in memory:
Parent topic: Changing the Size of the Form Cache
- Click Start -> Settings -> Control Panel -> Administrative Tools -> Performance to open the Performance monitor.
- In the left panel, open Console Root -> Performance Logs and Alerts and select Counter Logs.
- Click Action -> New Log Settings to create a new log setting and name it Webform.
- In the new Webform window, click Add Counters.
- In the Add Counters window, select Use local computer counters.
- Set Performance object to Process.
- Under Select counters from list, select Private Bytes.
- Under Select instances from list, select java.
- Click Add.
- Click Close to close the Add Counters window.
The Webform window now lists:
- \Process(java)\Private Bytes
- Click the Log Files tab and set Log file type to Text File (Comma delimited).
- Click the Schedule tab and set Start log to Manually (using the shortcut menu).
- Click OK to close the Webform window.
Keep the Performance window open.
- Stop all WebSphere® Application Server instances, including the instance hosting the Translator.
- Open the Windows Task Manager and make sure no java.exe processes are running.
- Start the Translator service.
- Open a Web browser to http://localhost:8085/translator/Translate?Action=toolbelt.
This initializes the API and sets a baseline for memory usage.
- In the Performance window, select Webform and click Action -> Start to start the counter log, and then wait two minutes to allow the counter to record the baseline memory usage several times.
- Use your Webform Server sample application (http://localhost:8085/Samples) to open the form you want to measure, and then wait two minutes to allow the counter to record the memory usage several times.
- Close and restart your Web browser, and then repeat the previous step. Do this two times, for a total of three form opens.
This will produce enough memory measurements for you to calculate an average value.
- In the Performance window, select Webform and click Action -> Stop to stop the counter log.
- Open the log in a spreadsheet program or text editor.
(The default location for performance logs is C:\PerfLogs.)
- The log of memory usage should indicate three spikes, one for each time you opened the form. For each spike, calculate the increase in memory usage. Then average the three increases in memory usage.
This value is the approximate size of the form in memory.