REST/HTTP 工具包 Spray
- 授权协议: Apache
- 开发语言: Scala
- 操作系统: 跨平台
- 软件首页: http://spray.io/
- 软件文档: http://spray.io/documentation/
软件介绍
Spray 是一个开源的 REST/HTTP 工具包和底层网络 IO 包,基于 Scala 和 Akka 构建。轻量级、异步、非堵塞、基于 actor 模式、模块化和可测试是 spray 的特点。
示例代码:
val responses: Future[Seq[HttpResponse]] = HttpDialog(host = "img.example.com", port = 8888) .send(HttpRequest(GET, "a.gif")) .send(HttpRequest(GET, "b.gif")) .send(HttpRequest(GET, "c.gif")) .end
