Re-using StringBuilder

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

Re-using StringBuilder

Guido Medina
QuickFIX/J Documentation: http://www.quickfixj.org/documentation/
QuickFIX/J Support: http://www.quickfixj.org/support/



Hi all,

Recently I went to another project which seems to be saving lots of memory utilization and hence making the GC work less, that is to re-use String builders at a ThreadLocal level.

I will do such modification this week and test it, and will report back if there are any improvements, I expect there will be because StringBuilder is backed by a char[] which will basically re-use the same array over and over and over.

That can be very beneficial for streaming market data, etc.

Let me know what you think.

Cheers,

Guido.

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Quickfixj-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/quickfixj-users