@Override
    public void startDocument() throws SAXException {
        try {
            hasOutputRoot = false;
            depth = 0;
            startBuffer();
        } finally {
            super.startDocument();
        }
    }
Filters out records that have raised an error or warning during processing.
stroom-pipeline/src/main/java/stroom/pipeline/filter/RecordOutputFilter.java