Minimal example of multiple context paths with jetty/dropwizard
There a few approaches implemented.
- contextPath
- servletMapping
- contextHandler
- handlerWrapper
- redirect
Each modes can be enabled in the config.yml
or supplied via a command line arg -Ddw.redirect=true
- Run
mvn clean package
to build your application - Start application with
java -jar target/jetty-context-path-1.0-SNAPSHOT.jar server config.yml
- Check that
http://localhost:8080/alias/link
return the same URL - Check that
http://localhost:8080/link
return the same URL