java - 使用 maven 插件的离线 swagger 文档

标签 java maven swagger swagger-maven-plugin

我正在尝试生成 swagger 文档,为此我需要启动服务器。我想离线生成 swagger 文档(不启动服务器),我刚得到这个链接 swagger-codegen-maven-plugin

但是当我将上面的插件添加到 POM.xml 时(我觉得应该在 maven 构建期间生成 HTML 文档),它根本没有做任何事情。请帮忙。

最佳答案

看看这个插件: https://github.com/teamcarma/swagger-jaxrs-doclet

As the JSON resource listing is generated offline from source code it means that you do not need to add any runtime dependencies to your project and avoid potential headaches with different jar versions and jaxrs implementations. This also avoids increasing the size of your artifacts

关于java - 使用 maven 插件的离线 swagger 文档,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/30640015/

相关文章:

java - 在 Eclipse 中我使用 JFrame 但没有出现窗口

java - Maven Tomcat 部署返回 HTTP 403 拒绝访问,停止生产

spring-boot - 使用 Open API 进行测试时,带有 HttpEntity 的 Spring Rest Controller API 获取空主体

kotlin - 如何在 micronaut 上启用 swagger UI?

java - 在推断模型上使用 Jena 规则文件为本体创建 validator

java - AES - 在 Java 中用密文存储 IV

scala - SBT 取决于特定的快照版本

java - 无法弄清楚如何访问由 swagger 自动生成的 jaxrs 服务器中的请求 header

java - 将不可序列化的数据发送到新的 Activity

maven - 基于更新路径的条件作业和步骤