Skip to content

Instantly share code, notes, and snippets.

@vangberg
Created December 7, 2012 09:26
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save vangberg/4232080 to your computer and use it in GitHub Desktop.
Save vangberg/4232080 to your computer and use it in GitHub Desktop.
# config/boot.rb
if ENV["MANUAL_GC"].to_i == 1
GC.disable
Thread.new {
while true
sleep 2
GC.enable
GC.start
GC.disable
end
}
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment