public Output create(final OutputStream innerOutputStream,
                         final AttributeMap attributeMapOverride) throws IOException {
        final Output output;
        if (useCompression) {
            if (compressionMethod.equalsIgnoreCase(COMPRESSION_ZIP)) {
                if (attributeMapOverride != null) {
                    output = new ZipOutput(attributeMapOverride, innerOutputStream);
                } else {
                    output = new ZipOutput(metaDataHolder, innerOutputStream);
                }
            } else {
                try {
                    output = new BasicOutput(new CompressorStreamFactory()
                            .createCompressorOutputStream(compressionMethod, innerOutputStream));
                } catch (final CompressorException e) {
                    throw new IOException(e);
                }
            }
        } else {
            output = new BasicOutput(innerOutputStream);
        }
        return output;
    }
@param attributeMapOverride If supplied these attributes will be used rather than those in the metaHolder
stroom-pipeline/src/main/java/stroom/pipeline/writer/OutputFactory.java