Thread Previous • Date Previous • Date Next • Thread Next |
On Nov 29, 2011, at 11:55 AM, Vishvananda Ishaya wrote: … some stuff I agree with, then... > something like db.interfaces_get_by_instance(id, hint='fixed_ip'), This is very similar to ActiveRecord. In a case like this you would say Instance.find(id, :include => :fixed_ip) If you are including the hint, why not just populate those models in the initial query? Something like db.instances_by_id_including_fixed_ips(id) or db.instances_by_id_including_vifs(id) or whatever. Aaron Lee
Thread Previous • Date Previous • Date Next • Thread Next |