经验啊,WAS6中ibatis解析异常Cause: sun.io.MalformedInputException

本文主要是介绍经验啊,WAS6中ibatis解析异常Cause: sun.io.MalformedInputException,希望对大家解决编程问题提供一定的参考价值,需要的开发者们随着小编来一起学习吧!

要在websphere上部署一个应用,websphere版本6.0
应用中用到了ibatis作为数据访问层,ibatis的xml文件中有一些中文注释,像这样的<!--   注释  -->,两边都空有两个空格
war包在本机tomcat 5.0上部署和访问都没有错误,但是部署在websphere上就报错,错误信息如下:

[08-12-27 9:09:21:375 CST] 0000003e SystemErr     R org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'com.abchina.csas.sch.service.impl.SchManagerServiceImpl#2409fc51' defined in ServletContext resource [/WEB-INF/classes/spring/applicationContext-sch.xml]: Can't resolve reference to bean 'schManagerDAO' while setting property 'schManagerDAO'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'schManagerDAO' defined in ServletContext resource [/WEB-INF/classes/spring/applicationContext-sch.xml]: Can't resolve reference to bean 'schSqlMapClient' while setting property 'sqlMapClient'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'schSqlMapClient' defined in ServletContext resource [/WEB-INF/classes/spring/applicationContext-resources.xml]: Initialization of bean failed; nested exception is com.ibatis.common.exception.NestedRuntimeException: Error occurred.  Cause: com.ibatis.common.xml.NodeletException: Error parsing XML.  Cause: com.ibatis.common.exception.NestedRuntimeException: Error parsing XPath '/sqlMapConfig/sqlMap'.  Cause: com.ibatis.common.xml.NodeletException: Error parsing XML.  Cause: sun.io.MalformedInputException
Caused by: sun.io.MalformedInputException
Caused by: com.ibatis.common.xml.NodeletException: Error parsing XML.  Cause: sun.io.MalformedInputException
Caused by: sun.io.MalformedInputException
Caused by: com.ibatis.common.exception.NestedRuntimeException: Error parsing XPath '/sqlMapConfig/sqlMap'.  Cause: com.ibatis.common.xml.NodeletException: Error parsing XML.  Cause: sun.io.MalformedInputException
Caused by: sun.io.MalformedInputException
Caused by: com.ibatis.common.xml.NodeletException: Error parsing XML.  Cause: sun.io.MalformedInputException
Caused by: sun.io.MalformedInputException
org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'schManagerDAO' defined in ServletContext resource [/WEB-INF/classes/spring/applicationContext-sch.xml]: Can't resolve reference to bean 'schSqlMapClient' while setting property 'sqlMapClient'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'schSqlMapClient' defined in ServletContext resource [/WEB-INF/classes/spring/applicationContext-resources.xml]: Initialization of bean failed; nested exception is com.ibatis.common.exception.NestedRuntimeException: Error occurred.  Cause: com.ibatis.common.xml.NodeletException: Error parsing XML.  Cause: com.ibatis.common.exception.NestedRuntimeException: Error parsing XPath '/sqlMapConfig/sqlMap'.  Cause: com.ibatis.common.xml.NodeletException: Error parsing XML.  Cause: sun.io.MalformedInputException
Caused by: sun.io.MalformedInputException
Caused by: com.ibatis.common.xml.NodeletException: Error parsing XML.  Cause: sun.io.MalformedInputException
Caused by: sun.io.MalformedInputException
Caused by: com.ibatis.common.exception.NestedRuntimeException: Error parsing XPath '/sqlMapConfig/sqlMap'.  Cause: com.ibatis.common.xml.NodeletException: Error parsing XML.  Cause: sun.io.MalformedInputException
Caused by: sun.io.MalformedInputException
Caused by: com.ibatis.common.xml.NodeletException: Error parsing XML.  Cause: sun.io.MalformedInputException
Caused by: sun.io.MalformedInputException
org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'schSqlMapClient' defined in ServletContext resource [/WEB-INF/classes/spring/applicationContext-resources.xml]: Initialization of bean failed; nested exception is com.ibatis.common.exception.NestedRuntimeException: Error occurred.  Cause: com.ibatis.common.xml.NodeletException: Error parsing XML.  Cause: com.ibatis.common.exception.NestedRuntimeException: Error parsing XPath '/sqlMapConfig/sqlMap'.  Cause: com.ibatis.common.xml.NodeletException: Error parsing XML.  Cause: sun.io.MalformedInputException
Caused by: sun.io.MalformedInputException
Caused by: com.ibatis.common.xml.NodeletException: Error parsing XML.  Cause: sun.io.MalformedInputException
Caused by: sun.io.MalformedInputException
Caused by: com.ibatis.common.exception.NestedRuntimeException: Error parsing XPath '/sqlMapConfig/sqlMap'.  Cause: com.ibatis.common.xml.NodeletException: Error parsing XML.  Cause: sun.io.MalformedInputException
Caused by: sun.io.MalformedInputException
Caused by: com.ibatis.common.xml.NodeletException: Error parsing XML.  Cause: sun.io.MalformedInputException
Caused by: sun.io.MalformedInputException
com.ibatis.common.exception.NestedRuntimeException: Error occurred.  Cause: com.ibatis.common.xml.NodeletException: Error parsing XML.  Cause: com.ibatis.common.exception.NestedRuntimeException: Error parsing XPath '/sqlMapConfig/sqlMap'.  Cause: com.ibatis.common.xml.NodeletException: Error parsing XML.  Cause: sun.io.MalformedInputException
Caused by: sun.io.MalformedInputException
Caused by: com.ibatis.common.xml.NodeletException: Error parsing XML.  Cause: sun.io.MalformedInputException
Caused by: sun.io.MalformedInputException
Caused by: com.ibatis.common.exception.NestedRuntimeException: Error parsing XPath '/sqlMapConfig/sqlMap'.  Cause: com.ibatis.common.xml.NodeletException: Error parsing XML.  Cause: sun.io.MalformedInputException
Caused by: sun.io.MalformedInputException
Caused by: com.ibatis.common.xml.NodeletException: Error parsing XML.  Cause: sun.io.MalformedInputException
Caused by: sun.io.MalformedInputException
Caused by: com.ibatis.common.xml.NodeletException: Error parsing XML.  Cause: com.ibatis.common.exception.NestedRuntimeException: Error parsing XPath '/sqlMapConfig/sqlMap'.  Cause: com.ibatis.common.xml.NodeletException: Error parsing XML.  Cause: sun.io.MalformedInputException
Caused by: sun.io.MalformedInputException
Caused by: com.ibatis.common.xml.NodeletException: Error parsing XML.  Cause: sun.io.MalformedInputException
Caused by: sun.io.MalformedInputException
Caused by: com.ibatis.common.exception.NestedRuntimeException: Error parsing XPath '/sqlMapConfig/sqlMap'.  Cause: com.ibatis.common.xml.NodeletException: Error parsing XML.  Cause: sun.io.MalformedInputException
Caused by: sun.io.MalformedInputException
Caused by: com.ibatis.common.xml.NodeletException: Error parsing XML.  Cause: sun.io.MalformedInputException
Caused by: sun.io.MalformedInputExceptionat com.ibatis.sqlmap.engine.builder.xml.SqlMapConfigParser.parse(SqlMapConfigParser.java:81)at com.ibatis.sqlmap.client.SqlMapClientBuilder.buildSqlMapClient(SqlMapClientBuilder.java:62)at org.springframework.orm.ibatis.SqlMapClientFactoryBean.afterPropertiesSet(SqlMapClientFactoryBean.java:258)at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1059)

 

