I believe I can fly

虫虫的Blog

  BlogJava :: 首页 :: 新随笔 :: 联系 :: 聚合  :: 管理 ::
  8 随笔 :: 2 文章 :: 2 评论 :: 0 Trackbacks

最近在用SSH做一个软件,在测试时,发现如果多刷新几次页面,提示Socket closed错误,貌似是连接丢失造成的,但是奇怪的是,过一段时间再刷新时,又正常了,再这样刷几次,又出同样的问题。查了好多资料,实在搞不定了。不知哪位同仁遇到过同样的问题,控制台输入如下:

2009-05-21 23:10:01,734 WARN [org.hibernate.util.JDBCExceptionReporter] - SQL Er
ror: 
17002, SQLState: null
2009-05-21 23:10:01,734 ERROR [org.hibernate.util.JDBCExceptionReporter] - Io 异
常: Socket closed
2009-05-21 23:10:01,734 WARN [org.hibernate.util.JDBCExceptionReporter] - SQL Er
ror: 
17002, SQLState: null
2009-05-21 23:10:01,734 ERROR [org.hibernate.util.JDBCExceptionReporter] - Io 异
常: Socket closed
org.hibernate.exception.GenericJDBCException: could not execute query
        at org.hibernate.exception.ErrorCodeConverter.handledNonSpecificExceptio
n(ErrorCodeConverter.java:
92)
        at org.hibernate.exception.ErrorCodeConverter.convert(ErrorCodeConverter
.java:
80)
        at org.hibernate.exception.JDBCExceptionHelper.convert(JDBCExceptionHelp
er.java:
43)
        at org.hibernate.loader.Loader.doList(Loader.java:
1596)
        at org.hibernate.loader.Loader.list(Loader.java:
1577)
        at org.hibernate.loader.hql.QueryLoader.list(QueryLoader.java:
395)
        at org.hibernate.hql.ast.QueryTranslatorImpl.list(QueryTranslatorImpl.ja
va:
271)
        at org.hibernate.impl.SessionImpl.list(SessionImpl.java:
844)
        at org.hibernate.impl.QueryImpl.list(QueryImpl.java:
74)
        at com.tkp.crm.dao.impl.ICustomerDAOImpl.queryAll(ICustomerDAOImpl.java:
22)
        at com.tkp.crm.struts.action.CustomerAction.listAll(CustomerAction.java:
59)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
java:
39)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
sorImpl.java:
25)
        at java.lang.reflect.Method.invoke(Method.java:
585)
        at org.apache.struts.actions.DispatchAction.dispatchMethod(DispatchActio
n.java:
270)
        at org.apache.struts.actions.DispatchAction.execute(DispatchAction.java:
187)
        at org.apache.struts.action.RequestProcessor.processActionPerform(Reques
tProcessor.java:
431)
        at org.apache.struts.action.RequestProcessor.process(RequestProcessor.ja
va:
236)
        at org.apache.struts.action.ActionServlet.process(ActionServlet.java:
119
6)
        at org.apache.struts.action.ActionServlet.doGet(ActionServlet.java:
414)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:
689)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:
802)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Appl
icationFilterChain.java:
237)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationF
ilterChain.java:
157)
        at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDisp
atcher.java:
704)
        at org.apache.catalina.core.ApplicationDispatcher.processRequest(Applica
tionDispatcher.java:
474)
        at org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationD
ispatcher.java:
409)
        at org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDis
patcher.java:
312)
        at org.apache.jasper.runtime.PageContextImpl.doForward(PageContextImpl.j
ava:
670)
        at org.apache.jasper.runtime.PageContextImpl.forward(PageContextImpl.jav
a:
637)
        at org.apache.jsp.index_jsp._jspService(index_jsp.java:
72)
        at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:
94)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:
802)
        at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper
.java:
324)
        at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:
2
92)
        at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:
236)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:
802)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Appl
icationFilterChain.java:
237)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationF
ilterChain.java:
157)
        at org.springframework.orm.hibernate3.support.OpenSessionInViewFilter.
do
FilterInternal(OpenSessionInViewFilter.java:
198)
        at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerR
equestFilter.java:
75)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Appl
icationFilterChain.java:
186)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationF
ilterChain.java:
157)
        at com.tkp.crm.filter.EncodingFilter.doFilter(EncodingFilter.java:
22)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Appl
icationFilterChain.java:
186)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationF
ilterChain.java:
157)
        at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperV
alve.java:
214)
        at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValv
eContext.java:
104)
        at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.jav
a:
520)
        at org.apache.catalina.core.StandardContextValve.invokeInternal(Standard
ContextValve.java:
198)
        at org.apache.catalina.core.StandardContextValve.invoke(StandardContextV
alve.java:
152)
        at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValv
eContext.java:
104)
        at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.jav
a:
520)
        at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.j
ava:
137)
        at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValv
eContext.java:
104)
        at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.j
ava:
118)
        at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValv
eContext.java:
102)
        at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.jav
a:
520)
        at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineVal
ve.java:
109)
        at org.apache.catalina.core.StandardValveContext.invokeNext(StandardValv
eContext.java:
104)
        at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.jav
a:
520)
        at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:
929)

        at org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:
16
0)
        at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java
:
799)
        at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.proce
ssConnection(Http11Protocol.java:
705)
        at org.apache.tomcat.util.net.TcpWorkerThread.runIt(PoolTcpEndpoint.java
:
577)
        at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadP
ool.java:
683)
        at java.lang.Thread.run(Thread.java:
595)
Caused by: java.sql.SQLException: Io 异常: Socket closed
        at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:
134)
        at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:
179)
        at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:
333)
        at oracle.jdbc.driver.OracleStatement.
<init>(OracleStatement.java:389)
        at oracle.jdbc.driver.OracleStatement.
<init>(OracleStatement.java:413)
        at oracle.jdbc.driver.OraclePreparedStatement.
<init>(OraclePreparedState
ment.java:
119)
        at oracle.jdbc.driver.OraclePreparedStatement.
<init>(OraclePreparedState
ment.java:
92)
        at oracle.jdbc.driver.OracleConnection.privatePrepareStatement(OracleCon
nection.java:
950)
        at oracle.jdbc.driver.OracleConnection.prepareStatement(OracleConnection
.java:
802)
        at org.apache.commons.dbcp.DelegatingConnection.prepareStatement(Delegat
ingConnection.java:
248)
        at org.apache.commons.dbcp.PoolingDataSource$PoolGuardConnectionWrapper.
prepareStatement(PoolingDataSource.java:
302)
        at org.hibernate.jdbc.AbstractBatcher.getPreparedStatement(AbstractBatch
er.java:
396)
        at org.hibernate.jdbc.AbstractBatcher.getPreparedStatement(AbstractBatch
er.java:
334)
        at org.hibernate.jdbc.AbstractBatcher.prepareQueryStatement(AbstractBatc
her.java:
88)
        at org.hibernate.loader.Loader.prepareQueryStatement(Loader.java:
1162)
        at org.hibernate.loader.Loader.doQuery(Loader.java:
390)
        at org.hibernate.loader.Loader.doQueryAndInitializeNonLazyCollections(Lo
ader.java:
218)
        at org.hibernate.loader.Loader.doList(Loader.java:
1593)
         
65 more
2009-05-21 23:10:05,015 WARN [org.hibernate.jdbc.ConnectionManager] - unclosed c
onnection, forgot to call close() on your session
?


QQ交流群:90623790
posted on 2009-05-21 23:17 虫虫 阅读(1961) 评论(0)  编辑  收藏

只有注册用户登录后才能发表评论。


网站导航: