Skip to content


Subversion checkout URL

You can clone with
Download ZIP
An easy pluggable Java monitor/healthcheck for your webapp.
Java Groovy Shell
branch: master

Fetching latest commit…

Cannot retrieve the latest commit at this time

Failed to load latest commit information.

Build Status

Webapp Monitorino

An easy pluggable Java monitor/healthcheck for your webapp.

Ever been in the situation where you would like to run diagnostics on your webapp? Or see some of the properties the application uses? Maybe even run the diagnostics scheduled and receive alerts when something is not how it is supposed to be?

Inspired by Knut Haugens presentation at Roots 2011 and corresponding Ruby Smoketest blogpost I decided to try to implement it in Java. Never wanting to do the same work all over again at another project I decided to polish it share it on github. Later I see Knut Haugen also has made a Java example, go check it out!

Anyways, this is a light jar-file which you can plug into any webapp project you would like.


If you like reading code check out the example project. Simplest way to get the example started is running and checking the result at http://localhost:8090/spring/monitor/ or http://localhost:8090/spring/monitor/junit


For Spring it's as easy as to include a bean of class MonitorinoController. The junit report will now be accessible from .../your-spring-dispatcher-mapping/healtcheck/xml and as html on .../your-spring-dispatcher-mapping/healtcheck/html

But to make it show something you need to add some healthchecks. Create beans that extends MonitorinoRunner like EverythingIsOk and be sure to return null if success. These will be autowired into your MonitorinoController.

If you'd like to see some properties add them to your Controller, perhaps like this from the example apps SpringApplicationContext

public MonitorinoController monitorinoController() throws IOException {
    MonitorinoController controller = new MonitorinoController();
    return controller;

public Properties mavenBuildProperties() throws IOException {
    PropertiesFactoryBean factory = new PropertiesFactoryBean();
    factory.setLocation(new ClassPathResource(""));
    return factory.getObject();

That's it. You're good to go.

Test example by git cloning/forking and run mvn install and Results for html and junit should be accessable from http://localhost:8090/spring/monitor


The real power lies in getting Jenkins to give you quick feedback. For setup look at Knut Haugens Ruby Smoketest blogpost






You could do it like WebappMonitorinoHttpServletExample

public class WebappMonitorinoHttpServletExample extends HttpServlet {
    protected void doGet(HttpServletRequest req, HttpServletResponse resp) throws ServletException, IOException {
        PrintWriter out = resp.getWriter();
        Collection<MonitorinoRunner> list = new ArrayList<MonitorinoRunner>();
        list.add(new AssertTwoPlusTwoIsFour());
        list.add(new EverythingIsOk());
        MonitorinoSuite suite = new SuiteAssembler("Monitor from HttpServlet", list, null).run();
        out.println(new HtmlView().process(suite));

What else?

Project Documentation

Use it Jenkins and Monitorino for scheduling? You could make scheduling jobs extend MonitorinoRunner and make Jenkins reguarly visit your Servlet.

The project has a Procfile and the example is reguarly deployed to Heroku on

Something went wrong with that request. Please try again.