最新消息: USBMI致力于为网友们分享Windows、安卓、IOS等主流手机系统相关的资讯以及评测、同时提供相关教程、应用、软件下载等服务。

Action:Consider defining a bean named ‘authenticator‘ in your configuration.

业界 admin 3浏览 0评论

错误描述

  • 今天Springboot 整合 Shiro 抛出如下错误:
***************************
APPLICATION FAILED TO START
***************************

Description:

Parameter 0 of method shirFilter in com.bbzd.mes.shiro.config.ShiroConfig required a bean named 'authenticator' that could not be found.


Action:

Consider defining a bean named 'authenticator' in your configuration.

原因

  • 我认为是依赖不兼容

解决办法

  • 报错依赖
<dependency>
	<groupId>org.apache.shiro</groupId>
    <artifactId>shiro-spring-boot-starter</artifactId>
    <version>1.4.0</version>
</dependency>
  • 将报错依赖改为:
<dependency>
	<groupId>org.apache.shiro</groupId>
	<artifactId>shiro-spring</artifactId>
	<version>1.4.0</version>
</dependency>

错误描述

  • 今天Springboot 整合 Shiro 抛出如下错误:
***************************
APPLICATION FAILED TO START
***************************

Description:

Parameter 0 of method shirFilter in com.bbzd.mes.shiro.config.ShiroConfig required a bean named 'authenticator' that could not be found.


Action:

Consider defining a bean named 'authenticator' in your configuration.

原因

  • 我认为是依赖不兼容

解决办法

  • 报错依赖
<dependency>
	<groupId>org.apache.shiro</groupId>
    <artifactId>shiro-spring-boot-starter</artifactId>
    <version>1.4.0</version>
</dependency>
  • 将报错依赖改为:
<dependency>
	<groupId>org.apache.shiro</groupId>
	<artifactId>shiro-spring</artifactId>
	<version>1.4.0</version>
</dependency>

与本文相关的文章

发布评论

评论列表 (0)

  1. 暂无评论