@Override
    public void insertSegmentMarker() throws IOException {
        // Add a segment marker to the output stream if we are segmenting.
        if (segmentOutput) {
            if (wrappedSegmentOutputStream != null) {
                //This can happen if stream type isn't set due to incorrect / incomplete configuration
                wrappedSegmentOutputStream.addSegment();
            }
        }
    }
Insert segment markers after the header and after every record.
stroom-pipeline/src/main/java/stroom/pipeline/writer/StreamOutput.java