LoneStarRuby Conf 2010 - Rails' Next Top Model: Using ActiveModel and ActiveRelation by: Adam Keys

Channel:
Subscribers:
42,400
Published on ● Video Link: https://www.youtube.com/watch?v=Pu5V0SYbGc8



Duration: 34:50
73 views
0


Rails jumped on the scene five years ago in part due to excellent support for connecting database tables to Ruby classes via ActiveRecord. Rails 3 makes two major improvements to this support. ActiveModel makes it easy to turn any old object into one that looks like ActiveRecord to your Rails app. ActiveRelation makes many kinds of queries easier and makes it possible to write some queries that were very difficult in the past.

In this talk, we'll learn how to build our own model layer using ActiveRelation and ActiveModel. We'll start by learning how ARel works and how to use it. Then we'll write an adapter for our own database. Next, we'll see what ActiveModel provides and how we use it through ActiveRecord. With this in mind, we'll add functionality to our models that make them look just like ActiveRecord to our Rails app.

In the end, we'll have a good grasp on the new options for modeling data in Rails 3 and how we can use that to write cleaner apps.




Other Videos By Confreaks


2015-04-07Rocky Mountain Ruby 2011 - Focus? Why Do I Need More Stinkin' Focus? by: Mike Gehard
2015-04-07Rocky Mountain Ruby 2011 - Active Hash by: Jeff Dean
2015-04-07Rocky Mountain Ruby 2011 - Be Moar Ridiculous by: Anthony Navarre
2015-04-07Rocky Mountain Ruby 2011 - BDSM Project SM Framework by: Wayne E.Wayne E. Seguin
2015-04-07Rocky Mountain Ruby 2011 - Lightning Talk: Do Your Commit Messages Suck by: Ryan McGeary
2015-04-07Rocky Mountain Ruby 2011 - Lightning Talk: In Defense of Unless by: Spike Ilacqua
2015-04-07Rocky Mountain Ruby 2011 - Lightning Talk: Deprecatable by: Jeremy Hinegardner
2015-04-07LoneStarRuby Conf 2010 - "Get your facts first...
2015-04-07LoneStarRuby Conf 2010 - How to Build a Sustainably Awesome Development Team
2015-04-07LoneStarRuby Conf 2010 - Deciphering Yehuda by: Gregg Pollack
2015-04-07LoneStarRuby Conf 2010 - Rails' Next Top Model: Using ActiveModel and ActiveRelation by: Adam Keys
2015-04-07LoneStarRuby Conf 2010 - Real Software Engineering by: Glenn Vanderburg
2015-04-07LoneStarRuby Conf 2010 - Beehive, scalable application deployment by: Ari Lerner
2015-04-07LoneStarRuby Conf 2010 - Components in a Monolithic World by: Nick Sutterer, Kevin Triplett
2015-04-07LoneStarRuby Conf 2010 - JSON and the Argonauts - Building Mashups with Ruby by: Wynn Netherland
2015-04-07LoneStarRuby Conf 2010 - Grease your Suite: Tips and Tricks for Faster Testing by: Nick Gauthier
2015-04-07LoneStarRuby Conf 2010 - Keynote Address by: Tom Preston-Werner
2015-04-07LoneStarRuby Conf 2010 - Seven Languages in Seven Weeks by: Bruce Tate
2015-04-07LoneStarRuby Conf 2010 - Taking Mongoid into the Future by: Bernerd Schaefer
2015-04-07LoneStarRuby Conf 2010 - Battle of NoSQL stars: Amazon's SDB vs Mongoid vs CouchDB vs RavenDB
2015-04-07RubyConf 2010 - Consuming Gherkin: One Byte at a Time by: Greg Hnatiuk, Mike Sassak