ExecSource don't flush the cache if there is no input entries
Review Request #8854 - Created Jan. 7, 2013 and updated
ExecSource has a default batchSize: 20, exec source read data from the source, then put it into the cache, after the cache is full, push it to the channel. but if exec source's cache is not full, and there isn't any input for a long time, then these entries always kept in the cache, there is no chance to the channel until the source's cache is full. so, the patch added a new config line: batchTimeout for ExecSource, and default is 3 seconds, if batchTimeout exceeded, push all cached data to the channel even the cache is not full.
|How does this help? The readLine() method would block until the next line is read from the process's stdout right? ...||Hari Shreedharan||Jan. 7, 2013, 10:20 p.m.||Open|