Uploaded image for project: 'Camel'
  1. Camel
  2. CAMEL-6679

Issue when using ZipSplitter and sending entries to a file endpoint

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Minor
    • Resolution: Cannot Reproduce
    • 2.11.0
    • 2.13.0
    • camel-core
    • None
    • Unknown

    Description

      This issue was recorded on the forum on this link: http://camel.465427.n5.nabble.com/Issue-when-using-ZipSplitter-and-sending-entries-to-a-file-endpoint-td5738179.html#a5738183

      I am not sure at this point if this is only relevant to the the ZipSplitter, but that is how I stumbled upon this. If you use the ZipSplitter and send the entries to a file EndPoint the "Original File" entry does not come back.

      This code can be used to reproduce it:

      from("seda:decompressFiles").routeId("DecompressFiles") 
        .split(new ZipSplitter()).streaming().shareUnitOfWork() 
           .log("WE ARE SPLITTING!!!") 
           .to("file:{{ClientFileArchiveRoot}}?fileName=zipFileName") 
           //.to("activemq:queue:ZipChildFiles") //You can use seda or direct or here and it will still work correctly 
      ;
      

      //data.zip has two entries
      template.sendBody("seda:decompressFiles", new File("data.zip"));

      With this simple example as it stands it does not work. If you comment out the .to("file:...") and uncomment the next line, it will work.

      With a zip file with two entries you should get:
      [ad #0 - seda://decompressFiles] DecompressFiles INFO WE ARE SPLITTING!!!
      [ad #0 - seda://decompressFiles] DecompressFiles INFO WE ARE SPLITTING!!!

      if you comment the to("file:..") and uncomment the next line you will get:
      [ad #0 - seda://decompressFiles] DecompressFiles INFO WE ARE SPLITTING!!!
      [ad #0 - seda://decompressFiles] DecompressFiles INFO WE ARE SPLITTING!!!
      [ad #0 - seda://decompressFiles] DecompressFiles INFO WE ARE SPLITTING!!!

      which means it is working as expected on the second case.

      Attachments

        1. data.zip
          0.5 kB
          Abdiel E. Sanchez

        Activity

          People

            davsclaus Claus Ibsen
            abdiels Abdiel E. Sanchez
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: