Caused by: java.lang.IllegalArgumentException 是因为jdk较高而项目需要的是低版本的问题

1.将idea或idea里的语言级别调到适合自己项目的版本比如安装的是1.8 项目需要1.6的环境 这样之后本地运行应该就没问题了(只用过idea eclipse还没试) 在没加下面这步之前 不要用maven打包 这样idea会用你打好的包 这样也会报错。

2.如果要解决服务器上报这样错 在pom文件里加以下: 这样过后即便是打了包也没问题

pom文件里加

<build>
<finalName>xxxxxx</finalName>
<plugins>
<plugin>
<artifactId>maven-compiler-plugin</artifactId>
<version>3.5.1</version>

<configuration>
<!-- 以下是修改我们编译时的jdk版本 即使是高版本jdk 设置之后打包编译会根据你的设置的版本去执行 -->
<!-- use the Java 6 language features -->
<source>1.6</source>
<!-- want the compiled classes to be compatible with JVM 1.6 -->
<target>1.6</target>
<!-- The -encoding argument for the Java compiler. -->
<encoding>UTF8</encoding>
</configuration>

   </plugin>

</plugins>
</build>

Caused by: java.lang.IllegalArgumentException的更多相关文章

  1. 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 ...

  2. 解决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 ...

  3. 解决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

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

  4. Caused by: java.lang.IllegalArgumentException: argument type mismatch

    下面是我的报错信息 at org.apache.ibatis.session.defaults.DefaultSqlSession.selectList(DefaultSqlSession.java: ...

  5. java.sql.SQLException: Error setting driver on UnpooledDataSource.Caused by: java.lang.IllegalArgumentException: Result Maps collection does not contain value for IStudentDaoMapper.Mapperdao.selectcou

    是因为 Caused by: java.lang.IllegalArgumentException: Result Maps collection does not contain value for ...

  6. 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 ...

  7. Caused by: java.lang.IllegalArgumentException: Can not set int field reyo.sdk.enity.xxx.xxx to java.lang.Long

    由于数据库字段设置不正确引起的,不能选中 alter <table> modify <column> int unsigned; 关于unsigned int类型,可以看看它的 ...

  8. Caused by: java.lang.IllegalArgumentException: Modifying queries can only use void or int/Integer as return type!

    Caused by: java.lang.IllegalArgumentException: Modifying queries can only use void or int/Integer as ...

  9. SpringBoot启动报:Caused by: java.lang.IllegalArgumentException: At least one JPA metamodel must be present!

    使用spring boot对项目改造,启动报错: Caused by: java.lang.IllegalArgumentException: At least one JPA metamodel m ...

  10. kettle添加hadoop cluster时报错Caused by: java.lang.IllegalArgumentException: Does not contain a valid host:port authority: hadoop:password@node56:9000

    完整报错是: Caused by: java.lang.IllegalArgumentException: Does not contain a valid host:port authority: ...

随机推荐

  1. codeforces #332 div 2 D. Spongebob and Squares

    http://codeforces.com/contest/599/problem/D 题意:给出总的方格数x,问有多少种不同尺寸的矩形满足题意,输出方案数和长宽(3,5和5,3算两种) 思路:比赛的 ...

  2. tips [ 18870 ]

    Created at 2017-08-23 Updated at 2018-01-31 Category 东方大陆 Tag 东方大陆 上面有编辑时间的,别吐槽说什么过期内容了使用 lightPIC图床 ...

  3. FastCGI sent in stderr: "Access to the script 'XXX' has been denied (see security.limit_extensions)" 报错处理

    一个新Lnmp环境在调试项目时出现如下报错: 处理: 在php.ini中设置cgi.fix_pathinfo=1(默认为0),重新加载php即可.参考链接https://blog.csdn.net/u ...

  4. TabActivity中的Tab标签详细设置

    参考链接: http://www.iteye.com/topic/602737 这个写的很不错,我是跟着一步步写下来的,不过到最后也遇到了麻烦,就是不能将Tab标签的文字和图片分开,始终是重合的,而且 ...

  5. 如何进行Web服务的性能测试

         涉及到web服务的功能在不断的增加,对于我们测试来说,我们不仅要保证服务端功能的正确性,也要验证服务端程序的性能是否符合要求.那么性能测试都要做些什么呢?我们该怎样进行性能测试呢? 性能测试 ...

  6. kibana增加验证

    Kibana从5.5开始不提供认证功能,想用官方的认证X-Pack收费 ... 自己动手吧,用nginx的代理加apache生成的密码认证文件.环境:ubuntu16.04 安装nginxapt-ge ...

  7. 编写高质量 Objective-C 代码

    第一章 熟悉 Objective-C 第一条:了解 Objective-C 起源 Objective-C 是 C 语言动态性扩充.使用"消息结构"而非"函数调用" ...

  8. PS4游戏将登陆PC:一曲属于主机的悲歌

    ​​ ​ 曾经,红白机.PS游戏机等成为一代人难以磨灭的记忆.而随后的索尼PS3.微软Xbox 360.任天堂Wii U等,也称霸了次时代主机时代,成为家庭娱乐的中心.但面对着依托于PC和智能移动终端 ...

  9. Python 异常处理中的 esle

    前言 我们知道,在Python中,我们是用try- -excetp- - 来做异常处理的,但Python 有别于其他语法的是在异常处理中还提供了else的处理场景,是的,你没看错,就是在条件判断if- ...

  10. 算发帖&mdash;&mdash;俄罗斯方块覆盖问题一共有多少个解

    问题的提出:如下图,用13块俄罗斯方块覆盖8*8的正方形.   那么一共可以有多少个解呢?(若通过旋转.翻转一个解而得到的新解,则两个解视为同一个解)   首先,求解的问题,已经在上一篇帖子里完成 算 ...