On Wed, Feb 15, 2012 at 9:25 AM, Willem <[email protected]> wrote:
> Hi,
>
> It looks like there are some short coming of the Zip data format which 
> doesn't support to combine the files together.

Yes the zip data format does not support files per see. For that we
would need to improve the data format.
As you would need to use special file zip API from the JDK for that.
http://docs.oracle.com/javase/6/docs/api/

We should probably look into this. Contributions is of course welcome.



\> BTW, I'm still interesting about the agggregatorStrategy that you use.
> Can you show me the code ?
>
> Willem
> ----------------------------------
> FuseSource
> Web: http://www.fusesource.com
> Blog: http://willemjiang.blogspot.com (English)
>          http://jnn.javaeye.com (Chinese)
> Twitter: willemjiang
> Weibo: willemjiang
>
> On Feb 15, 2012, at 3:30 PM, Lars wrote:
>
>> Hi,
>>
>> I have deleted much of the "crap" and converted to file endpoint ( see
>> below). However the produced zip-file is still unreadable. However, if I
>> convert to gzip marshalling the file is readable. What is wrong with the zip
>> marshalling?
>>
>>
>>       <camelContext id="camel" xmlns="http://camel.apache.org/schema/spring";>
>>               <route streamCache="true">
>>                       <from uri="{{file.inbox}}" />
>>                       <aggregate strategyRef="aggregatorStrategy"
>>                               completionTimeout="5000" completionSize="5">
>>                               <correlationExpression>
>>                                       <constant>true</constant>
>>                               </correlationExpression>
>>                               <marshal>
>>                                       <zip></zip>
>>                               </marshal>
>>                               <setHeader headerName="CamelFileName">
>>                                       <simple>${file:name}.zip</simple>
>>                               </setHeader>
>>                               <to uri="{{file.outbox}}" />
>>                       </aggregate>
>>               </route>
>>       </camelContext>
>>
>> Best regards
>>
>> Lars Stuevold
>>
>> --
>> View this message in context: 
>> http://camel.465427.n5.nabble.com/Zipping-the-content-of-several-files-into-one-file-tp5481638p5485128.html
>> Sent from the Camel - Users mailing list archive at Nabble.com.
>



-- 
Claus Ibsen
-----------------
FuseSource
Email: [email protected]
Web: http://fusesource.com
Twitter: davsclaus, fusenews
Blog: http://davsclaus.blogspot.com/
Author of Camel in Action: http://www.manning.com/ibsen/

Reply via email to