I am integrating Togglz library into a Clojure Ring project to support feature toggles and would like to activate the Togglz admin console. According to the Togglz documentation it is necessary to add a servlet in the /WEB-INF/web.xml file for projects that don't support Servlet 3.0. I used the :uberjar-merge-with leiningen plugin to merge the file with the Togglz servlet configuration with the web.xml file autogenerated by leiningen. However, this was not sufficient to activate the admin console. I could not find much information on how to integrate a servlet from an external library into a Ring application. What would be the best way to do it?
Asked
Active
Viewed 209 times
2
-
How are you running your application? Are you creating a war and deploying it or something like embedded Jetty? – BillRobertson42 Sep 23 '17 at 01:53
-
Hi Bill, I am using an embedded Jetty. – alexandra.s Sep 26 '17 at 06:52
-
If you're using embedded Jetty, (e.g. `lein ring server`, or `lein ring uberjar` to run/build), then AFAIK, you don't get servlet support by default. I'm not sure how to do it, but I'm sure it's possible to enable a 3d party servlet. – BillRobertson42 Sep 26 '17 at 18:54
1 Answers
0
I have not tried it myself, but the lein-servlet library seems to promise to do exactly that

Ward
- 2,802
- 1
- 23
- 38