Hello. I am having a problem with my asset compilation. It seems to be nesting asset directories inside each other, so it takes forever and I wind up with something like RAILS_ROOT/public/assets/assets/assets
I do not know what is causing this asset issue and I cannot google it very successfully. Has anyone seen this before? Could it be a problem with require_tree statements in my application.css.scss?
Maybe "require_tree ." and "require_self" are bad together, but it doesn't seem to fix the problem when I change them. What could cause asset directories to nest three or four deep on an asset precompile?
Although ... it did just finish much faster than it ever did before ... however, it still nested itself three times.
gwillen: It seems that the answer was "Ruby garbage collection" in case anyone is wondering.
I was googling phrases around random rails response times. I put a before and after filter on my app to report garbage collection times during a request. Fast calls have zero, slow calls have the ~200ms spent on GC.
I'm using REE. I don't know if this is REE-specific but the code "GC.enable_stats" + "GC.time" then I put it in the Rails log. This is the page that told me about those methods: http://www.rubyenterpriseedition.com/documentation.html#_garbage_collector_and_object_space
fryguy: I hear you. Not really my decision. Dinosaur technology at work. I'm making what improvements I can.
RubNoob: are you sure that your request is :remote => true or some other kind of ajax request and not a hard link?
Howdy Rails folks. I am having trouble understanding response times on my local machine. The page load time is either 100ms OR 300ms. It seems kind of random. Even in production mode there is a 200ms variability, but no other duration. I have tried prioritizing the process ID of the server and no change.
I was wondering if this was normal. I am not skilled at profiling my app. Any advice or references to sources I should read is appreciated.
Also, the profilers say that when it DOES take the longer duration the piece of code that delay happens is is random. Sometimes the #index action, sometimes rendering the template, sometimes in a SQL request.
Could my system be randomly assigning the processor to different things? Is that normal on a Mac?