Here at Tasktop we really like industry standards. It’s important for us to use well known tools and frameworks to make transitions between teams easier. When it comes to creating a REST API there is no way around JAX-RS in the Java world. But JAX-RS (or one of it’s implementations) is not a full server stack. You always need to use some other technologies e.g. to access a database, do logging and much more.
Several projects exists providing such a stack. And one of the coolest projects in the last years is Dropwizard. Dropwizard combines some industry standard technologies like JAX-RS (Jersey), Hibernate, log4j, guava, Jetty (and some more) and glues them together. We use Dropwizard here at Tasktop for several products because it just works and make things easy.
As you might know, we have a heavy Eclipse background and are using Eclipse as an IDE for all our projects. For this reason we also use Eclipse for our Dropwizard applications. While you can launch Dropwizard applications without special tooling in Eclipse, it has some drawbacks. These are:
- You need to use system properties to point to your Dropwizard configuration.
- You always need to terminate a previously launched instance of your application because the port used by the running instance will be occupied when launching the new instance.
Introducing the Eclipse Dropwizard Tools
To make our life easier we have created the Eclipse Dropwizard Tools. The tools contain a launcher to launch Dropwizard applications. You can select the Dropwizard configuration in the UI and it eliminates all previously launch instances before it launches a new one. So no more “address is already in use” error messages.
Besides of this the tools contain a launch shortcut. This means you can just launch your main class as a Dropwizard Application and it will also pick the first .yml file in your project as the configuration to use.
One other goodie we added, is a YAML editor. YAML is an essential part of Dropwizard (e.g. for the configuration). We did not develop this by ourself, instead we use the Eclipse YEdit plugin. It’s a very mature YAML editor for Eclipse and makes the editing much easier.
The Dropwizard Tools are available in the Eclipse Marketplace. You can simply drag and drop the “install” badge below into your IDE to install it.
Alternatively you can also use the p2 repository url which is: http://tasktop.github.io/dropwizard-tools/
License and Contribution
The Eclipse Dropwizard Tools are licensed using the Apache 2.0 Software License and hosted as a github project. Feel free to open issues and create some pull requests. We would love to see your contribution and every feedback is welcome!