java.lang.ClassFormatError Duplicate field name&signature in class file XXXXXX【转】
本文转载自:https://blog.csdn.net/ylchou/article/details/7739742
2012-7-5 15:06:25org.apache.catalina.core.StandardWrapperValve invoke
严重:Servlet.service() for servlet LotteryServlet threw exception
java.lang.ClassFormatError:Duplicate field name&signature in class file Fastjson_ASM_DateDataModel_2
atjava.lang.ClassLoader.defineClass1(Native Method)
atjava.lang.ClassLoader.defineClassCond(ClassLoader.java:632)
atjava.lang.ClassLoader.defineClass(ClassLoader.java:616)
atcom.alibaba.fastjson.util.ASMClassLoader.defineClassPublic(ASMClassLoader.java:24)
atcom.alibaba.fastjson.parser.deserializer.ASMDeserializerFactory.createJavaBeanDeserializer(ASMDeserializerFactory.java:91)
atcom.alibaba.fastjson.parser.ParserConfig.createJavaBeanDeserializer(ParserConfig.java:333)
atcom.alibaba.fastjson.parser.ParserConfig.getDeserializer(ParserConfig.java:311)
atcom.alibaba.fastjson.parser.ParserConfig.getDeserializer(ParserConfig.java:260)
atcom.alibaba.fastjson.parser.DefaultJSONParser.parseArray(DefaultJSONParser.java:506)
atcom.alibaba.fastjson.parser.DefaultJSONParser.parseArray(DefaultJSONParser.java:489)
atcom.alibaba.fastjson.parser.DefaultJSONParser.parseArray(DefaultJSONParser.java:484)
atcom.alibaba.fastjson.JSON.parseArray(JSON.java:294)
atcom.lottery.service.lottery.DateQueryService.authentication(DateQueryService.java:62)
atcom.lottery.service.lottery.DateQueryService.getRes(DateQueryService.java:34)
atcom.lottery.servlet.LotteryServlet.doMsg00(LotteryServlet.java:253)
atcom.lottery.servlet.LotteryServlet.doPost(LotteryServlet.java:74)
atjavax.servlet.http.HttpServlet.service(HttpServlet.java:637)
atjavax.servlet.http.HttpServlet.service(HttpServlet.java:717)
atorg.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
atorg.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
atorg.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)
atorg.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
atorg.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
atorg.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
atorg.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
atorg.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:298)
atorg.apache.coyote.http11.Http11AprProcessor.process(Http11AprProcessor.java:864)
atorg.apache.coyote.http11.Http11AprProtocol$Http11ConnectionHandler.process(Http11AprProtocol.java:579)
atorg.apache.tomcat.util.net.AprEndpoint$Worker.run(AprEndpoint.java:1665)
atjava.lang.Thread.run(Thread.java:662)
出错地方:
package com.lottery.model.lottery;
public class DateDataModel2
{
privateString poscode; // 玩法ID
privateLong salmoney; // 当天销售金额
privateLong cashmoney; // 当前兑奖金额
publiclong getSalmoney()
{
returnsalmoney;
}
publicvoid setSalmoney(long salmoney)
{
this.salmoney= salmoney;
}
publicString getPoscode()
{
returnposcode;
}
publicvoid setPoscode(String poscode)
{
this.poscode= poscode;
}
publicvoid setSalmoney(Long salmoney)
{
this.salmoney= salmoney;
}
publicvoid setCashmoney(Long cashmoney)
{
this.cashmoney= cashmoney;
}
publiclong getCashmoney()
{
returncashmoney;
}
publicvoid setCashmoney(long cashmoney)
{
this.cashmoney= cashmoney;
}
}
原因:
setSalmoney()和setCashmoney各2个。
解决:
setSalmoney()和setCashmoney各去掉1个即可。
如下即可解决:
package com.lottery.model.lottery;
publicclass DateDataModel
{
private String poscode; // 玩法ID
private Long salmoney; // 当天销售金额
private Long cashmoney; // 当前兑奖金额
// public long getSalmoney()
// {
// return salmoney;
// }
//
// public void setSalmoney(long salmoney)
// {
// this.salmoney = salmoney;
// }
public String getPoscode()
{
returnposcode;
}
publicvoid setPoscode(String poscode)
{
this.poscode = poscode;
}
public Long getSalmoney() {
returnsalmoney;
}
publicvoid setSalmoney(Long salmoney)
{
this.salmoney = salmoney;
}
publicvoid setCashmoney(Long cashmoney)
{
this.cashmoney = cashmoney;
}
public Long getCashmoney() {
returncashmoney;
}
// public long getCashmoney()
// {
// return cashmoney;
// }
//
// public void setCashmoney(long cashmoney)
// {
// this.cashmoney = cashmoney;
// }
}
java.lang.ClassFormatError Duplicate field name&signature in class file XXXXXX【转】的更多相关文章
- java.lang.ClassFormatError: Unknown constant tag 0 in class file
在通过文件上传之后,运行java程序,突然发现这么一个错误:java.lang.ClassFormatError: Unknown constant tag 0 in class file,通过网上查 ...
- java.lang.ClassFormatError
Error occurred during initialization of VMjava.lang.ClassFormatError: Unknown constant tag 26 in cla ...
- IZ65534: 'JAVA.LANG.CLASSFORMATERROR' ERROR FOR A VALID IDENTIFIER
PAR status Closed as program error. Error description Error Message: The java class could not be loa ...
- java.lang.ClassFormatError: Extra bytes at the end of class file
在精简JRE过程中,将rt.jar中类通过FileInputStream,FileOutputStream进行拷贝操作出错: java.lang.ClassFormatError: Extra byt ...
- java.lang.ClassFormatError: Illegal UTF8 string in constant pool in class file Server/Request
Linux服务器上,将本地编译好的文件上传后,Tomcat启动时报错: Exception in thread "Thread-2" java.lang.ClassFormatEr ...
- JDK8 stream toMap() java.lang.IllegalStateException: Duplicate key异常解决(key重复)
测试又报bug啦 接到测试小伙伴的问题,说是一个接口不返回数据了,好吧,虽然不是我写的接口任务落到头上也得解决,本地调试了一下,好家伙,直接抛了个异常出来,这又是哪位大哥喝醉了写的代码... Exce ...
- 【我的Android进阶之旅】解决sqlcipher库:java.lang.IllegalStateException: get field slot from row 0 col 0 failed.
一.背景 最近维护公司的大数据SDK,在大数据SDK里面加入了ANR的监控功能,并将ANR的相关信息通过大数据埋点的方式记录到了数据库中,然后大数据上报的时候上报到大数据平台,这样就可以实现ANR性能 ...
- spring运行时没有问题,在单元测试时,出现java.lang.ClassFormatError错误
Caused by: java.lang.ClassFormatError: Absent Code attribute in method that is not native or abstrac ...
- 大型网站技术架构(四)--核心架构要素 开启mac上印象笔记的代码块 大型网站技术架构(三)--架构模式 JDK8 stream toMap() java.lang.IllegalStateException: Duplicate key异常解决(key重复)
大型网站技术架构(四)--核心架构要素 作者:13GitHub:https://github.com/ZHENFENG13版权声明:本文为原创文章,未经允许不得转载.此篇已收录至<大型网站技 ...
随机推荐
- 26计算限制的异步操作02-CLR
由CLR via C#(第三版) ,摘抄记录... 6 Parallel的静态For,ForEach和Invoke方法 在一些常见的编程情形中,使用任务也许会提升性能.为了简化编程,静态类System ...
- centos7下挂载U盘和移动硬盘
挂载U盘 1.使用fdisk -l命令查看磁盘情况 [root@localhost ~]# fdisk -l 磁盘 /dev/sda:1000.2 GB, 1000204886016 字节,19535 ...
- haml入门
1.什么是Haml Haml是HTML abstraction markup language,遵循的原则是标记应该是美的.Haml能够加速和简化模版,长处是简洁.可读.高效. 2.erbm模板和ha ...
- Android开发:《Gradle Recipes for Android》阅读笔记1.6——使用android studio添加依赖
有经验的gradle开发者习惯直接编辑build.gradle文件,但是IDE没有提供许多代码提示.IDE提供了一个可视的界面显示配置内容. 点击像文件夹一样的图标可以看到project struct ...
- [Spring Framework]学习笔记--Dependency injection(DI)
1. 通过构造函数实现DI 简单类型实例 package examples; public class ExampleBean { // Number of years to calculate th ...
- J - 迷宫问题(BFS)
J - 迷宫问题 Time Limit:1000MS Memory Limit:65536KB 64bit IO Format:%I64d & %I64u Descriptio ...
- Springboot 热部署中存在冲突的问题
SpringBoot热部署有2中: 1.使用 Spring Loaded 2.使用 spring-boot-devtools 具体怎么用.自己百度! 在使用第一种时候,整合SpringBoot和通用M ...
- ubuntu1.4搭建zookeeper3.5.2分布式集群
1.下载 官网链接:http://mirrors.hust.edu.cn/apache/zookeeper/zookeeper-3.5.2-alpha/zookeeper-3.5.2-alpha.ta ...
- 64位matlab mex64位编译器解决方案
安装libsvm的时候用到了mex -setup,有的会报 Could not find the 64-bit compiler. This may indicate that the "X ...
- The JVM found at JAVA_HOME is damaged.Please reinstall or define EXE4J_JAVA_HOME to point to an installed 32-bit JDK or JRE
一.介绍 exe4j是一个很棒的工具,可以把jar包打包成exe进行运行.他可以把jre环境和打包的exe进行集成,使得打包后的exe应用程序可以在没有安装java的机器上运行(前提是要把exe和jr ...