https://github.com/am-kantox/agency
One more unnecessary abstraction on top of `Agent`
https://github.com/am-kantox/agency
agent elixir elixir-lang state-management
Last synced: 8 months ago
JSON representation
One more unnecessary abstraction on top of `Agent`
- Host: GitHub
- URL: https://github.com/am-kantox/agency
- Owner: am-kantox
- Archived: true
- Created: 2020-03-17T08:17:25.000Z (over 6 years ago)
- Default Branch: master
- Last Pushed: 2023-01-06T14:44:17.000Z (over 3 years ago)
- Last Synced: 2025-10-19T01:00:37.418Z (8 months ago)
- Topics: agent, elixir, elixir-lang, state-management
- Language: Elixir
- Size: 81.1 KB
- Stars: 2
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
#  ~~Agency~~
Obsoleted by [`PartitionSupervisor`](https://hexdocs.pm/elixir/PartitionSupervisor.html)
## Introduction
`Agency` is an abstraction layer above `Agent` allowing to use any
container supporting `Access` behind and simplifying the client API
handling.
`Agency` itself implements `Access` behaviour, making it possible to
embed instances in the middle of `Access.keys` chains.
In a nutshell, `Agency` backs up the `Agent` holding a container.
All the standard CRUD-like calls are done through containers’
`Access` implementation, allowing transparent shared access.
The set of `after_***/1` functions are introduced, so that the main
`Agent` feature distinguishing it from the standard `GenServer`
holding state—namely, a separation of client and server APIs—is
exposed transparently to the consumers.
## Installation
```elixir
def deps do
[
{:agency, "~> 0.1"}
]
end
```
### Changelog
- **`0.3.1`** `Agency.Multi` support is not optional anymore
- **`0.3.0`** `Agency.Multi` supporting the locally distributed agency (eliminating `:gen_server` mailbox bottleneck)
## [Documentation](https://hexdocs.pm/agency).