4 ms·
This comment is what I feel like replying with to every article about some "fast iterating" language. IMO the only reason to use rails if you don't actually un
by humbleMouse 10y ago
This comment is what I feel like replying with to every article about some "fast iterating" language. IMO the only reason to use rails if you don't actually understand how web development actually works. Why would you pick a slower language and platform like ruby/rails when java/spring is right there available to anyone?
- olavgg 10y agoAnd Grails is very similar to Rails, and you get the full power of the JVM/Spring technology stack. And Groovy is a fantastic language that gives you the flexibility everyone like to dream about.
- humbleMouse 10y agoGroovy is amazing. It's like javascript and Java had a beautiful baby that lets you compile either dynamically or statically.
- vorg 10y agoThe static compilation doesn't quite work properly. Groovy is good for scripting though, similar to the way Bash is used in Linux, so test your Java classes with it, or use it as a DSL in Gradle builds. For building systems on the JVM, use a language designed for that purpose from the ground up, e.g. Java, Scala, or Kotlin.
- humbleMouse 10y agoIt works quite well in the 1.5 million code line application written in groovy that I work on. I am sure Scala and Kotlin are nice languages, but groovy static compilation seems to work great in my experience.
- vorg 10y ago> the 1.5 million code line application written in groovy That's quite big for Groovy. There's a lot of exaggerated claims coming out of that ecosystem. Most JVM apps that size are actually written in Java, perhaps with the codebase duplicated a few times, and counting testing copies of the code in the LOC count. If the harness for testing is written in Groovy, you could call it a "1.5 million line Groovy app". If some of that Java code is compiled or run as Groovy code in some testing framework, you could call it all "Groovy code". If the Groovy code is called from some app written in Java, such as Grails, you could get creative and call it a "Groovy application". > groovy static compilation seems to work great And just what proportion of that Groovy code is really compiled statically and run in a production app?
- humbleMouse 10y agoTo be fair - only about 2/3 of the code in the app I mentioned is written in groovy. We strictly enforce static compilation with all of our groovy files. The app is used daily by 35,000 users concurrently @peak time.
- vorg 10y agoMy last personal experience of programming in Apache Groovy was with version 1.8. Often I tried recompiling some Java code from Groovy's codebase into Groovy, and even after changing it to allow for occasionally different semantics, it wouldn't work. It could be that Groovy 2.4 has improved a lot since v 1.8, but with the history of exaggerated claims associated with Groovy's backers, I'd need more evidence for your claim. For example, if the next version of Groovy ships having translated its own codebase into statically compiled Groovy, I'll happily look at it again for building systems. In the meantime, I'll only trust it for scripting. Then there's their governance problem -- nowadays, a single person owns the groovy-lang.org website, whereas until early last year it was governed by 5 "despots" at Codehaus. It's never good when leadership becomes less consensual.
- olavgg 10y agoI also have several big projects with hundreds of thousand lines of Groovy code that works fantastically well. And performance is top notch!
- vorg 10y agoApache Groovy is a dynamically typed language so performance can't be "top notch". And the static compilation is an addon that only works when used sparsely. If it worked at scale, the Groovy codebase itself would have been translated into statically compiled Groovy, but that's not happening because Groovy's static compilation doesn't scale. Groovy's good for scripting, nothing more, which isn't a bad thing. Just use it to script/test systems built with Java (or Scala or Kotlin or whatever).
- vorg 10y ago> you get the full power of the JVM/Spring technology stack. And Groovy If Groovy and Grails are technology "to dream about", one wonders then why VMware (the Spring backers) retrenched their 6 developers working on Grails and (what is now Apache) Groovy early last year, and why Sun Microsystems (the JVM backers before Oracle) wanted nothing to do with Groovy in its day (despite supporting the JRuby and Jython developers).
- humbleMouse 10y agoInternal politics? Budget constraints? Bad management? Idk
- tootie 10y agoFast-iterating is only useful when you have a small team and are getting off the ground. Every project spends 90% of it's life in maintenance and will be handed off between dozens of developers who will just ask "WTF is this?" no matter what you do. Java provides a lot more traceability and determinism as well as verbose idioms that make it easier to deal with. Like I've said many times, Java doesn't solve programming problems, it solves organizational problems.
- Tenhundfeld 10y ago> IMO the only reason to use rails if you don't actually understand how web development actually works. I'm not following your reasoning. Just because Ruby/Rails runs slower than Java/Spring, why does that mean you "don't understand how web development actually works" if you choose Ruby/Rails? That's a serious question. Runtime performance of a language/framework is only one small sliver of the overall performance of a large system. And overall runtime performance of a system is only one factor, among many, when choosing the right stack for a business.
- humbleMouse 10y agoTo expand on my offhanded comment: If you are well versed in OOP design principles/database design - I don't see why you would choose rails. I suppose if I didn't have so much experience with java I might want to try something like ruby. Java just gives you so much freedom to design things how you want and use whatever framework you feel like. I don't feel comfortable with all these behind the scenes scaffolding things happening. I prefer to design back-ends as data endpoints that feed a separate business logic layer. I feel like I have the most control of these things using java.
- Corrado 10y ago> Java just gives you so much freedom to design things > how you want and use whatever framework you feel like. This lack of flexibility is precisely the reason that people choose Rails. It is a very opinionated solution and the Rails community doesn't hide that fact. The power of a Rails project is anyone familiar with Rails can walk up to it and get productive in minutes. All the code is in a standard place, the tests are run the same way, the deployment is familiar, etc. On the contrary, look at 100 different Java projects and you would find 100 very different solutions. Getting up to speed on an existing Java project would take multiple times longer than a Rails project, even if you were generally familiar with Java + Spring.