Question

Actually I have a Java application running on a Linux server as daemon. Now I'll provide a simple web-based configuration page. I have no clue how to solve this without using big frameworks.

What I fell that I don't want is to use Java EE or sth like this. A "small" free (for commercial use) library is ok.

Any ideas?

Was it helpful?

Solution

I would recommend you to use Jetty(it is probably most Java lightweight server) with pure Servlets and JSP. If you need only one or two pages with few configuration options then any framework seem to me like unnessecary overkill.

OTHER TIPS

I can recommend play framework if you want to stay in the java space or if you are adventurous you might consider any number of microframeworks/environments in other languages.

  • flask(python)
  • scalatra(scala)
  • meteor.js(javascript)
  • node.js(javascript)
  • twisted(python)
  • sinatra(ruby)

All of these offer very lightweight web servers(Often allowing you to create dynamic web content in just a few lines) in conjunction with languages that have os integration that will allow you to manage the configuration and status of your application.

You can use Apache Tomcat or Jetty.

Look into com.sun.net.httpserver if you are using the jre. It's already there any very easy the embed.

For configurations you can also use JMX. The jconsole can easily access your application and there is also a JMX HTTP adapter. This adapter allows you to monitor the setting and also change them. This gives you a web page for free but of course its not a "pretty" page.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top