Skip to content


Switch branches/tags

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?

Latest commit


Git stats


Failed to load latest commit information.
Latest commit message
Commit time

Guice intergration for Dropwizard

Build Status Maven Version License Maintenance

A minimalistic integration between the dependency injection framework Guice and the microservice framework Dropwizard.

How to use?

This integration aims to introduce minimal effort to get started

Configure the Maven Dependencies

    <version>{{ current-version }}</version>

The current version can be found here.

Create your Application

To get started with Dropwizard and Guice you only need a single class which invokes the bootstrapping.

public class MyApplication implements GuiceApplication {
	public static void main(String[] args) throws Exception {
		new GuiceBootstrap<MyConfiguration>(MyConfiguration.class,
                                            new ExampleGuiceModule()) {

	private final Environment environment;
	private final MyResource myResource;

	public MyApplication(Environment environment, MyResource myResource) {
		this.environment = environment;
		this.myResource = myResource;

	public void run() throws Exception {

It is important, that the main method does invoke the GuiceBootstrap with an anonymous implementation like in the example. This is required due to the generic type paremeter resolution for Dropwizard.

More features can be found in the example.