Dropwizard vs Spring Boot comparison

Source: Internet
Author: User
Tags log4j

In this article we will discuss the similarities and differences between Java Lightweight framework Dropwizard and spring boot.

First of all, this is a choice of freedom and speed needs, no matter what you choose in Dropwizard and spring boot, the two frameworks themselves are a bit opinionated, they all believe that the agreement is better than the configuration, then how stubborn? You will find that, after we compare, each of them is mixed with a third-party library package, most of which is not a core function need but a need for integration. The benefit of this sacrifice is to get good performance. The following illustration uses white to display a dependent package.

Spring's dependence

Spring boot focuses on the spring app, and if you want to get into the spring ecosystem, or you're already familiar with it, and want a quick start, it's a good choice, and Dropwizard is the combination of rest and jersey, It helps you to leave the dependency on spring.

HTTP Server

Here we see spring boot more flexible, dropwizard with a convention over configuration, more extreme than spring boot, completely based on jetty, and spring boot uses embedded tomcat by default, and others can choose.

Log

Dropwizard switch from log4j to Logback, and spring boot provides logback, log4j and log4j2 selection, Logback is a better log4j, performance is higher than log4j, but note that different methods use different performance.

Dependency Injection

The main difference between the two frameworks is the dependency injection, the spring core has dependency injection, and Dropwizard needs your choice, which also brings flexibility, with Google Guice or newer better dependency injection frameworks to choose from.

Test

The two frameworks are supported by Dropwizard-testing and Spring-boot-starter-test.

Dropwizard metrics allows you to add it to any project, even with spring boot metrics, to ensure your code is productive.

Finally, both have strong community support. If you prefer light weight, no doubt Dropwizard wins, if you already have spring experience, no doubt use spring Boot.

Dropwizard vs Spring Boot comparison

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.