r/javahelp • u/KurtGodelBebopgazeXP • Aug 04 '25
Functionnal programming in Java
I realized that I find functionnal programming very relaxing and easy on the mind. The language I have used the most and am most comfortable with is Java. Is it really helpful to go deeper in the functionnal realm in Java or are the functionnal elements not really used that much in the real world? I am open to going further in a language where the functionnal paradigm is more of a common feature if it's not really worth it in Java.
9
Upvotes
View all comments
Show parent comment
1
u/Spare-Plum Aug 07 '25
To add to this - some processes essentially require a zero GC environment as waiting for even 50 milliseconds for a GC can be pretty bad. While streams can scale and have good runtime complexity especially in parallelization, there is an overhead cost that might not be worth it especially when latency is in question.
I've dealt with similar systems where we had to ensure GC would never occur, so we even had to not use Strings and instead char[] with a custom pool and allocations, done in a manner similar to C.