A collection of notes and references for my talk “Exceptional Ruby”, on failure handling in Ruby programs.
I’ve written an eBook inspired by this talk. “Exceptional Ruby” contains over 100 pages of information on how to master the art of handling failure in Ruby. It includes a ton of material I couldn’t fit in the talk, so if you enjoyed the talk you should check it out!
Here’s a video I made of the talk. It’s a slightly earlier version than the one I delivered at Magic Ruby, but the bulk of the content is the same.
Slides from the original MagicRuby 2011 version can be found here.
Slides from the more recent RubyConf 2011 version of the talk can be found here.
- Code Completeby Steve McConnell has lots of great advice for how to think about failure handling.
- The Practice of Programming by Kernighan & Pike has some good things to say on the subject.
- As does The Pragmatic Programmer by Dave Thomas and Andy Hunt
- Release It! by Michael Nygard is an indispensable guide to architecting your applications to be robust in the face of failures and user abuse.
- Object-Oriented Software Construction is one of the seminal books on Object Oriented design and, and is of particular interest to Rubyists since the language it specifies — Eiffel — strongly influenced Ruby’s exception mechanism.
- Exceptions Shouldn’t be Expected, by Jared Carroll
- Save bang your head, ActiveRecord will drive you mad by Jared Carroll
- How Slow are Ruby Exceptions? by Simon Carletti
- Making Wrong Code look Wrong by Joel Spolsky. This is a great article, even though I disagree with his conclusions about exceptions.
- How to get an always up-to-date listing of Ruby exception classes, from Nick Sieger
- WikiWiki is always a trove of information on software thought. Some interesting starting points for failure handling include: AvoidExceptionsWheneverPossible, NullCatchClause, ConvertException, NestedException
- Wikiepedia on Exception Safety