Memory requirements on the server
The Adonix process that executes the Sage X3 code on the server, manages two segments of memory to handle the resources it has access to.
Two variables exist that define the maximum size allowed to a process for each segment: maxmem and maxheap. Assigning a given value to each does not imply that the process will use the whole amount of memory immediately. The process will allocate the memory without exceeding the fixed limits.
Usually, default values for these two variables are defined in the configuration file APL.ini, that contains assignments of variable done by the engine when a process starts. A reassignment can be done at any time in a script.
A measure of the remaining memory of every type is given by the two functions freemem and freeheap.
If, at a given point, the required memory to manage the buffer exceeds the limit, an error (more memory available) will appear. You should measure the memory consumption in the scripts handling the biggest resource size, in order to be sure that this error will not appear at execution time.
End
execution). The Kill
and Close Mask
instructions can be used to release the main memory.The amount of memory managed by 'maxmem' and 'maxheap' is not used immediately by the process. It is the upper limit of memory consumption managed by a process.
Every parameter can be set up independently:
The sadora or sadodbc processes, that handle the database connection, use the value of variable sadmem to dimension buffers. The value of this variable can only be defined in the configuration file APL.ini. A reassignment cannot be done dynamically in a script.