---
title: "9 new features in Ruby 2.4 and replacing Sinatra with pure Rack"
publication: "Ruby Weekly"
issue: 327
published_at: "2016-12-08"
canonical_url: "https://rubyweekly.com/issues/327"
---

9 new features in Ruby 2.4 and replacing Sinatra with pure Rack

This week's Ruby and Rails news[Read this e-mail on the Web](http://rubyweekly.com/issues/327)

Ruby WeeklyIssue 327 — December 8, 2016

Leigh Halliday[Replacing Sinatra with Rack](https://blog.codeship.com/replacing-sinatra-with-rack-in-sidekiq/)A look at replacing the routing and views of the Sidekiq UI with a pure Rack implementation, inspired by incompatibilities introduced by Rails 5.


Peter Cooper[Detect Image Contents From Ruby with Amazon Rekognition](https://medium.com/statuscode/how-to-detect-image-contents-from-ruby-with-amazon-rekognition-46a962cb040f)Rekognition is a new Amazon Web Service that _‘makes it easy to add image analysis to your applications’_ and, indeed, it’s easy to use from Ruby too.


Jesus Castello[9 New Features in Ruby 2.4](http://www.blackbytes.info/2016/12/new-ruby-features/)Set#compare_by_identity, Hash#transform_values, Thread#report_on_exception, and more. You may also be surprised to find out Float#round will now [round to the nearest even number.](https://github.com/ruby/spec/pull/322)


RedisGreenSponsored[Why Is Redis Using so Much Memory?](https://dashboard.redisgreen.net/redismonitor_sign_up?utm_source=rubyweekly&utm_medium=email&utm_campaign=2016c&utm_content=primary&utm_term=why_so_much_memory)RedisMonitor's interactive visual map of your Redis memory makes it easy to find out why. Starts at just $7 per month.

[![RedisGreen\](https://copm.s3.amazonaws.com/c42ae929.png)](https://dashboard.redisgreen.net/redismonitor_sign_up?utm_source=rubyweekly&utm_medium=email&utm_campaign=2016c&utm_content=primary&utm_term=why_so_much_memory)


Ansistrano[Ansistrano: An Ansible Port of Capistrano](https://github.com/ansistrano/deploy)Ansible roles to deploy PHP, Python, Ruby, etc, apps in a Capistrano style.


Sam Livingston-Gray[DRY Up Your Domain Models using a Struct Table](https://www.rubytapas.com/2016/12/05/refactoring-ruby-dry-domain-models-struct-table/)Refactor your code using a struct table to drive out new understandings of the domain.


Joshua Plicque[Refactoring Legacy Rails Controllers](https://blog.codeship.com/refactoring-legacy-rails-controllers/)The first step is to get ‘legacy’ code covered by tests, then refactoring can begin.


Conner Shea[Using GitLab to Build the New GitLab Docs Site](https://about.gitlab.com/2016/12/07/building-a-new-gitlab-docs-site-with-nanoc-gitlab-ci-and-gitlab-pages/)How GitLab replaced a custom Ruby script with a static site generator (nanoc) and GitLab CI for their documentation site.


Jobs

- [Senior Engineer (Ruby/Javascript) in Chicago, IL](http://www.builtinchicago.org/job/senior-engineer-6?utm_source=rubyweekly&utm_medium=email)We are looking for motivated professionals who are excited about leveraging technology in order to impact the lives of millions of students. Our clients include ACT®, HRCI, Hobsons and many other educational companies. Benchprep
- [Looking for a Ruby developer to join our team... (Remote, UK-based)](https://www.yourtradebase.com/jobs?utm_source=rubyweekly&utm_medium=email)You: passionate, experienced, want to do work that makes a difference. Us: would love to speak to you about joining our small team. Working remotely with Ruby, Rails and React in an agile team. YOURTRADEBASE.COM
- [Don't Get Frustrated - Get Hired](http://hired.com/?utm_source=newsletters&utm_medium=petercooperpress&utm_campaign=q4-16-rubyweekly)Hired puts the power back in your hands, by having companies apply to you, not the other way around. With Hired you only talk to companies you're interested in. Hired

In brief

- [New Maintainer Sought for RubyInstaller for Windows](https://github.com/oneclick/rubyinstaller/issues/348?utm_source=rubyweekly&utm_medium=email) news
- [Rails 5.1 to Support Yarn and Webpack Out Of The Box](https://github.com/rails/rails/pull/26836#issuecomment-263860213?utm_source=rubyweekly&utm_medium=email) news
- [In Rails 5.1, Default Primary Keys Will Be 64 Bit](http://www.mccartie.com/2016/12/05/rails-5.1.html?utm_source=rubyweekly&utm_medium=email) news
- [JetBrains RubyMine 2016.3 Released: What's New?](https://www.jetbrains.com/ruby/whatsnew/?utm_source=rubyweekly&utm_medium=email) news 
Its debugger can now attach to Ruby processes started without debugger gems.
- [Testing and Deploying Docker Apps with Elastic Beanstalk](https://resources.codeship.com/ebooks/test-deploy-docker-apps-aws-elastic-beankstalk-ebs-aw/?utm_source=email-sponsorship&utm_medium=cpc-ruby-weekly-secondary&utm_campaign=cooper-docker-elastic-beanstalk) tutorial 
In this eBook you will learn how to prepare Elastic Beanstalk for Docker, how to build and push your Docker images to Docker Hub, and how to test and deploy your app to EBS with Codeship. CodeshipSponsored
- [3 Cool Things You Might Not Have Known About Rakefiles](http://www.codeotaku.com/journal/2016-12/cool-things-about-rakefiles/index?utm_source=rubyweekly&utm_medium=email) tutorial 
Chaining tasks, stateful tasks, and multiple task definitions. Samuel Williams
- [Erlix: Elixir and Ruby Together Again](https://blog.fazibear.me/elixir-ruby-dont-fight-talk-with-erlix-24b0f5ed8d12#.5ieq4zmmz?utm_source=rubyweekly&utm_medium=email) tutorial 
This article describes another way Elixir and Ruby can talk to each other. Michał Kalbarczyk
- [Understanding Monads By Example](http://beyondscheme.com/2016/monads-in-recurring-payment-handling?utm_source=rubyweekly&utm_medium=email) tutorial 
Refactoring a large conditional into a series of chainable monads. Artur Trzop
- [How To Override A Default Scope In Rails](https://solidfoundationwebdev.com/blog/posts/how-to-override-a-default-scope-in-rails?utm_source=rubyweekly&utm_medium=email) tutorial Weston Ganger
- [A Beginner's Guide to Exceptions in Ruby](http://blog.honeybadger.io/a-beginner-s-guide-to-exceptions-in-ruby/?utm_source=rubyweekly&utm_medium=email) tutorial Starr Horne
- [Zero Downtime Migrations with ActiveRecord and Postgres](https://tech.lendinghome.com/zero-downtime-migrations-with-activerecord-and-postgresql-b3aca53ffbe6#.bb4ovpt7q?utm_source=rubyweekly&utm_medium=email) tutorial Sean Huber
- [Using Materialized Views in Rails](http://blog.redpanthers.co/materialized-views-caching-database-query/?utm_source=rubyweekly&utm_medium=email) tutorial Harisankar P S
- [Data Structures and Big O Time Complexity](http://www.visuality.pl/posts/cs-lessons-002-data-structures?utm_source=rubyweekly&utm_medium=email) tutorial 
A solid explanation of Big O time complexity applied to different data structures. Michał Młoźniak
- [Webinar: Building a Multi-Database Application with Compose](https://attendee.gotowebinar.com/register/2860378778701698052?utm_source=cooper&utm_medium=newsletter&utm_content=ruby) 
​Learn how we can help you build battle hardened, open source data layers across leading cloud vendors. ComposeSponsored
- [Who Called Git? An Unusual Debugging Story](http://schneems.com/2016/11/28/who-called-git-an-unusual-debugging-story/?utm_source=rubyweekly&utm_medium=email) story Richard Schneeman
- [Building A Multiplayer 8 Bit Sequencer in Rails](http://marcgg.com/blog/2016/11/21/chiptune-sequencer-multiplayer/?utm_source=rubyweekly&utm_medium=email) story 
Done for Ruby Rampage. Marc G Gauthier
- [Deciding to Build an Isomorphic Ruby App with Opal](https://blog.gitresolve.com/deciding-to-build-an-isomorphic-ruby-app-with-opal-206befe93c8f#.nf2vf3r51?utm_source=rubyweekly&utm_medium=email) story GitResolve
- [Webpacker: Use Webpack to Manage App-like JS Modules in Rails](https://github.com/rails/webpacker?utm_source=rubyweekly&utm_medium=email) code 
First steps in Rails’ move to using Webpack and Yarn. Ruby on Rails
- [pure-ruby-nats: A Native Ruby Client Library for NATS](https://github.com/nats-io/pure-ruby-nats?utm_source=rubyweekly&utm_medium=email) code 
[NATS](https://nats.io/) is a high performance open source messaging system. NATS
- [Coverband: Rack Middleware to Measure Production Code Usage](https://github.com/danmayer/coverband?utm_source=rubyweekly&utm_medium=email) code Dan Mayer

Curated by [Peter Cooper](https://twitter.com/peterc) and [Glenn Goodrich](https://twitter.com/ruprict), and published by [Cooperpress](https://cooperpress.com/).
Send feedback by simply replying to this mail.
Want to sponsor an issue? See our [media kit.](https://cooperpress.com/mediakit)
Want to post a job? Email us or [use our self-serve system.](https://booking.cooperpress.com/jobs)

[Unsubscribe](*|UNSUB|*) | [Change email address](*|UPDATE_PROFILE|*) | [Read this issue on the Web](http://rubyweekly.com/issues/327)

© Cooperpress Ltd. Office 30, Lincoln Way, Louth, LN11 0LS, UK
[Email policy](https://cooperpress.com/spam.html) [Privacy policy](https://cooperpress.com/privacy.html)
