I have an application (C#, WPF) that displays many financial charts with live data streaming from server. The data that is collected in-memory may grow to be a bit large, and I don’t want to keep any data on disk.
Since the historical data itself doesn’t change, but only added to, will it make sense to keep that data (which is stored in a collection object) in some compressed format?
Is it possible and can anyone recommend a good practice for it if so?
UPDATE
Some notes about performance and tradeoff:
I am aware that compression will add a delay accessing the data, but, the user only needs fast updates on new data arriving. When accessing the data that was already rendered (for example, to study or re-render it) he doesn’t require a quick response.
Compressing and decompressing will make your application slower so for performance (speed) it is not a good option.
Compression is only useful when you are worried about available memory. It might be easier to store/swap the data to a temp folder.
The key to performance is measuring. Only take action when you have crunched the numbers.