站内搜索: 请输入搜索关键词

当前页面: 开发资料首页Eclipse 专题MyEclipse: 在运行时刻 改动java 文件保存后就报错

MyEclipse: 在运行时刻 改动java 文件保存后就报错

摘要: MyEclipse: 在运行时刻 改动java 文件保存后就报错


错误信息如下:怎么解决啊
006-4-16 14:55:42 org.apache.catalina.core.StandardContext reload
信息: Reloading this Context has started
14:55:42,375 INFO [/sinew]:638 - Closing Spring root WebApplicationContext
14:55:42,375 INFO XmlWebApplicationContext:516 - Closing application context [Root WebApplicationContext]
14:55:42,375 INFO DefaultListableBeanFactory:550 - Destroying singletons in factory {org.springframework.beans.factory.support.DefaultListableBeanFactory defining beans [dataSource,sessionFactory,sinewHibernateInterceptor,sinewTransactionManager,baseTxProxy,functionDao,functionServiceTarget,functionServiceProxy,userDao,userService,userServiceProxy,bbsUserDao,bbsUserService,bbsUserServiceProxy,bbsCategoryDao,bbsCategoryService,bbsCategoryServiceProxy,bbsForumDao,bbsForumService,bbsForumServiceProxy,bbsTopicDao,bbsTopicService,bbsTopicServiceProxy,siteInfoDao,siteInfoService,siteInfoServiceProxy,channelDao,channelService,channelServiceProxy,siteClassDao,siteClassService,siteClassServiceProxy,specialDao,specialService,specialServiceProxy,voteDao,voteService,voteServiceProxy,bulletinDao,bulletinService,bulletinServiceProxy,noticeDao,noticeService,noticeServiceProxy,friendSiteDao,friendSiteService,friendSiteServiceProxy,articleDao,articleService,articleServiceProxy]; root of BeanFactory hierarchy}
14:55:42,375 INFO LocalSessionFactoryBean:958 - Closing Hibernate SessionFactory
14:55:42,390 INFO SessionFactoryImpl:727 - closing
14:55:42,437 ERROR [/sinew]:667 - Servlet action threw unload() exception
javax.servlet.ServletException: Servlet.destroy() for servlet action threw exception
at org.apache.catalina.core.StandardWrapper.unload(StandardWrapper.java:1344)
at org.apache.catalina.core.StandardWrapper.stop(StandardWrapper.java:1666)
at org.apache.catalina.core.ContainerBase.removeChild(ContainerBase.java:892)
at org.apache.catalina.core.StandardContext.removeChild(StandardContext.java:3093)
at org.apache.catalina.startup.ContextConfig.stop(ContextConfig.java:1107)
..........
14:55:44,875 INFO ContextLoader:146 - Root WebApplicationContext: initialization started
log4j:ERROR Error occured while converting date.
java.lang.NullPointerException
at java.lang.System.arraycopy(Native Method)
at java.lang.AbstractStringBuilder.getChars(AbstractStringBuilder.java:331)
at java.lang.StringBuffer.getChars(StringBuffer.java:202)
at org.apache.log4j.helpers.AbsoluteTimeDateFormat.format(AbsoluteTimeDateFormat.java:117)
at java.text.DateFormat.format(DateFormat.java:314)
...........
log4j:ERROR Error occured while converting date.
java.lang.NullPointerException
at java.lang.System.arraycopy(Native Method)
at java.lang.AbstractStringBuilder.getChars(AbstractStringBuilder.java:331)
at java.lang.StringBuffer.getChars(StringBuffer.java:202)
at org.apache.log4j.helpers.AbsoluteTimeDateFormat.format(AbsoluteTimeDateFormat.java:117)
at java.text.DateFormat.format(DateFormat.java:314)
at org.apache.log4j.helpers.PatternParser$DatePatternConverter.convert(PatternParser.java:444)
at org.apache.log4j.helpers.PatternConverter.format(PatternConverter.java:64)
at org.apache.log4j.PatternLayout.format(PatternLayout.java:503)
...........
2006-4-16 14:55:44 org.apache.catalina.core.ContainerBase backgroundProcess
警告: Exception processing loader WebappLoader[/sinew] background process
java.lang.NullPointerException
at org.apache.log4j.spi.LocationInfo.(LocationInfo.java:104)
at org.apache.log4j.spi.LoggingEvent.getLocationInformation(LoggingEvent.java:191)
at org.apache.log4j.helpers.PatternParser$LocationPatternConverter.convert(PatternParser.java:483)
at org.apache.log4j.helpers.PatternConverter.format(PatternConverter.java:64)
at org.apache.log4j.PatternLayout.format(PatternLayout.java:503)


如果eclipse是自动编译,在运行时候做改动可能会有影响。你最好把程序停下来,再做修改,看是否有语法错误,再执行,看看结果是否正确。


因为我不是很清楚你是如何发布工程的。在你tomcat下进行web工程映射的相应配置的reloadable="true"属性改为reloadable="false"这样在运行时修改java文件时eclipse自动编译class时tomcat也不会自动加载class了。


谢谢楼上的


呵呵


↑返回目录
前一篇: 一个超级简单的问题,郁闷了3天。Java连接oracle数据库!!
后一篇: 为什么request.setAttribute()后面的Object参数不能是boolean类型的?