Uploaded image for project: 'Cocoon 3 (Retired)'
  1. Cocoon 3 (Retired)
  2. COCOON3-68

calling setup on the pipeline overrides any parameters set on the individual pipeline component

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Not A Problem
    • None
    • None
    • cocoon-pipeline
    • None

    Description

      Below code demonstrates the issue.

      ByteArrayOutputStream baos = new ByteArrayOutputStream();
      Map<String, Object> parameters = new HashMap<String, Object>();
      parameters.put("sentence", "split words test");
      XQJGenerator generator = new XQJGenerator(this.getClass().getResource("/xquery/splitstring.xquery"));
      generator.setXQDataSource(xqds);
      generator.setup(parameters); // set parameters for this specific pipeline component [1]
      Pipeline<SAXPipelineComponent> pipeline = new NonCachingPipeline<SAXPipelineComponent>();
      pipeline.addComponent(generator);
      pipeline.addComponent(new XMLSerializer());
      pipeline.setup(baos); // this overrides the parameters set in [1] resulting in nullpointer exception
      pipeline.execute();

      Attachments

        Activity

          People

            Unassigned Unassigned
            robbypelssers Robby Pelssers
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: