Currently with a handled round trip in lift 3.0.0(and in the latest master) there isn't any reasonable way to tell when a client has disconnected. Is there any chance of getting the current actor state passed through? That would be nice for cases where data needs to be streamed until the client disconnects.
--
--
Lift, the simply functional web framework: http://liftweb.net
Code: http://github.com/lift
Discussion: http://groups.google.com/group/liftweb
Stuck? Help us help you: https://www.assembla.com/wiki/show/liftweb/Posting_example_code
---
You received this message because you are subscribed to the Google Groups "Lift" group.
To unsubscribe from this group and stop receiving emails from it, send an email to liftweb+u...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
def fetchData(t: JValue, func: RoundTripHandlerFunc): Unit = { def stream: scala.collection.immutable.Stream[Call] = Call("console.log", 1) #:: stream
val iter = stream.iterator
def send(): Unit = { func.send(iter.next()) send() }
send()}
def getFunctions(in: NodeSeq): NodeSeq = { for (session <- S.session) { val script = JsCrVar( "customLiftFunctions", session.buildRoundtrip( List( HandledRoundTrip("fetchData", fetchData) ) ) ) S.appendGlobalJs(script) } in}
<div data-lift="MySnippet.getFunctions"></div>
val session: LiftSession = ???
val stop: scalaz.concurrent.Task[Unit] = ???session.addSessionCleanup { _ => stop.unsafePerformAsync(_.leftMap(t => logger.error(s"Failed to stop $name on $sessionId.", t)))}
To unsubscribe from this group and stop receiving emails from it, send an email to liftweb+unsubscribe@googlegroups.com.
You received this message because you are subscribed to a topic in the Google Groups "Lift" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/liftweb/X4YFBW9NGD8/unsubscribe.
To unsubscribe from this group and all its topics, send an email to liftweb+unsubscribe@googlegroups.com.
You received this message because you are subscribed to a topic in the Google Groups "Lift" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/liftweb/X4YFBW9NGD8/unsubscribe.
To unsubscribe from this group and all its topics, send an email to liftweb+u...@googlegroups.com.