Hi,

I cannot figure out, how would I do something like : 

bucketOpt match {
  case None =>
    *// ??? How to return just a dummy partial graph ???*
  case Some(bucket) =>
    Flow() { implicit b =>
      import FlowGraph.Implicits._

      val broadcast = b.add(Broadcast[Array[ResCtx]](2))

      val uniqueResourceFilter = Flow[Array[ResCtx]].transform(() => new 
UniqueResourceFilter)
      val backup = Flow[Iterable[Resource]].mapAsyncUnordered(4) { resources =>
        Future.sequence(
          resources.map( res => S3BackupFlow.backup(bucket, res, res.name, 
deleteLocal))
        )
      }
      broadcast.out(0) ~> uniqueResourceFilter ~> backup ~> Sink.ignore

      (broadcast.in, broadcast.out(1))
    }
}


Also it is a mystery to me how to grab just an inlet stream, for doing 
something like : 

Flow() { implicit b =>
  import FlowGraph.Implicits._

  

  val uniqueResourceFilter = Flow[Array[ResCtx]].transform(() => new 
UniqueResourceFilter)

  val merge = b.add(Merge[Array[ResCtx]](2))

 

  ???in??? ~> filter ~> broadcast.out(0) ~> uniqueResourceFilter ~> backup ~> 
merge.in(0)

                     ~> broadcast.out(1) ~> uniqueResourceFilter ~> backup ~> 
merge.in(1)


(???in???, merge.out)
}



Thanks, Jakub

-- 
>>>>>>>>>>      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 http://groups.google.com/group/akka-user.
For more options, visit https://groups.google.com/d/optout.

Reply via email to