Reputation: 1543
I am working on integrating the swagger UI with a spring boot MVC app and I am curious as to the differences between these libraries.
I looked at each on mvnrepository.com and they are all done by different groups but seem to do the same thing. I am hoping to get a clear idea of the differences between these and if one is recommended over the others. I notice the swagger-core module by io.swagger has the most usages.
Thanks!
Upvotes: 16
Views: 16054
Reputation: 2991
io.swagger
is the package for swagger libraries and you need separate spring jars to couple it with Spring. This is version 2 of swagger.
io.springfox
is Springfox
Swagger2, wherein swagger comes integrated with Spring.
com.mangofactory
is swagger integrated with Spring Web MVC framework.
To understand differences between Spring Web MVC framework and spring, you can read this: what is the difference between Spring and Spring MVC framework
Upvotes: 8
Reputation: 5487
Here is an explanation of the different libraries.
Springfox is in a sense v2 of the swagger library that used to be packaged as mangofactory
. What happened was we transitioned from using a private repo to creating a github organization so support development as a team.
In short mangofactory
evolved into springfox
which supports 2.0 version of swagger spec (in addition to 1.2). To be clear springfox and its predecessor supports spring mvc.
io.swagger
is the mother ship if you will. It has great support for spring and jax-rs. So if you're looking for support for Jax-rs based services using spring or otherwise that's a great option.
Upvotes: 7