删除 SpringFox SwaggerUI 中的基本错误控制器 [英] Remove Basic Error Controller In SpringFox SwaggerUI

查看:53
本文介绍了删除 SpringFox SwaggerUI 中的基本错误控制器的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

有没有办法从 springfox swagger-ui 中删除基本错误控制器"?

Is there a way i can remove the "basic-error-controller" from springfox swagger-ui?

图片:

推荐答案

您可以限制请求处理程序选择器仅扫描您项目的包:

You can restrict the request handler selector to scan only the package of your project:

    return new Docket( DocumentationType.SWAGGER_2)
        .select()
        .apis( RequestHandlerSelectors.basePackage( "your package" ) )
        ...

这篇关于删除 SpringFox SwaggerUI 中的基本错误控制器的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