Rails 3.1, memory leak for missing local partial variables (Ruby 1.9.2-p290)

前端 未结 1 1888
青春惊慌失措
青春惊慌失措 2021-01-22 17:03

If I render a partial like so:

= render :partial => \"event_news_item\", :object => event, :variable => true

And then reference variable in the partial

1条回答
  •  终归单人心
    2021-01-22 17:43

    I have seen a really bad memory leak in similar environment. I've tracked it to the innocently looking association fetch (comment.author, to be precise), then tried to debug it for some time, and finally gave up and ran on 1.9.3-rc1.

    Surprisingly, that fixed this particular memory leak, and, moreover, reduced the unicorns' startup size by 15M (from 85M to 70M; i386).

    0 讨论(0)
提交回复
热议问题