我是采用代理模式的aspectj

<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<version>2.10</version>
<configuration>
<argLine>
-javaagent:/Users/hongjie/.m2/repository/org/aspectj/aspectjweaver/1.8.13/aspectjweaver-1.8.13.jar
</argLine>
<useSystemClassLoader>true</useSystemClassLoader>
<forkMode>always</forkMode>
</configuration>
</plugin>

代码运行报错如下:

解决方案:

1、需要在 resources 中配置 aop.xml 文件,放置在 META-INF 目录中( resource/META-INF/aop.xml),如没有自行创建

2、aop.xml 文件中的配置非常容易理解,只需要配置 Aspects 和需要被织入的类即可。

aop.xml

<?xml version="1.0" encoding="UTF-8" ?>
<aspectj>
<weaver options="-Xset:weaveJavaxPackages=true -Xlint:ignore -verbose">
</weaver>
</aspectj>

再次运行解决问题,不会在报错了

关于because the weaver option '-Xset:weaveJavaxPackages=true' has not been specified报错的解决方案的更多相关文章

  1. 关于Oxygen版 Eclipse JSP或html 中<option>标签嵌入jstl 如<c:if>出现报错

    Oxygen版 Eclipse JSP或html 中<option>标签嵌入jstl 如<c:if>出现报错 好好的学框架的整合,结果在<option>中加入< ...

  2. web.xml配置文件中<async-supported>true</async-supported>报错的解决方案

    为什么用到这个: ssh集成了cxf,当登录系统后,发现系统报错,控制台不断输出下面信息: 2016-05-05 11:05:06 - [http-bio-8080-exec-4] - WARN - ...

  3. <compilation debug="true" targetFramework="4.5.2"> 报错解决方案

    有的时候新建项目,默认会选择比较高的 .net framework 版本如 4.5.2 有的时候发布项目就会遇到这个问题 解决的话 改成4.0就行了! 看你发布在哪里,如果在本地或者服务器,只要去下载 ...

  4. Spring.之.报错:Caused by: java.lang.ClassNotFoundException: org.aspectj.weaver.reflect.ReflectionWorld$ReflectionWorldException

    Caused by: java.lang.ClassNotFoundException: org.aspectj.weaver.reflect.ReflectionWorld$ReflectionWo ...

  5. ThinkPHP 中入口文件中的APP_DEBUG为TRUE时不报错,改为FALSE时报错

    今天好不容易将一个新闻网做好了(ThinkPHP框架做的),但是,当我将入口文件中定义调试模式设为FALSE,即define('APP_DEBUG',False),然后再刷新网站的时候,就提示报错,报 ...

  6. weblogic启动报错之Unrecognized option: -jrockit

    报错如下: $ ./startWebLogic.sh . . JAVA Memory arguments: -Xms512m -Xmx512m . WLS Start Mode=Production ...

  7. pandas 报错:【sys:1: DtypeWarning: Columns (15) have mixed types. Specify dtype option on import or set low_memory=False.】

    错误原因 报错提示:“sys:1: DtypeWarning: Columns (15) have mixed types. Specify dtype option on import or set ...

  8. Python模块学习之xlrd 读取Excel时传入formatting_info=True报错:NotImplementedError: formatting_info=True not yet implemented

    问题:xlrd读取Excel时传入 formatting_info=True 报错 之前我们使用读取xls文件的时候都是使用的xlrd库,但是这个库只能操作 .xls格式,对于后来的 .xlsx的版本 ...

  9. mysql 报错:Error Code: 1175. You are using safe update mode and you tried to update a table without a WHERE that uses a KEY column. To disable safe mode, toggle the option in Preferences

    目录 #事故现场 #解决方法 #事故现场 mysql执行update操作报错: sql如下: update psmp.Users set name='Jack' where name='Lily'; ...

随机推荐

  1. pytorch错误:RuntimeError: received 0 items of ancdata解决

    版权声明:本文为博主原创文章,欢迎转载,并请注明出处.联系方式:460356155@qq.com RuntimeError: received 0 items of ancdata错误是在datalo ...

  2. 佳文赏析:How to uninstall Linux

    来源:https://www.dedoimedo.com/computers/linux-uninstall.html This article was suggested to me by a re ...

  3. Struts2+Spring+Hibernate3整合

    这几天正在复习三大框架的知识,特意把写出来,如有错误,希望大家多指教! 代码地址:https://git.coding.net/puchenglin/SSHDemo.git 1. 引入jar包 Str ...

  4. [Java]list集合为空或为null的区别

    判断的是list这个集合的问题,当前需要判断list内值的问题. 简述判断一个list集合是否为空,我们的惯性思维是判断list是否等于null即可,但是在Java中,list集合为空还是为null, ...

  5. AWS Step Function Serverless Applications

    Installing VS Components To follow along with this article, you must have an AWS account and install ...

  6. VMware虚拟机里Centos7的IP地址查看方法

    电脑的虚拟机里面安装了一个Cetos 7 ,想用Xshell链接进行操作,发现没有IP显示,需要IP地址,我才能进行连接,用命令ip addr查看下: 发现ens33 没有inet 这个属性,那么就没 ...

  7. thinkphp 迁移数据库 -Phinx 简单说明文档

    php think migrate migrate:create Create a new migration ///创建 migrate:rollback Rollback the last or ...

  8. [NOI2017]游戏

    题目描述 http://www.lydsy.com/JudgeOnline/upload/Noi2017D2.pdf 题解 如果说没有x的话,那么每一局只能有两种选择,可以描述为是/非,每条限制也可以 ...

  9. Ticwatch2_3G版省电优化

    设置 --> 网络与连接 --> 云消息同步(禁用) 设置 --> 声音与震动 --> 铃声与音量(静音) 设置 --> 声音与震动 --> 闹钟音量(静音) 设置 ...

  10. visp库中解决lapack库的问题

    解决的办法是——绕过去,不要用这个库: 使用中发现如下代码抛出异常: //vpTemplateTracker.cpp try { initHessienDesired(I); ptTemplateSu ...