Automatically choose most correct codec for bytestream inputs.

Now, if you try to use `plain` or `json` codecs with either `stdin` or
`tcp` inputs, it will automatically select `line` or `json_lines` codec
respectively.

Right now, many users try to use json codec with tcp input. This
*should* work, but due to technical limitations[1], it does not.
To compensate, we have always provided a json_lines codec to help
parse "streams of line-delimited json" which is what most folks
seem to be handling these days.

[1] I haven't found a JSON library capable of processing a byte stream.
Jackson has one, but it requires an input stream model which logstash
does not currently expose. Future work will make this possible.

Related: #1391
fix stdin message handling & specs

closes #1386
Pass correct HOME env into chroot

Without this patch the logstash isn't able to start on Debian 7 when using file input, as both HOME and SINCEDB_DIR aren't set in chroot.
Merge branch 'pr/1343'
closes #1343
initial spec for pipe input

removed logging

fixed encoding header

closes 1385
replace json parsers with JrJackson and Oj