[kepler-dev] Getting a file from eml2datasource

Dan Higgins higgins at nceas.ucsb.edu
Wed Nov 24 11:07:02 PST 2004

Hi all,

 I was trying to figure out how to download a file using the ByteArray 
mode of the eml200datasoure. Basically on would create a workflow like 
the one shown below. One sets the 'outputType' parameter of the 
datasource as "Byte Array" and the 'append' attribute of the 
BimaryFileWriter to 'true'. The problem is that for a big file, the data 
is saves in a series of arrays, each of which triggers and output of the 
file name "Test.out". Workflows to the right of the file writer really 
only want to know when the complete file is availble (i.e. a single 
token with the file name).


A scheme for creating a single file name token when the file has been 
completely copied is shown below. It uses the BooleanSwitch actor and 
the EndOfStream port to create a single output token. Does anyone have a 
better way of doing this?
(I know the file is already archives in the cache and we should have a 
way to just reference it from an actor.)

Dan Higgins                                  higgins at nceas.ucsb.edu
http://www.nceas.ucsb.edu/    Ph: 805-892-2531
National Center for Ecological Analysis and Synthesis (NCEAS) 
735 State Street - Room 205
Santa Barbara, CA 93195

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mercury.nceas.ucsb.edu/ecoinformatics/pipermail/kepler-dev/attachments/20041124/79f09580/attachment.htm
-------------- next part --------------
A non-text attachment was scrubbed...
Name: binaryfile1.gif
Type: image/gif
Size: 12892 bytes
Desc: not available
Url : http://mercury.nceas.ucsb.edu/ecoinformatics/pipermail/kepler-dev/attachments/20041124/79f09580/binaryfile1.gif
-------------- next part --------------
A non-text attachment was scrubbed...
Name: binaryfile2.gif
Type: image/gif
Size: 13443 bytes
Desc: not available
Url : http://mercury.nceas.ucsb.edu/ecoinformatics/pipermail/kepler-dev/attachments/20041124/79f09580/binaryfile2.gif

More information about the Kepler-dev mailing list