[preview] stats log json v0.4

Builds on #1200, replaces #1199 

Preview because we need to think about the JSON structure better.

Prscript:
- PR build: https://buildbot.openinfosecfoundation.org/builders/inliniac/builds/58
- PR pcaps: https://buildbot.openinfosecfoundation.org/builders/inliniac-pcap/builds/58