Finatra is a sinatra-inspired web framework for scala, running on top of Finagle
See the Getting Started guide or the Documentation for more information.
Get help on the finatra-users mailing list.
class HelloWorld extends Controller {
get("/hello/:name") { request =>
val name = request.routeParams("name").getOrElse("default user")
render.plain("hello " + name).toFuture
}
}
object App extends FinatraServer {
register(new HelloWorld())
}
"com.twitter" %% "finatra" % "1.5.3"
<dependency>
<groupId>com.twitter</groupId>
<artifactId>finatra_2.10</artifactId>
<!-- for 2.9 <artifactId>finatra_2.9.2</artifactId> -->
<version>1.5.3</version>
</dependency>
Copyright 2014 Twitter, Inc and other contributors
Licensed under the Apache License, Version 2.0: http://www.apache.org/licenses/LICENSE-2.0