解决办法:

MalformedInputException造成的原因就是IBM JDK重写了IO通道。原来1.4当中就有过类似的问题,原来解决方法是:
1.打开管理控制台,找到并选择运行这个JSP的应用服务器
2.依次选择进程定义,java虚拟机,一般JVM自变量
3.添加-Dibm.stream.nio=true
4.确定,保存
5.重新启动该服务器
 

 

这篇关于经验啊,WAS6中ibatis解析异常Cause: sun.io.MalformedInputException的文章就介绍到这儿,希望我们推荐的文章对编程师们有所帮助!



http://www.chinasem.cn/article/851566

相关文章

Java 关键字transient与注解@Transient的区别用途解析

《Java关键字transient与注解@Transient的区别用途解析》在Java中,transient是一个关键字,用于声明一个字段不会被序列化,这篇文章给大家介绍了Java关键字transi... 在Java中,transient 是一个关键字,用于声明一个字段不会被序列化。当一个对象被序列化时,被

Java JSQLParser解析SQL的使用指南

《JavaJSQLParser解析SQL的使用指南》JSQLParser是一个Java语言的SQL语句解析工具,可以将SQL语句解析成为Java类的层次结构,还支持改写SQL,下面我们就来看看它的具... 目录一、引言二、jsQLParser常见类2.1 Class Diagram2.2 Statement

