Ecosyste.ms: Awesome

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

Awesome Lists | Featured Topics | Projects

https://github.com/brandonchinn178/resourcet-pool

Convert a Pool into an Acquire
https://github.com/brandonchinn178/resourcet-pool

Last synced: 25 days ago
JSON representation

Convert a Pool into an Acquire

Awesome Lists containing this project

README

        

DEPRECATED: `unliftio-pool` should be sufficient for most use-cases

# `resourcet-pool`

![Hackage](https://img.shields.io/hackage/v/resourcet-pool)

`resource-pool` provides the `Pool` abstraction, which performs resource allocation. Independently, `resourcet` provides the `Acquire` abstraction, which also performs resource allocation, but also plugs into the `MonadResource` type class. This library provides a way of converting a `Pool` into an `Acquire`, if using `Acquire` functions is easier for your application.

This library exports a single function

```hs
poolToAcquire :: Pool a -> Acquire a
```

which pretty much does what it says on the box.