10 ms·
I have no strong opinion on serverless but I’ve used Rails for 13 years now (in massive $multi-million SaaS products as well as hobby projects) and it still mak
by thismodernlife 6y ago
I have no strong opinion on serverless but I’ve used Rails for 13 years now (in massive $multi-million SaaS products as well as hobby projects) and it still makes me happy. I keep thinking about learning Node and React but I just can’t be bothered because Rails lets me get things done so quickly while also being a joy to write Ruby and Rspec.
Regarding hosting, I think this is actually a great time to host Rails apps either via Heroku, via the new Digital Ocean k8s app cluster or – and this is my new favourite tool – using Hatchbox.io to deploy apps to Digital Ocean or AWS. It’s a dream!
- luxurytent 6y agoReplace Rails with Django and this comment seems to hold true for many in the Django community. Boring can be good.
- sodapopcan 6y agoBoring tech is great if your primary concern is writing business logic. Ideally, this should always be true, but of course the reality is that people's jobs often have them working on products they don't really care for. And of course, it's easy to get distracted by tech anyway. Experience also comes into play when it comes to loving "boring" tech—it took my around a decade before I was sufficiently jaded that almost all I want to do is write actual business logic. I still love refactoring, though :)
- joelbluminator 6y ago> it took my around a decade before I was sufficiently jaded that almost all I want to do is write actual business logic It's comforting to see I'm not alone. I just wanna ship clean code and contribute value to the business, while all the young bucks in my team are more interested in rewriting our REST apis in Graphql (with all kinds of rationalizations). Looks like the younger you are the more eager you are to explore new tech and the older you are the more keen you are in just delivering value in a boring old stack.
- marsdepinski 6y ago+1. Boring tech just works and provides familiar tools you can build on.
- sodapopcan 6y agoHa, ya, my work recently mandated moving everything to graphql. My team started a greenfield project so there was no need to convert anything, though the learning curve was high with apollo. Graphql is nice, but as the only consumers of our API, I don't see it as a win over REST. At this point, though, we're proficient enough that it doesn't get in our way.
- joelbluminator 6y ago> but as the only consumers of our API, I don't see it as a win over REST. Same story here. Our company is the only API user, why go through all that trouble? Donno.
- xwdv 6y agoAll you need is one weekend to really learn a useful amount of Node and React. You can’t spare it?
- nickthemagicman 6y agoI personally like Ruby better than Node and Svelte better than React. So that weekend could rabbit hole into complexity figuring out which framework to use.
- sodapopcan 6y agoWhy bother? I work on a very UI-heavy interactive app (it's a gantt chart) for work and therefore have been doing react daily for 1.5 years. React is probably making life a little easier here, and I don't hate it, but I don't love it either. If I didn't love my team so much I would be looking for a job working on a more classic web app in Rails. And when I profess my appreciation for Rails, I could just as easily be talking about Django, Phoenix, or any other _opinionated_ backend framework. [edited for spelling]
- kawsper 6y agoI know some Rails shops that are switching to Stimulus Reflex for some UI-heavy things, it works like Phoenix LiveViews, you can briefly see how CodeFund uses it for their interfaces here (40 seconds in): https://www.youtube.com/watch?v=F5hA79vKE_E&feature=youtu.be&t=40 https://www.youtube.com/watch?v=F5hA79vKE_E&feature=youtu.be...
- sodapopcan 6y agoI'm aware of Stimulus Reflex though never tried it out! :) I've been playing with LiveView a lot recently which is fantastic. I would love to switch to stimulus but we're pretty heavily bought into React at this point.
- neurostimulant 6y agoWhat's the benefit of moving from Rails to Node and React productivity-wise? On the backend side, Rails comes with an ORM, authentication, templating system and many more out of the box, while on Node you'll need to mix and match a bunch of 3rd party libs or roll your own, which might be a good thing depending on your priorities but certainly kills productivity. On the frontend side, you can always use react with rails backend, but developing traditional template-based ui is usually faster than developing a react app and you can take advantage of rails templating/rendering feature to speed up development.
- ffdjjjffjj 6y agoI’m also a big fan of rails, but I’ve experienced a lot of problems scaling it. A lot of the problems ultimately came down to the simple fact that Ruby is really, really slow. At a certain scale you end up forced to develop infrastructure on a different stack to keep up with the CPU load. I never ran into that so quickly when building similar systems with java, go, and C#. I wanna say something nice about rails too so I’ll say I have never seen a team so quickly deliver high quality web app features than a well oiled rails team. It’s something to behold.
- erikrothoff 6y agoCurious what part of Rails you didn’t find scalable? Our Rails frontend servers run on cheap VMs that are easily scaled horizontally.
- awestroke 6y agoScaling horizontally is not cheap. A faster language needs fewer replicas.
- erikrothoff 6y agoReally? Our frontend servers handle 50 rps and cost $20 each and are nowhere near peak utilization. If anything ever needs scaling its the database. What level of traffic are you talking about?
- tutfbhuf 6y agoFor example a newspaper with customizable content, 1 petabyte (70% video) per month and avg. 2k request per second.
- erikrothoff 6y agoI don’t want to second guess technical decisions I know nothing about but: no, Rails shouldn’t be streaming video. But 2k requests per second with mostly text content being shuffled around sounds absolutely doable with Rails. The cost benefit of easier development should definitely not be understated as well. But that being said, the primary driver for tools should be what the developers know and ease of access finding developers who know this technology. If the city you work in mostly has PHP developers, PHP is a great choice. Similar for Java, Haskell, Lisp, etc. My point is that the tool ”Rails” definitely is adequate for this problem (minus streaming video...). Look at Shopify, Github or any other massive Rails app
- cpursley 6y agoElixir (with Phoenix) really is the sweet-spot for a productive framework that's fast, scalable and easy to pick up for a Rails developer: https://medium.com/coryodaniel/from-erverless-to-elixir-48752db4d7bc https://medium.com/coryodaniel/from-erverless-to-elixir-4875...
- freedomben 6y agoSecond this. I did rails for years and liked it a lot, but there were pain points, particularly as a project scaled. Elixir/Phoenix solves a lot of these pain points and is a joy to work with. If you like Ruby/Rails then you already know quite a bit of Phoenix. Schedule yourself 4 hours to follow a tutorial or book.
- murphm8 6y agoDo you have any recommended books or tutorials?
- cambalache 6y agoFor the language and the framework the official tutorial/documentation are pretty good. Also Pragmatic Programmers has very good books on both, written by the creators. I love Phoenix but I will disagree with the OP in 2 points. Yes probably Elixir/Phoenix will manage better thousands of concurrent connections, but if you are doing personal projects or are a start-up that condition is irrelevant in the meantime. So that only lefts us with the big established applications. That does not mean Phoenix is not good, it only means you will not notice a difference with Rails for most of your projects. The second thing, that OP failed to mention is that the Rails ecosystem is at least an order of magnitude larger. From the gems available, job opportunities,developers available, instructional material, SOP for many tasks and so on.That is boring, but valuable.
- lawn 6y agoProgramming Phoenix is good. You might want to look at something Elixir specific too, I liked Programming Elixir although I've heard good things about Elixir in Action as well. The official online documentation is pretty good too.
- unixhero 6y agoI am not a good programmer. Every time I try to learn a language I end up down rabbit holes and always end up yak shaving. Whenever I take the plunge I am always reassured; Ruby and Rails does make me happy.
- faizshah 6y agoIs there a good way to turn your rails app into a mobile app these days? I remember seeing something from turbolinks showing a way to make hybrid mobile apps using turbolinks.
- julianrubisch 6y agoYep, turbolinks. We’re all waiting for TL6 though to revive the android adapter.
- stepbeek 6y agoIt’s been a while. I tried to hack something like this together - without having done any android dev before - and I understand why it’s taking a while. It’s not as simple as I’d imagined it would be.
- tomerbd 6y agoSpring + Thymeleaf is also great it's practically Ruby on Rails for Java developers.
- arcturus17 6y agoHaving learned web dev around five years to go, my main stack has been Node/Express or Firebase (serverless) with React front-ends. However, I got tired of the lack in conventions in Express, and Firebase has quite a few gotchas and limitations, so I'm moving to good old Django. I'm delighted thus far, I love not having to reinvent the wheel every time I start a project or add a feature. I'm probably keeping React/Next.js as my primary working tools for the front-end nonetheless, but that's just me because I feel highly productive with them and I've become accustomed to the decoupled client/API architecture. I can see the merits of SSR with templating as seen in RoR or Python, and I'm happy to have that tool in my belt. But conversely I also think it's worth for pretty much everyone to learn React (or Vue, Svelte, or what have you) because they do open different possibilities in UX engineering and app architecture, and the market is quite hot for them too.