[HN Gopher] Jets: Ruby Serverless Framework
       ___________________________________________________________________
        
       Jets: Ruby Serverless Framework
        
       Author : thunderbong
       Score  : 118 points
       Date   : 2023-12-05 22:01 UTC (2 days ago)
        
 (HTM) web link (docs.rubyonjets.com)
 (TXT) w3m dump (docs.rubyonjets.com)
        
       | kulor wrote:
       | If people aren't familiar, there's a similar project for Python
       | that's fantastic: https://github.com/zappa/Zappa
        
         | lobo_tuerto wrote:
         | There is one for Elixir too, Flame:
         | https://fly.io/blog/rethinking-serverless-with-flame/
        
           | freedomben wrote:
           | Is Flame actually ready for production use yet? I just saw it
           | the first time a couple days ago but no idea how long it's
           | been simmering.
           | 
           | Flame seems very different to me than Jets though. Flame just
           | plugs into a Phoenix app and lets you trivially async some
           | application code on a different node through the existing
           | erlang functionality without having to manually sync
           | memory/state/etc. Definitely cool, but seems fundamentally
           | different than Jets which uses traditional "serverless"
        
       | Alifatisk wrote:
       | How active is this project?
        
         | runjake wrote:
         | https://github.com/rubyonjets/jets/commits/master/
         | 
         | Pretty active?
        
         | sam0x17 wrote:
         | It's been pretty consistently active over the last four years
         | from what I've seen
        
       | sam0x17 wrote:
       | Former CTO at Arist (YC S'20) here.
       | 
       | Jet's literally got us off the ground and to the point where we
       | could handle spikes where we scale up 1000x to handle hundreds of
       | thousands of messages per second and then immediately scale back
       | down 1000x because of the spikey nature of our workload.
       | 
       | Almost all of the traditional issues one encounters when running
       | a Rails app in production vanish when you build on top of Jets,
       | as scaling just becomes something that happens automatically
       | without you worrying too much about it other than at the database
       | level.
       | 
       | One thing that was particularly impressive about Jets is its
       | whole ApplicationJob system that provides an easy-to-use API for
       | writing lambda fan-out routines, which we used as the crux of our
       | message scheduling and processing system
       | https://docs.rubyonjets.com/docs/jobs/
       | 
       | Anyway, I mostly work in Rust now but still am and will always be
       | a huge fan of the project and Tung Nguyen, its creator :)
        
         | tongueroo wrote:
         | Thanks Sam!
        
         | davidw wrote:
         | How much more do you estimate, very roughly, it costs to use
         | the serverless stuff in "normal times" outside of spikes
         | compared to a more traditional system?
        
           | sam0x17 wrote:
           | normal times was well within the free tier, and this was even
           | with a pre-warm job turned on for our endpoints. Even the
           | spikes were not very expensive. Back then 80% of our bill was
           | RDS and I think we were paying under $50/mo for beyond-free-
           | tier usage of lambda. It was a tiny fraction of what the cost
           | was when we had EC2 clusters.
           | 
           | If you're ok with cold-starts on less-used routes you could
           | probably make any medium to low traffic app run totally free
           | on jets (other than db)
        
         | quickthrower2 wrote:
         | I guess this is a serverless thing rather than Jets-specific?
         | Has anyone had this experience in NextJS using serverless
         | erm... servers? Maybe Vercel themselves (or Lambda etc.)
        
           | sam0x17 wrote:
           | What's really special about Jets in particular is it lets you
           | have your cake and eat it too, in that locally you have what
           | feels like a pretty normal monolithic Rails app, but when you
           | deploy every endpoint magically becomes its own lambda...
        
       | tongueroo wrote:
       | Jets 5 was just released also
       | https://blog.boltops.com/2023/12/05/jets-5-improvements-galo...
        
       | dcchambers wrote:
       | Love seeing non-rails ruby stuff. This project looks cool...In
       | general I think most people should avoid lambdas except for very
       | specific types of workloads, but I hope projects like this allow
       | ruby/rails devs to feel a bit more comfortable building lambda
       | functions when they do need one.
        
         | freedomben wrote:
         | Likewise, non-rails ruby stuff doesn't get nearly enough love.
         | I still use and love Sinatra for small apps quick
         | PoCs/demos/tools. So wonderfully stable and mature, and does
         | what it needs to do.
        
           | manojlds wrote:
           | Not to mention Jekyll
        
         | jerrygenser wrote:
         | What's wrong with lambda? If you write a monolithic app that
         | serves your rest API via lambda that pattern can be very
         | powerful. What alternative for such a use case would your
         | recommend instead?
        
       | jmarchello wrote:
       | Anything that gets more Ruby out in the world is positive in my
       | book. Great looking project!
        
       | blondin wrote:
       | can't recall the last time i was on a project's page and
       | everything just clicked. no fluff. kudos to the team!
        
       | xutopia wrote:
       | Is there an example of this to run a web socket?
        
       | dang wrote:
       | Related:
       | 
       |  _Ruby on Jets: Like Rails but serverless_ -
       | https://news.ycombinator.com/item?id=34474049 - Jan 2023 (84
       | comments)
       | 
       |  _Jets: Ruby Serverless Framework_ -
       | https://news.ycombinator.com/item?id=19893796 - May 2019 (39
       | comments)
        
       | askonomm wrote:
       | I've learned and previously also professionally worked with:
       | JavaScript, TypeScript, PHP, Clojure, ClojureScript.
       | 
       | I really like the ergonomics of Ruby. Should I learn it? How's
       | the job market (decreasing|stable|increasing)? Is Ruby also good
       | for non-web things?
        
         | promiseofbeans wrote:
         | I've been seeing a lot of job postings mentioning rails
         | recently
        
         | caseyohara wrote:
         | Ruby is absolutely worth learning. It's a nice combination of
         | OO and functional programming, and I find it nice to both read
         | and write. It's very expressive; I find it easier to model my
         | ideas in Ruby than many other languages.
         | 
         | The job market seems healthy and stable, but I'm not a reliable
         | source on that.
         | 
         | Outside of web development, Ruby is an excellent scripting
         | language, that's perhaps where it excels best.
        
       | trevor-e wrote:
       | Nice, looks like the Ruby equivalent of sst.dev for folks that
       | prefer Typescript.
        
       ___________________________________________________________________
       (page generated 2023-12-07 23:00 UTC)