Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/mkende/perl_parallel_task_executor

Cross-platform executor for parallel tasks executed in forked processes.
https://github.com/mkende/perl_parallel_task_executor

executor fork ipc perl promise

Last synced: 3 days ago
JSON representation

Cross-platform executor for parallel tasks executed in forked processes.

Awesome Lists containing this project

README

        

# Parallel::TaskExecutor

Cross-platform executor for parallel tasks executed in forked processes.

## Summary

This module provides a simple interface to run Perl code in forked processes and
receive the result of their processing. This is quite similar to
[Parallel::ForkManager](https://metacpan.org/pod/Parallel::ForkManager) with a
different OO approach, more centered on the task object that can be seen as a
very lightweight promise.

## Example

```perl
my $executor = Parallel::TaskExecutor->new();
my $task = $executor->run(sub { return 'foo' });
$task->wait();
is($task->data(), 'foo');
```

## Documentation

See
[this module documentation on CPAN](https://metacpan.org/pod/Parallel::ForkManager).