Bulk Costing Considerations¶
To optimize the performance of Bulk Costing jobs, ensure that your system is configured to reflect the following.
Bulk Costing Child Clients versus CPU Cores¶
Before increasing the number of Bulk Costing child clients, you must increase the number of CPU cores:
Costing is a single threaded process, so increasing the number of child clients without increasing the number of CPU Cores does NOT improve Bulk Costing performance.
Setting Heap Size for Bulk Costing¶
The default heap size for aPriori Bulk Costing can be set in two files:
- By setting
launcher.max.memoryin<pistol>``\ext\analysis-purchasing-module\plugin.properties. The default is 4096m. - For running the Bulk Loader from the command line, you can also set
MAX_HEAP_SIZEin<ap_install>\bin\bulkLoad.cmd.By default, this setting is commented out, so unless you uncomment and edit this line, command line Bulk Costing jobs use the value set inplugin.properties.
Very complex parts can require 9GB.
If you need to set your child clients to this high of a value, you must ensure that you have enough RAM on the computer. If you have moderately complex parts, you can try setting the heap size to 5GB.
You can also try other settings between these values. For example, if you are going to generate Spreadsheet Reports and use Bulk Costing for greater than 1000 parts, you might try setting the main client heap size to 6GB. Note that these are rough estimates to start with, and you may need to tweak these values to find the best performance for your situation.
Database location¶
The aPriori Bulk Costing process occupies most of the CPU processing of the machine that aP Pro is installed on. Therefore, to optimize performance, do not store your database on a machine that contains aP Pro. Instead, store your database on a separate machine within your LAN.
Calculating total RAM requirements¶
To evaluate the impact of the above considerations, use the following formula to calculate the total RAM needed for your configuration:
Where:
- Tc = Total Number of Child Clients = Total Number of CPU Cores
- Hc = Heap Size setting for individual Bulk Costing Clients
- Hm = Heap Size setting for the main client
- Md = Memory required for the database (2GB if database is on the same machine)
- Mos = Memory required for OS and other processing (2GB)
If your requirements far exceed the existing RAM of the computer, consider making these changes:
- Reduce number of client processes.
- Reduce heap size.
- Add RAM.
Note:
If the database resides on another machine, you can eliminate Md.