Hello,

has anyone succeded at having a source fromPublisher() conform to the 
SupervisionStrategy defined in the ActorMaterializer ?


I have that publisher  :
MongoClients.create(mongoSettings).listDatabaseNames()
That throws an exception on the onError callback, but the errorDecider 
never gets called. The stream colapses on a failed Future :


    implicit val system2 = ActorSystem("Sys2")
    import system2.dispatcher

    val errorDecider : Supervision.Decider = {
      case _ => {
        println("errorDecider does something, yeiii !")
        Supervision.stop}
    }

    implicit val materializer = ActorMaterializer(ActorMaterializerSettings(
system2)
      .withSupervisionStrategy(errorDecider))

    val publiString : Publisher[String] = MongoClients.create(mongoSettings
).listDatabaseNames()
    val stream: Source[String, NotUsed] = Source.fromPublisher(publiString)

    stream.map( {s => println(s);s}).runWith(Sink.ignore).onComplete(_ => 
system2.terminate())



thanks in advace for your responses.

Best,

Antonin PA

-- 
>>>>>>>>>>      Read the docs: http://akka.io/docs/
>>>>>>>>>>      Check the FAQ: 
>>>>>>>>>> http://doc.akka.io/docs/akka/current/additional/faq.html
>>>>>>>>>>      Search the archives: https://groups.google.com/group/akka-user
--- 
You received this message because you are subscribed to the Google Groups "Akka 
User List" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/akka-user.
For more options, visit https://groups.google.com/d/optout.

Reply via email to