=doc a first set of new and imported documentation for akka-http

This commit is contained in:
Johannes Rudolph 2014-12-18 09:25:33 +01:00
parent 6f11735765
commit af14fd8243
81 changed files with 3674 additions and 54 deletions

View file

@ -22,9 +22,8 @@ class HttpServerExampleSpec
implicit val materializer = FlowMaterializer()
val serverBinding = Http(system).bind(interface = "localhost", port = 8080)
for (connection <- serverBinding.connections) {
serverBinding.connections.foreach { connection // foreach materializes the source
println("Accepted new connection from " + connection.remoteAddress)
// handle connection here
}
//#bind-example
}
@ -56,7 +55,9 @@ class HttpServerExampleSpec
serverBinding.connections foreach { connection =>
println("Accepted new connection from " + connection.remoteAddress)
connection handleWith { Flow[HttpRequest] map requestHandler }
connection handleWithSyncHandler requestHandler
// this is equivalent to
// connection handleWith { Flow[HttpRequest] map requestHandler }
}
//#full-server-example
}