News for hackers. Stuff that matters.
Re:Rewrite It in Rails by alanfranz on Saturday November 02, 2024 @04:20AM (#42024877)
I must say that even if it’s not a trendy stack, I find Spring Framework/Spring Boot to be the best all-around web application stack. Very easy integration with the tons of java libs you have around that can do virtually anything, a statically typed language which can help in a lot of situations (just data binding by convention via Jackson is great since forever, while it’s an afterthought in dynamically typed languages).
Re:Rewrite It in Rails by t-writescode on Saturday November 02, 2024 @04:23AM (#42024891)
I've been incredibly pleased with Ktor and Kotlin, as well. JVM underneath, robust libraries, easy to use infra, using Exposed for the ORM which is mostly (genuinely) a joy.

The best thing I think Rails still has is ActiveAdmin. Everything else, I really can take or leave.

Re:Rewrite It in Rails by Tainnor on Saturday November 02, 2024 @05:06AM (#42025049)
> The best thing I think Rails still has is ActiveAdmin. Everything else, I really can take or leave.

ActiveAdmin gets you off the ground very quickly, but is also extremely inflexible (and, IIRC, poorly maintained). The last time I worked on an ActiveAdmin backend we had to use all sorts of weird hacks to build the interface the way our backoffice team needed it to be.

Re:Rewrite It in Rails by RangerScience on Monday November 04, 2024 @04:28PM (#42046168)
AA is really just some wrapper and glue around some other tools… which aren’t super well documented either, but it definitely does mean that a) you can do weird/custom stuff, and that it’s a PITA to figure out how.
Re:Rewrite It in Rails by dajonker on Saturday November 02, 2024 @06:37AM (#42025433)
In another company I had to completely replace ActiveAdmin with "vanilla" Rails abstractions as it was quite buggy and caused Rails to hang indefinitely as soon as you edited any ruby file. The admin part also turned out to be the most used part of the app, so it probably made sense to replace it in any case, but the bugginess at the time was more than I could handle.
Re:Rewrite It in Rails by regularfry on Monday November 04, 2024 @08:34AM (#42041384)
Admin is the one area where Django has the edge, but it's enough on its own for me to push Django over Rails for a lot of "just put a UI around some data, please" use cases.
Re:Rewrite It in Rails by taikon on Tuesday November 05, 2024 @11:28AM (#42052843)
I recall Active admin having really clunky UI a couple years ago. I just checked it again and it looks really sleek!
Re:Rewrite It in Rails by egeozcan on Saturday November 02, 2024 @04:32AM (#42024928)
I did write a lot of Java but never called myself a Java developer, and in my current company there are a lot of hardcore Java devs who used to swear by the Spring stack (some even liked JSF!), and a lot of them are moving things to Quarkus (https://quarkus.io/). No idea why, just an observation.
Re:Rewrite It in Rails by royjacobs on Saturday November 02, 2024 @04:45AM (#42024974)
They are moving there because it's new and shiny, not because it's better.

Spring and Spring Boot are incredibly productive and give you a ton of stuff out of the box, whereas some people actually enjoy writing a lot of plumbing code as a distraction/challenge from boring business code. Those people will migrate to "lean" frameworks because it will give them the opportunity to write more low-level plumbing code.

Re:Rewrite It in Rails by ffsm8 on Saturday November 02, 2024 @05:07AM (#42025056)
> They are moving there because it's new and shiny, not because it's better.

I highly doubt that.

The real reason is likely more about the GraalVM, which spring hasn't supported until very recently. (And still only with caveats)

Re:Rewrite It in Rails by royjacobs on Saturday November 02, 2024 @05:35AM (#42025163)
That sort of proves my point, though. Spring support for GraalVM is ongoing and will likely be quite useable and mature out of the box.

The people jumping to Quarkus or Micronaut are more eager to chase the new shiny and are willing to spend the time debugging not-yet-mature stacks.

Edit: To be clear, the reply mentions fanboyism but we are talking about the maturity of a stack. Spring has been around for 20 years and is not going anywhere. Quarkus just reached 5.

Re:Rewrite It in Rails by ffsm8 on Saturday November 02, 2024 @05:44AM (#42025205)
The GraalVM is significantly more performant. Calling that "chasing the new shiny" redefines the meaning of the expression, which has historically been about side-grades for unclear advantages.

Especially considering that Springs support isn't full yet, and quarkus has been around for 5yrs now.

They're both production ready stacks though, really strange to have spring fanboyism in 2024

Re:Rewrite It in Rails by alanfranz on Saturday November 02, 2024 @06:03PM (#42029517)
If Rails is fast enough, I doubt plain old Java on a standard JVM is slower. We’re talking comprehensive and productive web stack, not raw speed, otherwise we go back to the Go and Rust case.
Re:Rewrite It in Rails by pjmlp on Saturday November 02, 2024 @05:10AM (#42025067)
JSF can be a great experience when coupled with the right framework like PrimeFaces.
Re:Rewrite It in Rails by egeozcan on Saturday November 02, 2024 @07:12AM (#42025633)
My impression after many years of working with JSF: PrimeFaces or not, it's a lot of server-side state making it hard to work on the front-end and an unnecessary burden on the server.

I have also some nice things to say, and I'm not going to make a detailed analysis here but IMHO, it's really not worth the tradeoff.

Re:Rewrite It in Rails by pjmlp on Saturday November 02, 2024 @07:40AM (#42025748)
Agreed, and yet the celebration of stuff like Blazor Server, Phoenix, among others show that some folks really like this approach.

Personally the experience with JSF and Web Forms, is what makes me appreciate any framework that exposes the underlying browser stack, instead of pretending it is something it is not.

Re:Rewrite It in Rails by alanfranz on Saturday November 02, 2024 @06:04PM (#42029525)
I need to disagree, as I think JSF to be a rather clunky approach, but I admit I never used PrimeFaces.
Re:Rewrite It in Rails by michaelmior on Saturday November 02, 2024 @08:42AM (#42026053)
I think part of the problem may be that a lot of people are familiar with old versions of Java before things like lambdas and anonymous interface implementations were possible. Writing Java without some of those things can be pretty painful.
Re:Rewrite It in Rails by camdenreslink on Monday November 04, 2024 @04:10PM (#42046006)
ASP.NET Core is similar. Not necessarily trendy, but very efficient to work in.