News for hackers. Stuff that matters.
Re:From Node to Ruby on Rails by princevegeta89 on Thursday December 16, 2021 @12:47PM (#29581215)
Right, but a big project in Rails has all the problems you can think of:

- slow to compile and run

- easy target for spaghetti code

- test suites get sluggish

- hard to upgrade

- won't scale well

- with no static typing, large scale collaboration can easily break things

- metaprogramming hell

Re:From Node to Ruby on Rails by jaredcwhite on Thursday December 16, 2021 @01:23PM (#29581760)
A big project in any stack has many problems. Vanilla Rails is going to scale way better than some wacky bespoke configuration of stitched-together NPM packages, which in my experience is what a lot of folks build now because they don't know any better.
Re:From Node to Ruby on Rails by princevegeta89 on Thursday December 16, 2021 @03:51PM (#29583744)
I've successfully run Java/Go projects with huge amounts of code without a lot of degradation in any direction whereas Rails seems to quickly come to a stopping point compared to other platforms. I've written my side project which is now at a huge size in Elixir, I'm yet to see any degradation so far. I'm sure Rails would have been a pain by now. Sorry I don't have much Node experience so can't comment.
Re:From Node to Ruby on Rails by jaredcwhite on Friday December 17, 2021 @12:49AM (#29588349)
Simply hasn't been my experience at all, and I've worked with numerous Rails projects large and small since 2008. If you prefer Java/Go/Elixir, knock yourself out, but I'm throughly satisfied with Ruby-based solutions.
Re:From Node to Ruby on Rails by princevegeta89 on Friday December 17, 2021 @04:09AM (#29589713)
Got it. It's not impossible but I've been at multiple jobs involving Rails monolithic apps, they all really sucked from a maintenance and development perspective.

P.S would have been happier if you had a better choice of words than "knocking myself out".

Re:From Node to Ruby on Rails by mountainriver on Friday December 17, 2021 @10:50AM (#29593809)
Yes, I’m at one of those companies now, spaghetti code galore, and the project is becoming increasingly harder to maintain.

As the company scales they really need to break things into more services to distribute work and satiate work happening in other languages, but now that’s nearly impossible because of the mess they’ve created

Rails is great if your building a basic “dumb” web app, but rails folks seem to think it’s more than that and need to get their heads out of the clouds

Re:From Node to Ruby on Rails by jaredcwhite on Friday December 17, 2021 @08:07PM (#29600378)
I've worked on a lot of legacy Rails apps. Most of the problems of "spaghetti code" occur because people write bucketloads of un-Ruby-like code that betrays a serious lack of understanding around how Rails really works. Whenever I hear "aw man, Rails sucks. I switched to writing (X) in Rust/Go/Haskell/TypeScript/whatever…"

Let me stop you right there. If you tell me Rails wasn't meeting your needs so you rewrote (X) in a different manner using Ruby + something else, I'd totally understand. Otherwise, all it tells me is that there was a tragic lack of deep Ruby knowledge, respect even, to begin with as the project unfolded. Often I muse on how in some ways it was unfortunate that Rails became such a darling in the startup community early on. It meant that a ton of people jumped into Rails web dev thinking they were writing "Rails". No, you're writing Ruby, and Rails just provides a nice set of base classes and some decent defaults and assumptions. If you end up with a giant wad of spaghetti mess, that's on you. It's totally feasible not to end up there, and plenty of projects end up in far better shape.

Re:From Node to Ruby on Rails by ericb on Thursday December 16, 2021 @06:22PM (#29585432)
> won't scale well

Really?

https://twitter.com/ShopifyEng/status/1465806691543531525

Github is in Rails. I mean, seems like it scales just fine.

Re:From Node to Ruby on Rails by princevegeta89 on Thursday December 16, 2021 @08:42PM (#29586696)
It takes a lot more effort and housekeeping in Rails to make it scale well. When Github was built, Rails didn't have many decent alternatives. As of today there are a good number
Re:From Node to Ruby on Rails by montblanc on Saturday December 18, 2021 @12:59PM (#29606727)
> It takes a lot more effort and housekeeping in Rails to make it scale well.

It takes increasing the number of pods on your k8s which is how almost all teams deploy nowadays. Bigger amazon bills yes but the devops overhead isn't really larger in Rails,

Re:From Node to Ruby on Rails by k__ on Thursday December 16, 2021 @01:18PM (#29581679)
Somehow Rails seemed to me like a short fad.

I knew a few people at university, who were pretty hyped about it. That was in 2008, I think. They used it at some companies where they jobbed and found it too limiting.

I was building customized stuff with bare PHP in those days and found it quite flexible. Later, the Rails hype came to PHP, but I already left for Node.js and never looked back.

Re:From Node to Ruby on Rails by dwheeler on Thursday December 16, 2021 @04:46PM (#29584409)
GitHub and GitLab use Rails. Many UK government websites do.

Like anything else, Rails is good for some things & terrible at others. Rails tries to minimize developer time, at the cost of computing time (Ruby is not a fast language), and focuses on CRUD-type applications. Whether or not that's a good match depends on what you're trying to do.

Re:From Node to Ruby on Rails by k__ on Thursday December 16, 2021 @09:26PM (#29586965)
Somehow Rails-like frameworks didn't make it big on Node.js, which was released way later than Ruby.

I saw this as a sign that the time of these fully fledged frameworks was over and devs were craving modularity.

But, yes, I saw a bunch of recent projects done with Rails. Forem is built with it, for example.