Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/evolution-gaming/pubsub
PubSub typesafe abstraction on top of akka DistributedPubSubMediator
https://github.com/evolution-gaming/pubsub
akka cluster pubsub
Last synced: 28 days ago
JSON representation
PubSub typesafe abstraction on top of akka DistributedPubSubMediator
- Host: GitHub
- URL: https://github.com/evolution-gaming/pubsub
- Owner: evolution-gaming
- License: mit
- Created: 2017-11-26T09:54:46.000Z (about 7 years ago)
- Default Branch: master
- Last Pushed: 2024-07-18T10:33:28.000Z (5 months ago)
- Last Synced: 2024-07-18T13:11:07.306Z (5 months ago)
- Topics: akka, cluster, pubsub
- Language: Scala
- Size: 224 KB
- Stars: 3
- Watchers: 10
- Forks: 2
- Open Issues: 37
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# PubSub
[![Build Status](https://github.com/evolution-gaming/pubsub/workflows/CI/badge.svg)](https://github.com/evolution-gaming/pubsub/actions?query=workflow%3ACI)
[![Coverage Status](https://coveralls.io/repos/github/evolution-gaming/pubsub/badge.svg?branch=master)](https://coveralls.io/github/evolution-gaming/pubsub?branch=master)
[![Codacy Badge](https://api.codacy.com/project/badge/Grade/5c1e3dc82255463f82583a3fa69fd56f)](https://www.codacy.com/app/evolution-gaming/pubsub?utm_source=github.com&utm_medium=referral&utm_content=evolution-gaming/pubsub&utm_campaign=Badge_Grade)
[![Version](https://img.shields.io/badge/version-click-blue)](https://evolution.jfrog.io/artifactory/api/search/latestVersion?g=com.evolutiongaming&a=pubsub_2.13&repos=public)
[![License: MIT](https://img.shields.io/badge/License-MIT-yellowgreen.svg)](https://opensource.org/licenses/MIT)The library is based on cats-effect 3 since 7.0.0 version, for cats-effect 2.x.x back ports use [series/6.x.x](https://github.com/evolution-gaming/pubsub/tree/series/6.x.x)
### Typesafe layer for DistributedPubSubMediator
```scala
trait PubSub[F[_]] {def publish[A: Topic : ToBytes](
msg: A,
sender: Option[ActorRef] = None,
sendToEachGroup: Boolean = false
): F[Unit]def subscribe[A: Topic : FromBytes : ClassTag](
group: Option[String] = None)(
onMsg: OnMsg[F, A]
): Resource[F, Unit]def topics(timeout: FiniteDuration = 3.seconds): F[Set[String]]
}
```### Ability to serialize/deserialize messages to offload akka remoting and improve throughput
Check `DistributedPubSubMediatorSerializing.scala`
## Setup
```scala
addSbtPlugin("com.evolution" % "sbt-artifactory-plugin" % "0.0.2")libraryDependencies += "com.evolutiongaming" %% "pubsub" % "7.0.0"
```## CHANGELOG
### 7.0.0
##### Upgrades
- cats-effect 2.5.4 to 3.3.11