(Bug 49566) Buffer serialized WT and write to response at the end

* Cleaned up dead state and some comments in selective serializer.
* Removed buffering in selective serializer and added output
  buffering in ParserService so this buffering is used when either
  serializer is used.

Change-Id: I944558d265b6329a87499ef9a38b4c5b9e34ca8f