Update tcp.rb
LOGSTASH-1066 - fix debug puts statement and whitespace
Merge pull request #575 from jlscott3/LOGSTASH-1066

LOGSTASH-1066 - fix debug puts statement and whitespace
Revert "Revert "- use more let() statements instead of local scoping things""

This reverts commit 87c46c3345e0281fb89d8f48be1b5b3126be6f5d.
Make LogStash::Pipeline more multiple-instance friendly. I think there
was a bug that doing eval("def filter ...") would override the method
of all existing pipelines, which is bad.

Now filter and output implementations (from a pipeline) are compiled to
@filter_func and @output_func.
Fix a pretty bad bug (found by the tests, yay!) that allowed sharing of
default values (like hashes) across plugin instances. This bug only
really impacted tests, but was important to fix for the future where
logstash might support multiple pipelines (or reloads).
- can't yield in a lambda (the way we're doing things), give the block
instead.
- update to reflect new defaults (no tags by default and grok has
'singles' enabled by default)
Merge pull request #574 from hantuo/master

[fix] tcp out retry
Remove prints from tests
Add guard
- add require
Various fixes to generated .deb packages

This resolves a few inconsistencies and issues in the generated packages
for Debian/Ubuntu:

  * Creates /etc/logstash/conf.d
  * Installs a basic defaults file in /etc/default/logstash (which also sets HOME)
  * Stops creating /var/run/logstash (unused)
  * Uses /var/lib/logstash as the home directory of the logstash user instead of /home/logstash
  * Defaults package files to be owned by root, fixes ownership in post-install script
  * Properly stops service when removing the package on Debian

The end result is that after installing, LogStash will pretty much "just
work" with only 2 changes:

1) Enable START=yes in /etc/default/logstash
2) Provide a config for the LogStash agent