• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Tim Cooke
  • Ron McLeod
  • paul wheaton
  • Jeanne Boyarsky
Sheriffs:
  • Paul Clapham
  • Devaka Cooray
Saloon Keepers:
  • Tim Holloway
  • Roland Mueller
  • Himai Minh
Bartenders:

Java 8 vs. Groovy - Functional Programming

 
Greenhorn
Posts: 14
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi to all!

For some time, the language groovy is used to teach the benefits of functional programming.
What is the advantage of using java 8 over languages ​​like groovy/scala?

Thank you,
Francisco.
 
Author
Posts: 31
12
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Francisco Llaryora wrote:Hi to all!

For some time, the language groovy is used to teach the benefits of functional programming.
What is the advantage of using java 8 over languages ​​like groovy/scala?

Thank you,
Francisco.



Hi Francisco,

I've used Scala and Groovy a bit for functional programming things and I've generally found them to be pretty good. I think its hard to put my finger on something that makes the Java the language better than scala or groovy, but there's quite a few things at the platform level.

* IDE/Build Tool support - whenever I've used either groovy or scala I've run into quite a number of bugs or missing features in IDE and build systems. To my mind its great that Java 8 lets you continue to use the mature and well supported Java ecosystem while getting some functional programming support.
* Type systems - Scala has quite a sophisticated and powerful type system, but I've found a lot of people get confused by the complexity this brings compared to Java. I personally value static typing quite a bit, so for me I'd count that as a positive over traditional groovy. Groovy 2.0 brings static typing but especially on the early releases I've hit a number of bugs which hurt productivity.
* Streams - Scala has had a lot of operations on collections, similar to the style of parallel streams but there are numerous issues. There's a great talk at http://www.youtube.com/watch?v=uiJycy6dFSQ which goes into a lot of these problems. I think the parallel decomposition and performance issues have been thought through a lot better in the Java 8 streams library.

regards,

Richard
 
Don't get me started about those stupid light bulbs.
reply
    Bookmark Topic Watch Topic
  • New Topic