Reputation: 168
I've been going through the docs on dataweave memory management and came across some confusions related to the configuration of buffer files Link: https://docs.mulesoft.com/dataweave/2.4/dataweave-memory-management
com.mulesoft.dw.memory_pool_size
suggests that by default there are 60 slots in the off-heap memory and com.mulesoft.dw.max_memory_allocation
governs the size of each slot, if the slot exceeds the default size limit of 1572864 bytes its pushed to a file storage. If thats the case then what is the role of com.mulesoft.dw.buffersize
doesn't it governs the size of data that should be held in memory and if exceeded push to the file storage, but the same is also done by the previously mentioned 2 properties?dw-buffer-output-${count}.tmp
and dw-buffer-input-${count}.tmp
have a default size limit of 1572864 bytes after which they are pushed to file storage but, the other property com.mulesoft.dw.buffersize
that governs the limits shows the default size set to 8192 bytes, isn't it incorrect?com.mulesoft.dw.memory_pool_size
Since Mule 4.3.0, DataWeave buffers use off-heap memory from a pool up to a defined size and allocates the rest using heap memory.
If buffers use 60 slots x 1.5 MB in the off-heap space and if the size continues to grow will the additional part move to the heap space and if at all it moves to the heap space when/what is the limit it will be pushed to file storage?Apparently, the documentation looks quite confusing, appreciate if someone could help in calrifying the confusions.
Upvotes: 1
Views: 957
Reputation: 25782
Sounds about right. If the size is exceeded, the data can not fit into the memory reserved and has to go to a temporary buffer file.
The documentation is incorrect at this time about com.mulesoft.dw.buffersize
determining if the data should go to a temporary buffer file. I'm sure the documentation will be fixed soon.
The decision to move data to a temporary buffer file is not by the number of slots. Rather is if a single slot (of 1.5 MB) can contain the data.
Upvotes: 4