add Application.java and refactor resource class.
edit gradle task to run jetty9.