Add recurse method for doing breadth-first traversal of the AST

This will be used by the filter flush compiler
Add generation of a flush lambda for each filter.

This allows filters to flush and have any generated events proceed
downward through the config as you would expect, respecting any
branches or future plugins.
Die on IOError which occurs when reading from a closed STDIN
Make filter_flusher invoke the new (and correct, I hope!) way to flush.

- On shutdown, we will also flush all filters.
- The flusher thread will terminate if we are shutting down.
Clarify the comment
Fix comment generation in the code to avoid newlines.
Add 'max_age' setting to multiline for flushing.

This setting chooses how long (in seconds) an event is considered to be
fresh before it will be automatically flushed.

This is useful for:
* slow log sources to get the 'last event' flushed,
* transaction-id-style events that have no obvious "end" event and also
  are mixed among other-id events in the same stream.

Also:
- Make filters have no teardown by default.
- Remove 'enable_flush' since it is not needed anymore; flush is always
  enabled.
Merge remote-tracking branch 'jordansissel/feature/filter-flushing-execution'

Fix conditions in metrics (flush)

* jordansissel/feature/filter-flushing-execution:
  Add 'max_age' setting to multiline for flushing.
  Fix comment generation in the code to avoid newlines.
  Clarify the comment
  Make filter_flusher invoke the new (and correct, I hope!) way to flush.
  Die on IOError which occurs when reading from a closed STDIN
  Add generation of a flush lambda for each filter.
  Add recurse method for doing breadth-first traversal of the AST
Improved Logic