funflow-1.5.0: Workflows with arrows

Safe HaskellNone
LanguageHaskell2010

Control.Funflow.Exec.Simple

Description

This module contains the means to execute a pipeline.

You should probably start with withSimpleLocalRunner and runSimpleFlow. The other functions in this module provide more flexible versions of runSimpleFlow.

Synopsis

Documentation

runFlow Source #

Arguments

:: (Coordinator c, Exception ex, MonadIO m, MonadBaseControl IO m, MonadCatch m, MonadMask m, Cacher (KatipContextT m) remoteCache) 
=> c 
-> Config c 
-> ContentStore 
-> remoteCache 
-> (eff ~> AsyncA m)

Natural transformation from wrapped effects

-> Maybe Int

Flow configuration identity. This forms part of the caching system and is used to disambiguate the same flow run in multiple configurations.

-> Flow eff ex a b 
-> a 
-> m (Either ex b) 

Run a flow, discarding all logging.

runFlowEx Source #

Arguments

:: (Coordinator c, Exception ex, MonadIO m, MonadBaseControl IO m, MonadCatch m, MonadMask m, KatipContext m, Cacher m remoteCache) 
=> c 
-> Config c 
-> ContentStore 
-> remoteCache 
-> (eff ~> AsyncA m)

Natural transformation from wrapped effects

-> Maybe Int

Flow configuration identity. This forms part of the caching system and is used to disambiguate the same flow run in multiple configurations. If Nothing, then it means this flow has no identity, this implies that steps will be executed without cache, and external tasks will all be considered impure.

-> Flow eff ex a b 
-> a 
-> m b 

Simple evaulation of a flow

runSimpleFlow :: forall m c a b. (Coordinator c, MonadIO m, MonadBaseControl IO m, MonadCatch m, MonadMask m) => c -> Config c -> ContentStore -> SimpleFlow a b -> a -> m (Either SomeException b) Source #

Run a simple flow. Logging will be sent to stderr

withSimpleLocalRunner Source #

Arguments

:: Path Abs Dir

Path to content store

-> ((SimpleFlow a b -> a -> IO (Either SomeException b)) -> IO c) 
-> IO c 

Create a full pipeline runner locally. This includes an executor for executing external tasks. This function is specialised to SimpleFlow since in cases where a custom term algebra is in use, we assume that probably a centralised coordinator and external runners may be desired as well.