Trill icon indicating copy to clipboard operation
Trill copied to clipboard

Should the payload always be struct?

Open nsulikowski opened this issue 5 years ago • 1 comments

or class?

nsulikowski avatar Apr 17 '19 23:04 nsulikowski

Hello! As with all things .Net memory management, the answer tends to come down to "maybe?" The general guidance we give is to start with struct. The logic behind it is that internally to Trill we batch data into groups of up to 80 thousand. Having the data co-located like that is likely to increase throughput at least a little. However, it's not free, because the initial batching will also need to copy the structs into the payload batch.

cybertyche avatar Apr 19 '19 06:04 cybertyche