This is probably so basic that I can't even find an example. I've recently been learning Scala and want to explore using Unfiltered for a new set of services.
I've got a simple EchoService defined as such:
object EchoService {
val echo = Planify {
case Path(Seg(p :: Nil)) => ResponseString(p)
}
val niceError = Planify {
case _ => ResponseString("no can do")
}
}
I've got a manual test working like this:
object Unfiltered_MT {
def main(args: Array[String]) {
Http.anylocal.filter(EchoService.echo).filter(EchoService.niceError).run()
}
}
Works great! Now this thing (with the two chained filters) needs to be deployed as a war in WebLogic. What I can't figure out is what the web.xml should look like to accomplish that declaratively.