changcheng / wro4j

Automatically exported from code.google.com/p/wro4j
0 stars 0 forks source link

Memory & Performance improvements #424

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
 Imagine we put the server live, its immediately going to get tons of page requests, including tons of css resource requests.

Expected behavior: 
- first request will trigger the processing.
- any subsequent request for the same group is blocked until the content is 
available.

Actual behavior:
- until the resource is not stored in cache, each request trigger the 
processing which causes high memory & cpu load.

Reported on mailing list: 
https://groups.google.com/forum/?fromgroups#!topic/wro4j/c_WRdK3ZPZk

Original issue reported on code.google.com by alex.obj...@gmail.com on 3 May 2012 at 7:14

GoogleCodeExporter commented 9 years ago

Original comment by alex.obj...@gmail.com on 5 May 2012 at 11:41

GoogleCodeExporter commented 9 years ago

Original comment by alex.obj...@gmail.com on 10 May 2012 at 7:01

GoogleCodeExporter commented 9 years ago
The following improvements were implemented:
- when multiple threads are trying to access the same group which require 
processing, only the first one will trigger processing while the others will be 
blocked until the first one is ready and will use cached content (if cache is 
enabled).

This improvement is important, especially when dealing with slow processors 
like: less, coffeeScript (based on rhino) or those based on jruby (sass).

Original comment by alex.obj...@gmail.com on 4 Jun 2012 at 1:28