https://github.com/nokia/akka-typed-persistence
Event sourcing for Akka Typed
https://github.com/nokia/akka-typed-persistence
actors akka-persistence scala
Last synced: 4 months ago
JSON representation
Event sourcing for Akka Typed
- Host: GitHub
- URL: https://github.com/nokia/akka-typed-persistence
- Owner: nokia
- License: apache-2.0
- Created: 2016-11-24T09:57:52.000Z (about 9 years ago)
- Default Branch: master
- Last Pushed: 2018-02-19T10:11:40.000Z (almost 8 years ago)
- Last Synced: 2025-07-27T16:50:53.559Z (5 months ago)
- Topics: actors, akka-persistence, scala
- Language: Scala
- Size: 66.4 KB
- Stars: 40
- Watchers: 9
- Forks: 5
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE.txt
Awesome Lists containing this project
README
# Akka Typed Persistence
[](https://gitter.im/nokia/akka-typed-persistence "Gitter chat")
**Event sourcing for Akka Typed**
This library implements actor persistence for
[Akka Typed](http://doc.akka.io/docs/akka/2.5.4/scala/typed.html)
with event sourcing. It provides:
* an actor definition API, which
* is integrated with Akka Typed,
* statically _type safe_,
* and _supports actor persistence_ (with event sourcing and snapshots);
* and an _implementation_ of this API
* based on `akka-typed` and `akka-persistence`.
A conference talk introducing the library was presented at
[Scala By the Bay](http://sched.co/7iUT) ([slides](https://t.co/IsENEuxShc)).
For the full code of the example in the talk, see
[this file](examples/src/main/scala/com/example/PingActor.scala).
## Motivation
[Akka Typed](http://doc.akka.io/docs/akka/2.5.4/scala/typed.html)
provides a type safe API for defining Akka actors. However, originally
it had no solution for actor persistence. The goal of this library was
exactly that: integrating Akka Typed and Akka Persistence. (Since then,
Akka Typed have been extended to include a
[persistence API](https://akka.io/blog/2017/10/13/typed-persistence).)
## Getting started
This library is currently not published, but you can use it by
depending on this git repository in sbt:
```scala
dependsOn(ProjectRef(uri("https://github.com/nokia/akka-typed-persistence.git#master"), "persistence"))
```
For how to use the library, see
[this example](examples/src/main/scala/com/example/PingActor.scala).
**Dependencies:**
* Scala 2.11 or 2.12
* Akka 2.5.4
* Cats 1.0.0-MF, cats-effect 0.4 and shapeless 2.3.2