2013-12-17 | spray (vienna scala user group)
DESCRIPTION
Introduction to spray, a suite of Scala libraries providing client- and server-side REST/HTTP support on top of Akka. Talk given at Vienna Scala User Group on Dec. 17, 2013TRANSCRIPT
Dominik Gruber, @the_dom Vienna Scala User Group – Dec. 17, 2013
Dominik Gruber • @the_dom
Dominik Gruber
• Developing software for iOS and the web
• Work at KURIER.at online network
• Studied “Software Engineering & Internet Computing” at Vienna University of Technology
Dominik Gruber • @the_dom
“spray is a suite of lightweight Scala libraries providing client- and server-side
REST/HTTP support on top of Akka.”
Dominik Gruber • @the_dom
spray• Started in April 2011 by Mathias Doenitz
• Version 1.0/1.1/1.2 released in Nov 2013
• Acquired by Typesafe: spray will become akka-http
• Play will gradually move onto akka-http
• Future: WebSockets, SPDY
Dominik Gruber • @the_dom
Components
© Mathias Doenitz
Dominik Gruber • @the_dom
IO Stack
© Mathias Doenitz
Dominik Gruber • @the_dom
API Layer
© Mathias Doenitz
Dominik Gruber • @the_dom
API Layer
© Mathias Doenitz
Dominik Gruber • @the_dom
spray-httpcase class HttpRequest(
method: HttpMethod = HttpMethods.GET,
uri: Uri = Uri./,
headers: List[HttpHeader] = Nil,
entity: HttpEntity = HttpEntity.Empty,
protocol: HttpProtocol = HttpProtocols.`HTTP/1.1`)
Dominik Gruber • @the_dom
spray-http
case class HttpResponse(
status: StatusCode = StatusCodes.OK,
entity: HttpEntity = HttpEntity.Empty,
headers: List[HttpHeader] = Nil,
protocol: HttpProtocol = HttpProtocols.`HTTP/1.1`)
Dominik Gruber • @the_dom
Code
Dominik Gruber • @the_dom
ResourcesSpray Websitehttp://spray.io
Template Projecthttps://github.com/spray/spray-template Talks http://spray.io/webinar/ http://skillsmatter.com/podcast/scala/mathias-doenitz
Dominik Gruber • @the_dom
Q & A