RubyConf 08: Jamis Buck - Recovering from the Enterprise
Thursday, November 06 2008
The main idea of this talk was that working in the enterprise gets you used to certain solutions and its easy to try and apply those solutions in Ruby where they might not apply. Jamis worked in Java and when he came to Ruby he wanted to bring dependency injection to Ruby and wrote two different frameworks for Ruby to enable dependency injection.
The first he wrote was called Copland and was very much a Java library written in Ruby, one stat he mentioned was that there was 161 lines of YAML config for a 250 line ruby library. He presented it at RubyConf and the main recommendation was to get rid of the config and write it in Ruby. Jim Weirich went as far as to write a small sample of how he would do it, Jamis ran with the sample and created another library called Needle.
To try and show why these libraries were needed Jamis added Needle to his NET:SSH project. He went as far as to make the cryptography library configurable, even though there is only one ruby cryptography library. It's a classic example of of "enterprise thinking".
Jamis has since realized that he was trying to use Java solutions in a Ruby world. His analogy was that Java is like Legos and Ruby is like Play-Doh, you wouldn't mold Play-Doh into little blocks to build something... because you don't have the constraints that you have with Legos.
One great quote was "Just in time, not just in case" which is a nice re-statement of YAGNI.
UPDATE: Jamis has posted a great post summing up his talk.
-James
Comments
- #1 Dave D. on 11.07.2008 at 3:18 AM
-
"Just in time, not just in case"... quoteboard material if I ever heard it.
