Skip to content
This repository has been archived by the owner on Jun 17, 2024. It is now read-only.

Commit

Permalink
Merge pull request #91 from feynmanliang/patch-1
Browse files Browse the repository at this point in the history
Make examples in README compile
  • Loading branch information
t3hnar authored May 17, 2017
2 parents e961560 + 35f1497 commit 1d9aff9
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -334,7 +334,7 @@ object StartTransactionExample extends App {
import akka.actor._
import eventstore.LiveProcessingStarted
import eventstore.tcp.ConnectionActor
import eventstore.{ IndexedEvent, SubscriptionActor }
import eventstore.{ IndexedEvent, Settings, SubscriptionActor }
import scala.concurrent.duration._

object CountAll extends App {
Expand Down Expand Up @@ -428,7 +428,7 @@ object MessagesPerSecond extends App {
val connection = EventStoreExtension(system).connection
val publisher = connection.allStreamsPublisher()

Source(publisher)
Source.fromPublisher(publisher)
.groupedWithin(Int.MaxValue, 1.second)
.runForeach { xs => println(f"${xs.size.toDouble / 1000}%2.1fk m/s") }
}
Expand All @@ -449,7 +449,7 @@ object ListAllStreamsExample extends App {
implicit val materializer = ActorMaterializer()
val connection = EventStoreExtension(system).connection
val publisher = connection.streamPublisher(EventStream.System.`$streams`, infinite = false, resolveLinkTos = true)
Source(publisher)
Source.fromPublisher(publisher)
.runForeach { x => println(x.streamId.streamId) }
.onComplete{ _ => system.terminate()}
}
Expand Down

0 comments on commit 1d9aff9

Please sign in to comment.