3 ms·
I know this is ever so slightly off topic, but is Groovy in popular use these days? I seem to see it mentioned quite a lot recently. If so, what for? General s
by philbarr 12y ago
I know this is ever so slightly off topic, but is Groovy in popular use these days? I seem to see it mentioned quite a lot recently.
If so, what for? General scripting tasks?
- pjmlp 12y agoThe Groovy use case was a bit crazy. It was on a corporation that was replacing their HP-UX/Perl/C++/CORBA infrastructure with JEE/Java/Red-Hat Linux. The new sysadmins (newly grads) just started replacing the existing, battle tested Perl scripts with Groovy ones. The only reason pointed out was that they couldn't grok Perl. As for its use in general, here in Germany it seems to have been replaced by Scala/Clojure. When Rails was hype, the JUGs around my area used to be full of Grails and other Groovy related sessions. Nowadays it seldom comes up in the agenda.
- laichzeit0 12y agoGroovy is one of the best kept secrets of the JVM scripting world. I hardly _ever_ write pure Java if I can do it in Groovy instead. Look at how insanely easy parallel programming is in Groovy using gpars: http://gpars.codehaus.org/ http://gpars.codehaus.org/ It's literally: GParsPool.withPool { def result = [1, 2, 3, 4, 5].collectParallel {it * 2} } Why oh why people still torture themselves with pure Java.
- pjmlp 12y ago> Why oh why people still torture themselves with pure Java. Customer requirements.
- raiph 12y agoAn equivalent in P6: [1,2,3,4,5] X* 2 This (theoretically) parallel processes and then puts the results back in order. The X is the cross metaoperator; it applies the following operator (the * symbol which is the multiply operator) to each of the combinations of the items in the lists on its left and right, and does so in parallel if the compiler so chooses, and ensures the results are returned as if it was processed sequentially.
- vorg 12y agoGroovy's being heavily promoted behind the scenes by its handlers at VMWare, everything short of paid adverts. It's been sitting in the 40's on TIOBE constantly since 2007, sometimes higher, sometimes out of the top 50, but hasn't had any consistent uptake since then. It's main use case was with Grails, but like its "inspiration" Rails, Grails is on the decline. Groovy's original use was as a dynamic language with closures for scripting Java classes, but there's now many other options like Clojure where you can define a 3-line macro to eliminate some repeating code that can't be done with a function. Its backers have tried to use their Groovy distribution channel to ship other addons such as DSL syntax (2009), a parallel processing library (2011), static typing and compilation (2012), and (soon) an Android version, but like when this trick is pulled with other software from elsewhere developers aren't biting. Gradle 1.x used Groovy for its DSL syntax, but Gradle 2.0 removed virtually all Groovy code from its internal codebase, probably an indicator of their future plans regarding Groovy. Overall, use Groovy * if you're still using Grails * for quick scripts that your certain won't need to scale * in Gradle but stick to the DSL syntax