Red Hat Training

A Red Hat training course is available for Red Hat JBoss Data Virtualization

10.2. Scalability Considerations

Although, you can find information about all JBoss Data Virtualization settings using the Management CLI (see Section 11.1, “JBoss Data Virtualization Settings”), this section provides some additional information about those settings related to scalability.
buffer-service-processor-batch-size
Default is 256. This property specifies the maximum row count of a batch sent internally within the query processor. Additional considerations are needed if extremely large VM sizes and or datasets are being used. JBoss Data Virtualization has a non-negligible amount of overhead per batch/table page on the order of 100-200 bytes. Depending on the data types involved, each full batch/table page will represent a variable number of rows (a power of two multiple above or below the processor batch size).
If you are working with extremely large datasets and you run into memory issues, consider increasing the buffer-service-processor-batch-size property to force the allocation of larger batches and table pages.
buffer-service-max-storage-object-size
Default is 8288608 or 8MB. This value is the maximum size of a buffered managed object in bytes and represents the individual batch page size.
If buffer-service-processor-batch-size is increased or you are dealing with extremely wide result sets, then the default setting of 8MB for the buffer-service-max-storage-object-size may be too low. The inline LOBS also contribute to this size if the batch contains them. The sizing for buffer-service-max-storage-object-size is in terms of serialized size, which will be much closer to the raw data size than the Java memory footprint estimation used for buffer-service-max-reserve-kb.
buffer-service-max-storage-object-size should not be set too large relative to buffer-service-memory-buffer-space since it will reduce the performance of the memory buffer. The memory buffer supports only 1 concurrent writer for each buffer-service-max-storage-object-size of the buffer-service-memory-buffer-space.

Note

JBoss Data Virtualization temporary tables (also used for internal materialization) can only support 2^31-1 rows per table.
buffer-service-memory-buffer-space
Default is -1. This controls the amount of on or off heap memory allocated as byte buffers for use by the JBoss Data Virtualization buffer manager. This setting defaults to -1, which automatically determines a setting based upon whether it is on or off heap and the value for buffer-service-max-reserve-kb.

Note

When left at the default setting the calculated memory buffer space will be approximately one quarter of the buffer-service-max-reserve-kb setting. If the memory buffer is off heap and the buffer-service-max-reserve-kb setting is automatically calculated, the memory buffer space will be subtracted out of the effective buffer-service-max-reserve-kb.
buffer-service-memory-buffer-off-heap
Default is false. Determines whether to take advantage of the buffer manager memory buffer to access system memory without allocating it to the heap. Setting buffer-service-memory-buffer-off-heap to true will allocate the JBoss Data Virtualization memory buffer off heap. Depending on whether your installation is dedicated to JBoss Data Virtualization and the amount of system memory available, this may be preferred over on-heap allocation.
The primary benefit of off-heap memory is additional memory usage for JBoss Data Virtualization without additional garbage collection tuning. This becomes especially important in situations where more than 32GB of memory is desired for the JVM. Note that when using off-heap allocation, the memory must still be available to the java process and that setting the value of buffer-service-memory-buffer-space too high may cause the JVM to swap rather than reside in memory. With large off-heap buffer sizes (greater than several gigabytes) you may also need to adjust JVM settings.
For Sun JVMs the relevant JVM settings are MaxDirectMemorySize and UseLargePages. For example adding:
-XX:MaxDirectMemorySize=12g -XX:+UseLargePages
to the JVM process arguments would allow for an effective allocation of an (approximately) 11GB JBoss Data Virtualization memory buffer (the buffer-service-memory-buffer-space property) accounting for any additional direct memory that may be needed by JBoss EAP or applications running within it.