写项目时应用了SpringSecurity框架来进行登陆验证,之前单独的写简单的SpringSecrity的Demo时并没有报错,但是当和SpringMVC一起整合时却发生了报错

报错如下:

Caused by: java.lang.IllegalArgumentException: A universal match pattern ('/**') is defined  before other patterns in the filter chain, 
causing them to be ignored.
Please check the ordering in your <security:http> namespace or FilterChainProxy bean configuration

出错原因:

初始化配置文件发生出错

原先初始化顺序:

  <context-param>
<param-name>contextConfigLocation</param-name>
<param-value>
classpath:spring-security.xml
classpath:applicationContext.xml
</param-value>
</context-param>

报错

解决方法:

将applicationContext.xml在spring-security.xml之前先初始化

解决Caused by: java.lang.IllegalArgumentException: A universal match pattern ('/**') is defined before other patterns in the filter chain, causing them to be ignored. Please check the ordering in your的更多相关文章

  1. 解决Caused by: java.lang.IllegalArgumentException: Result Maps collection does not contain value for com.geek.dao.ContentDao.Integer

    mybatis报错:Caused by: java.lang.IllegalArgumentException: Result Maps collection does not contain val ...

  2. Spring AOP 开发中遇到问题:Caused by: java.lang.IllegalArgumentException: warning no match for this type name: com.xxx.collector.service.impl.XxxServiceImpl [Xlint:invalidAbsoluteTypeName]

    在网上找了很多,都不是我想要的,后来发现是我在springaop注解的时候 写错了类名导致的这个问题 @Pointcut("execution(* com.xxx.collector.ser ...

  3. 解决kylin报错:Failed to create dictionary on <db>.<table>, Caused by: java.lang.IllegalArgumentException: Too high cardinality is not suitable for dictionary

    报错信息: 2017-05-13 15:14:30,035 DEBUG [pool-9-thread-10] dict.DictionaryGenerator:94 : Dictionary clas ...

  4. mybatis报错:Caused by: java.lang.IllegalArgumentException: Caches collection already contains value for com.crm.dao.PaperUserMapper

    一.问题 eclipse启动时报下面的错误: Caused by: java.lang.IllegalArgumentException: Caches collection already cont ...

  5. spring .cloud ------------java.lang.RuntimeException: com.netflix.client.ClientException,Caused by: java.lang.IllegalArgumentException: MIME type may not contain reserved characters

    1.问题的发生 Feign在默认情况下使用的是JDK原生的URLConnection发送HTTP请求,没有连接池,但是对每个地址会保持一个长连接,即利用HTTP的persistence connect ...

  6. Caused by: java.lang.IllegalArgumentException: Parameter Maps collection does not contain value for com.bj186.crm.mapper.UserMapper.Integer

    在使用SSM整合myBatis的过程中遇到了这个问题. 问题的原因: 把parameterType错误的写成了parameterMap 解决办法: 将parameterMap修改为parameterT ...

  7. Caused by: java.lang.IllegalArgumentException: Property 'sqlSessionFactory' or 'sqlSessionTemplate' are required [ IDEA mybatis项目报错 ]

    今天笔者用Springboot框架整合Mybatis做一个小小的项目: 代码写完,在运行项目时,IDEA给我报了3处错误: org.springframework.beans.factory.Unsa ...

  8. springboot整合mybatis的时候报错Caused by: java.lang.IllegalArgumentException: Property 'sqlSessionFactory' or 'sqlSessionTemplate' are required

    今天闲来无事,学习springboot整合mybatis,在bilibili看视频学的,视频中在dao层的interface上面加上org.apache.ibatis.annotations.Mapp ...

  9. 使用 Jenkins 打包成功后 运行 出现 Caused by: java.lang.IllegalArgumentException: Property 'sqlSessionFactory' or 'sqlSessionTemplate' are required

    linux 运行时 错误日志 Error starting ApplicationContext. To display the conditions report re-run your appli ...

随机推荐

  1. git pull和本地文件冲突

    在使用git pull代码时,经常会碰到有冲突的情况,提示如下信息: error: Your local changes to 'c/environ.c' would be overwritten b ...

  2. Android屏幕适配框架-(今日头条终极适配方案)

    在Android开发中,屏幕适配是一个非常头痛的问题,因而为了去进行屏幕适配,作为程序员,是呕心沥血,历经磨难,哈哈 我们之前做屏幕适配一般都会用到一下两种方式: 第一种就是宽高限定符适配,什么是宽高 ...

  3. ES9新内容概括

    本文主要介绍ES2018 新出的一些特性 1.异步迭代 允许 async/await 与 for-of 一起使用,以串行的方式运行异步操作,达到异步函数的迭代效果. async function pr ...

  4. POST调用WCF方法-项目实践

    做即时通信项目时,需要与OA系统对接接口,主要目标是实现在OA里进行一项事项,通过调用我们的接口,即时通知过来,并弹出消息框提示一下.我们的即时通信使用的WCF服务进行通信,在客户端调用通信时,用的就 ...

  5. linux 7 关闭防火墙 开启sshd服务

    启动一个服务:systemctl start firewalld.service关闭一个服务:systemctl stop firewalld.service重启一个服务:systemctl rest ...

  6. 从零开始学Python 三(网络爬虫)

    本章由网络爬虫的编写来学习python.首先写几行代码抓取百度首页,提提精神,代码如下: import urllib.request file=urllib.request.urlopen(" ...

  7. Robot Framework自动化使用

    自动化测试框架---Robot Framework Robot Framework是用Python语言写的,所以在安装Robot Framework以前必须安装Python环境.Robot Frame ...

  8. Win10系列:C#应用控件进阶7

    PathGeometry 前面介绍了Path的使用方法,接下来介绍PathGeometry类.PathGeometry提供了描绘由弧线.曲线和直线组成的多个复杂图形的方法.PathGeometry的核 ...

  9. LVS初始使用步骤

    LVS是Linux Virtual Server的简称,也就是Linux虚拟服务器, 是一个由章文嵩博士发起的自由软件项目,它的官方站点是www.linuxvirtualserver.org. 现在L ...

  10. elment重置表格行高,hover效果

    来源网络,做个笔记.表头行高.el-table__header tr, .el-table__header th { padding: 0; height: 50px; }表体行高 .el-table ...