shuyangzhou/liferay-portal — pull request #213 by zberentey (2013-01-11 16:01:07+00:00)
Title: DELAYED-BUFFERED-INC

Hi Shuyang, could you take a look at this enhancement to batchable pipe? This is one part of a solution to get rid of the problems a lot of customers are facing regarding asset and DL download counters. The other part of the solution will probably be to use a separate table for the counter (such as social activity) and create an additional entry in lucene without the contents but with the counter that could be updated and used for ordering instead of going to the database. This part could be an option until then, which the customer could fine tune (i.e. the value threshold and/or the timeout for the delayed write) There is one thing missing, which is a shutdown hook, so that we flush the delayed queue on shutdown. Thanks.