@Override
    public long getCurrentOutputSize() {
        if (wrappedSegmentOutputStream != null) {
            return wrappedSegmentOutputStream.getPosition();
        }
        return 0;
    }
Insert segment markers after the header and after every record.
stroom-pipeline/src/main/java/stroom/pipeline/writer/StreamOutput.java