Skip to content

Instantly share code, notes, and snippets.

@markehammons
Created January 22, 2013 14:31
Show Gist options
  • Save markehammons/4595051 to your computer and use it in GitHub Desktop.
Save markehammons/4595051 to your computer and use it in GitHub Desktop.
package com.example.myapp
import org.scalatra._
import javax.servlet.ServletContext
/**
* This is the Scalatra bootstrap file. You can use it to mount servlets or
* filters. It's also a good place to put initialization code which needs to
* run at application start (e.g. database configurations), and init params.
*/
class Scalatra extends LifeCycle {
override def init(context: ServletContext) {
// Mount one or more servlets
context.mount(new MyServlet, "/*")
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment