Lighthouse has a new layout. Prefer the old one? Return to the old layout, and switch back any time from the link at the top of each page.

Luke Melia's latest activity

Wednesday, October 13 2010
2986 polymorphic_url should handle STI better was updated in Ruby on Rails
  • Luke Melia
    Luke Melia commented at 7:58 PM

    I never got anywhere on the Rails 3 compatible approach due to lack of time. We're upgrading our app to Rails 3 soonish, so hopefully I can dig in and take a cr...

Friday, October 08 2010
3332 Add options[:procs] to to_json was updated in Ruby on Rails
  • Luke Melia
    Luke Melia commented at 10:28 PM

    Agreed, Jose. When I ran into this problem, I initially set out to unify the interfaces, but quickly saw that the internals are so different that it was not an ...

  • Luke Melia
    Luke Melia commented at 10:18 PM

    I think the common use case is building an API for your web app that supports output in either xml or json. Ideally, you could use the same types of options bot...

Wednesday, April 14 2010
4396 Repeated SHOW FIELDS FROM... queries with STI was updated in Ruby on Rails
  • Luke Melia
    Luke Melia commented at 11:17 PM

    We have about 300 models in our app. About a third of them are subclasses. I started looking at this today because these queries popped up in some New Relic tra...

  • Luke Melia
    Luke Melia commented at 7:14 PM

    @foca, yep, my proposed solution actually takes advantage of that "feature" of class variables. It uses a single hash for the entire inheritance hierarchy, with...

  • Luke Melia
    Luke Melia created the ticket at 6:17 PM

    ActiveRecord looks up the columns for a table each time it loads a class using that table
    With STI, this means repeated calls to 'SHOW FIELDS FROM table_name' f...

Monday, August 03 2009
2986 polymorphic_url should handle STI better was updated in Ruby on Rails
  • Luke Melia
    Luke Melia commented at 7:31 AM

    I'll take a look at implementing on top of rack-mount. Handling (1) on 2.x will require major surgery the routing engine that seems dubious given a different ap...

  • Luke Melia
    Luke Melia created the ticket at 5:38 AM

    If I have a class Project and a subclass SpecialProject, but only map.resources :projects defined in routes, it seems natural that polymorphic_url(@special_proj...

Friday, May 29 2009
2737 Don't load ActiveRecord::SessionStore during intialization if it's not used b... was created in Ruby on Rails
  • Luke Melia
    Luke Melia created the ticket at 3:02 PM

    Our app uses CookieStore but I noticed that ActiveRecord::SessionStore was still being loaded (with the DB reflection overhead associated with loading an AR cla...