python进行while遍历的常见错误解析

《python进行while遍历的常见错误解析》在Python中选择合适的遍历方式需要综合考虑可读性、性能和具体需求,本文就来和大家讲解一下python中while遍历常见错误以及所有遍历方法的优缺点... 目录一、超出数组范围问题分析错误复现解决方法关键区别二、continue使用问题分析正确写法关键点三

redis在spring boot中异常退出的问题解决方案

《redis在springboot中异常退出的问题解决方案》:本文主要介绍redis在springboot中异常退出的问题解决方案,本文给大家介绍的非常详细,对大家的学习或工作具有一定的参考借鉴... 目录问题:解决 问题根源️ 解决方案1. 异步处理 + 提前ACK(关键步骤)2. 调整Redis消费者组

springboot项目redis缓存异常实战案例详解(提供解决方案)

《springboot项目redis缓存异常实战案例详解(提供解决方案)》redis基本上是高并发场景上会用到的一个高性能的key-value数据库,属于nosql类型,一般用作于缓存,一般是结合数据... 目录缓存异常实践案例缓存穿透问题缓存击穿问题(其中也解决了穿透问题)完整代码缓存异常实践案例Red

使用Java实现Navicat密码的加密与解密的代码解析

《使用Java实现Navicat密码的加密与解密的代码解析》:本文主要介绍使用Java实现Navicat密码的加密与解密,通过本文,我们了解了如何利用Java语言实现对Navicat保存的数据库密... 目录一、背景介绍二、环境准备三、代码解析四、核心代码展示五、总结在日常开发过程中,我们有时需要处理各种软

Java内存区域与内存溢出异常的详细探讨

《Java内存区域与内存溢出异常的详细探讨》:本文主要介绍Java内存区域与内存溢出异常的相关资料,分析异常原因并提供解决策略,如参数调整、代码优化等,帮助开发者排查内存问题,需要的朋友可以参考下... 目录一、引言二、Java 运行时数据区域(一)程序计数器(二)Java 虚拟机栈(三)本地方法栈(四)J

Python多进程、多线程、协程典型示例解析(最新推荐)

《Python多进程、多线程、协程典型示例解析(最新推荐)》:本文主要介绍Python多进程、多线程、协程典型示例解析(最新推荐),本文通过实例代码给大家介绍的非常详细,对大家的学习或工作具有一定... 目录一、multiprocessing(多进程)1. 模块简介2. 案例详解:并行计算平方和3. 实现逻

Spring Boot拦截器Interceptor与过滤器Filter深度解析(区别、实现与实战指南)

《SpringBoot拦截器Interceptor与过滤器Filter深度解析(区别、实现与实战指南)》:本文主要介绍SpringBoot拦截器Interceptor与过滤器Filter深度解析... 目录Spring Boot拦截器(Interceptor)与过滤器(Filter)深度解析:区别、实现与实

解决Java异常报错:java.nio.channels.UnresolvedAddressException问题

《解决Java异常报错:java.nio.channels.UnresolvedAddressException问题》:本文主要介绍解决Java异常报错:java.nio.channels.Unr... 目录异常含义可能出现的场景1. 错误的 IP 地址格式2. DNS 解析失败3. 未初始化的地址对象解决