| Safe Haskell | None |
|---|---|
| Language | Haskell2010 |
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
- runFlow :: forall c eff ex a b. (Coordinator c, Exception ex) => c -> Config c -> ContentStore -> (eff ~> AsyncA IO) -> Int -> Flow eff ex a b -> a -> IO (Either ex b)
- runFlowEx :: forall c eff ex a b. (Coordinator c, Exception ex) => c -> Config c -> ContentStore -> (eff ~> AsyncA (KatipContextT IO)) -> Int -> Flow eff ex a b -> a -> KatipContextT IO b
- runSimpleFlow :: forall c a b. Coordinator c => c -> Config c -> ContentStore -> SimpleFlow a b -> a -> IO (Either SomeException b)
- withSimpleLocalRunner :: Path Abs Dir -> ((SimpleFlow a b -> a -> IO (Either SomeException b)) -> IO c) -> IO c
Documentation
Arguments
| :: (Coordinator c, Exception ex) | |
| => c | |
| -> Config c | |
| -> ContentStore | |
| -> (eff ~> AsyncA IO) | Natural transformation from wrapped effects |
| -> 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 | |
| -> IO (Either ex b) |
Run a flow, discarding all logging.
Arguments
| :: (Coordinator c, Exception ex) | |
| => c | |
| -> Config c | |
| -> ContentStore | |
| -> (eff ~> AsyncA (KatipContextT IO)) | Natural transformation from wrapped effects |
| -> 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 | |
| -> KatipContextT IO b |
Simple evaulation of a flow
runSimpleFlow :: forall c a b. Coordinator c => c -> Config c -> ContentStore -> SimpleFlow a b -> a -> IO (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.