The endDocument()event never gets activated (even when using the included sample implementation code) due to a small bug in JsonStreamingParser.cpp
Inside function JsonStreamingParser::endObject(), change line 277 from
if (stackPos == -1) {
to
if (stackPos == 0) {