private DocRef getEventPipeline(final String feedName,
                                    final TextConverterType textConverterType,
                                    final Path translationTextConverterLocation,
                                    final Path translationXsltLocation,
                                    final Path flatteningXsltLocation,
                                    final List<PipelineReference> pipelineReferences) {
        final DocRef pipelineRef = getPipeline(feedName, EVENT_DATA_PIPELINE);
        final PipelineDoc pipelineDoc = pipelineStore.readDocument(pipelineRef);

//        final Tuple2<DocRef, PipelineDoc> pipelineRefAndDoc = duplicatePipeline(
//                new DocRef(PipelineDoc.DOCUMENT_TYPE, EVENT_DATA_TEXT_PIPELINE_UUID),
//                feedName);
//        final PipelineDoc pipelineDoc = pipelineRefAndDoc._2();

        // Setup the text converter.
        final DocRef translationTextConverterRef = getTextConverter(feedName, textConverterType,
                translationTextConverterLocation);

        // Setup the xslt.
        final DocRef translationXSLT = getXSLT(feedName, translationXsltLocation);
        final DocRef flatteningXSLT = getXSLT(feedName + "_FLATTENING", flatteningXsltLocation);

        // Read the pipeline data.
        final PipelineData pipelineData = pipelineDoc.getPipelineData();

        // Change some properties.
        if (translationTextConverterRef != null) {
            // final ElementType elementType = new ElementType("Parser");
            // final PropertyType propertyType = new PropertyType(elementType,
            // "textConverter", "TextConverter", false);
            pipelineData.addProperty(PipelineDataUtil.createProperty(CombinedParser.DEFAULT_NAME, "textConverter",
                    translationTextConverterRef));
        }
        if (translationXSLT != null) {
            // final ElementType elementType = new ElementType("XSLTFilter");
            // final PropertyType propertyType = new PropertyType(elementType,
            // "xslt", "XSLT", false);
            pipelineData.addProperty(PipelineDataUtil.createProperty(
                    "translationFilter",
                    "xslt",
                    translationXSLT));
        }
        if (pipelineReferences != null) {
            for (final PipelineReference pipelineReference : pipelineReferences) {
                pipelineData.addPipelineReference(pipelineReference);
            }
        }
        if (flatteningXSLT != null) {
            // final ElementType elementType = new ElementType("XSLTFilter");
            // final PropertyType propertyType = new PropertyType(elementType,
            // "xslt", "XSLT", false);
            pipelineData.addProperty(PipelineDataUtil.createProperty(
                    "flattenFilter",
                    "xslt",
                    flatteningXSLT));
        } else {
            pipelineData.removeLink(PipelineDataUtil.createLink("writeRecordCountFilter", "flattenFilter"));
        }
        // final ElementType elementType = new ElementType(
        // "StoreAppender", false, true);
        // final PropertyType feedPropertyType = new PropertyType(elementType,
        // "feed", "Feed", false);
        pipelineData.addProperty(PipelineDataUtil.createProperty("storeAppender",
                "feed",
                new DocRef(null, null, feedName)));

        // final PropertyType streamTypePropertyType = new PropertyType(
        // elementType, "streamType", "StreamType", false);
        pipelineData.addProperty(PipelineDataUtil.createProperty("storeAppender",
                "streamType",
                StreamTypeNames.EVENTS));

        // // Write the pipeline data.
        // final ByteArrayOutputStream outputStream = new
        // ByteArrayOutputStream();
        // pipelineDataWriter.write(pipelineData, outputStream);
        // data = outputStream.toString();
        //
        // pipeline.setMeta(data);

        pipelineStore.writeDocument(pipelineDoc);

//        return pipelineRefAndDoc._1();
        return pipelineRef;
    }
Adds event data to a stream store.

@param feedName                         The feed name to use.
@param translationTextConverterType     Type of text converter
@param translationTextConverterLocation The Text Converter location
@param translationXsltLocation          The XSLT location
@param dataLocation                     The event data location.
@param referenceFeeds                   The reference feeds used.
@return An event feed definition.
@throws IOException Thrown if files not found.
stroom-app/src/test/java/stroom/test/StoreCreationTool.java