[kepler-dev] a few questions

Ilkay Altintas altintas at sdsc.edu
Sun Jan 29 20:53:30 PST 2006


Hi Tristan,

On Jan 29, 2006, at 8:41 PM, Tristan King wrote:

> Hi everyone,
>
> Just a few questions.
>
> I'm looking to do the following:
> 	
> 	for ever {
> 		Poll a Directory for new files
> 		when new file is located {
> 			Run workflow with new files as input
> 		}
> 	}
>
> What i need to know is:
>
> 1. Is this best preformed using a director to preform the loops? Or is

PN would be the best director to perform this. You can have the  
directory listing actor to perform infinitely (or until a stop  
condition occurs), and that actor will keep on producing inputs for the  
rest of the workflow.

> it possible to use some sort of flow control actors to direct the flow
> back to the directory poller? If a director should be used, which one
> and how should it be configured?

You don't need a backwards loop. The directory list actors will queue  
until the next actor consumes it. You can put a sleep parameter to the  
actor if you don't want it to fire to soon.

You don't have to do any configuration in the PN actor. Just check that  
the postfire of the directory listing actor returns true all the time  
for running it forever (or  until a stop condition to stop it after a  
while).


> note that (as implied in my psuedo code) the loop may want to continue
> forever.
>
> 2. Is it possible to run particular sections in seperate threads? i.e.
> new file is found -> make thread to process new file -> main thread  
> goes
> back to polling for new files. Are there any actors that do this
> already, or do you think it's possible to write one?

PN director will automatically create different threads for each actor.  
You don't have to do it.

> 3. Can workflows be run as a non-gui service? i.e. like a web server.

Yes.  There is a command line version.

Also, Efrat has created services to run the GEON workflows as web  
services using a wrapper similar to the command line version.

Cheers,
-ilkay

> This could be a simple dirty solution to problem 2. i.e. just have the
> directory polling workflow run a command line version of kepler  
> starting
> up a workflow to process the new files.
>
> any other thoughts and ideas you might have for my situation could be
> helpful too :)
>
> thanks
> --Tristan
>
> --  
> Tristan King                            | Ph: (07) 4781 6911
> Information Technology and Resources    | Email:  
> Tristan.King at jcu.edu.au
> James Cook University                   |
> Townsville QLD 4814                     |
> Australia                               |
>
> _______________________________________________
> Kepler-dev mailing list
> Kepler-dev at ecoinformatics.org
> http://mercury.nceas.ucsb.edu/ecoinformatics/mailman/listinfo/kepler- 
> dev



More information about the Kepler-dev mailing list