-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 4 posts ] 
Author Message
 Post subject: "Got -1 from a read call" When saving 1463 records
PostPosted: Wed Apr 23, 2008 11:31 am 
Newbie

Joined: Wed Apr 23, 2008 10:51 am
Posts: 4
Location: Lebanon
Hello,
In the web application we are saving arround 1463 records in one hit. Upon this event the application fails with the exception "- Io exception: Got minus one from a read call". However all the records have been successfully saved to the database.
What I noticed is whenever the save operation goes beyond 1 min we get this error if we stay below 1 minute it works.
What can I do to solve this issue?


Hibernate version:
3.2.6.ga

Full stack trace of any exception that occurs:
- Io exception: Got minus one from a read call
- #{rightConfigsBB.submit}: javax.faces.el.EvaluationException: javax.faces.FacesException: Could not save the right configuration
javax.faces.FacesException: #{rightConfigsBB.submit}: javax.faces.el.EvaluationException: javax.faces.FacesException: Could not save the right configuration
at com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:98)
at oracle.adf.view.faces.component.UIXCommand.broadcast(UIXCommand.java:211)
at javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:287)
at javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:401)
at com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:95)
at com.sun.faces.lifecycle.LifecycleImpl.phase(LifecycleImpl.java:245)
at com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:110)
at javax.faces.webapp.FacesServlet.service(FacesServlet.java:213)
at com.evermind.server.http.ResourceFilterChain.doFilter(ResourceFilterChain.java:65)
at com.fp.common.servlets.ApplicationSessionExpiryFilter.doFilter(ApplicationSessionExpiryFilter.java:49)
at com.evermind.server.http.EvermindFilterChain.doFilter(EvermindFilterChain.java:15)
at oracle.adfinternal.view.faces.webapp.AdfFacesFilterImpl._invokeDoFilter(AdfFacesFilterImpl.java:228)
at oracle.adfinternal.view.faces.webapp.AdfFacesFilterImpl._doFilterImpl(AdfFacesFilterImpl.java:197)
at oracle.adfinternal.view.faces.webapp.AdfFacesFilterImpl.doFilter(AdfFacesFilterImpl.java:123)
at oracle.adf.view.faces.webapp.AdfFacesFilter.doFilter(AdfFacesFilter.java:103)
at com.evermind.server.http.ServletRequestDispatcher.invoke(ServletRequestDispatcher.java:621)
at com.evermind.server.http.ServletRequestDispatcher.forwardInternal(ServletRequestDispatcher.java:370)
at com.evermind.server.http.HttpRequestHandler.doProcessRequest(HttpRequestHandler.java:871)
at com.evermind.server.http.HttpRequestHandler.processRequest(HttpRequestHandler.java:453)
at com.evermind.server.http.HttpRequestHandler.serveOneRequest(HttpRequestHandler.java:221)
at com.evermind.server.http.HttpRequestHandler.run(HttpRequestHandler.java:122)
at com.evermind.server.http.HttpRequestHandler.run(HttpRequestHandler.java:111)
at oracle.oc4j.network.ServerSocketReadHandler$SafeRunnable.run(ServerSocketReadHandler.java:260)
at com.evermind.util.ReleasableResourcePooledExecutor$MyWorker.run(ReleasableResourcePooledExecutor.java:303)
at java.lang.Thread.run(Thread.java:595)
Caused by: javax.faces.el.EvaluationException: javax.faces.FacesException: Could not save the right configuration
at com.sun.faces.el.MethodBindingImpl.invoke(MethodBindingImpl.java:150)
at com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:92)
... 24 more
Caused by: javax.faces.FacesException: Could not save the right configuration
at com.fp.rights.view.backing.rightsconfig.RightConfigsBB.submit(RightConfigsBB.java:687)
at sun.reflect.GeneratedMethodAccessor914.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at com.sun.faces.el.MethodBindingImpl.invoke(MethodBindingImpl.java:146)
... 25 more
Caused by: org.hibernate.exception.GenericJDBCException: Cannot open connection
at org.hibernate.exception.SQLStateConverter.handledNonSpecificException(SQLStateConverter.java:103)
at org.hibernate.exception.SQLStateConverter.convert(SQLStateConverter.java:91)
at org.hibernate.exception.JDBCExceptionHelper.convert(JDBCExceptionHelper.java:43)
at org.hibernate.exception.JDBCExceptionHelper.convert(JDBCExceptionHelper.java:29)
at org.hibernate.jdbc.ConnectionManager.openConnection(ConnectionManager.java:426)
at org.hibernate.jdbc.ConnectionManager.getConnection(ConnectionManager.java:144)
at org.hibernate.jdbc.BorrowedConnectionProxy.invoke(BorrowedConnectionProxy.java:50)
at $Proxy2.prepareCall(Unknown Source)
at com.fp.rights.model.dao.hibernate.RightConfigsDaoHibernateImpl.saveRightPath(RightConfigsDaoHibernateImpl.java:277)
at com.fp.rights.model.service.impl.RightConfigsServiceImpl.saveRightConfig(RightConfigsServiceImpl.java:393)
at com.fp.rights.view.backing.rightsconfig.RightConfigsBB.submit(RightConfigsBB.java:661)
... 29 more
Caused by: java.sql.SQLException: Io exception: Got minus one from a read call
at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:138)
at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:175)
at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:287)
at oracle.jdbc.driver.T4CConnection.logon(T4CConnection.java:328)
at oracle.jdbc.driver.PhysicalConnection.<init>(PhysicalConnection.java:430)
at oracle.jdbc.driver.T4CConnection.<init>(T4CConnection.java:151)
at oracle.jdbc.driver.T4CDriverExtension.getConnection(T4CDriverExtension.java:32)
at oracle.jdbc.driver.OracleDriver.connect(OracleDriver.java:608)
at java.sql.DriverManager.getConnection(DriverManager.java:525)
at java.sql.DriverManager.getConnection(DriverManager.java:140)
at org.springframework.jdbc.datasource.DriverManagerDataSource.getConnectionFromDriverManager(DriverManagerDataSource.java:291)
at org.springframework.jdbc.datasource.DriverManagerDataSource.getConnectionFromDriverManager(DriverManagerDataSource.java:277)
at org.springframework.jdbc.datasource.DriverManagerDataSource.getConnectionFromDriverManager(DriverManagerDataSource.java:259)
at org.springframework.jdbc.datasource.DriverManagerDataSource.getConnection(DriverManagerDataSource.java:240)
at org.springframework.orm.hibernate3.LocalDataSourceConnectionProvider.getConnection(LocalDataSourceConnectionProvider.java:81)
at org.hibernate.jdbc.ConnectionManager.openConnection(ConnectionManager.java:423)

Name and version of the database you are using:
Oracle 10.2.0.2


Top
 Profile  
 
 Post subject:
PostPosted: Wed May 07, 2008 8:38 am 
Newbie

Joined: Wed Apr 23, 2008 10:51 am
Posts: 4
Location: Lebanon
I would appreciate if somebody can give me some pointers on where and what to look for the source of the problem.

Maybe it's a configuration issue.

Thanks,
Charbel


Top
 Profile  
 
 Post subject:
PostPosted: Wed May 07, 2008 10:02 am 
Beginner
Beginner

Joined: Fri May 18, 2007 10:28 am
Posts: 48
Location: Madison, WI
If you use Oracle 10G there is a bug with it.

Check for bug #4400441. I think it is related to bug # 4417706.

If that is the case, it might happen only in your Windows platform.

_________________
Please rate if it helped


Top
 Profile  
 
 Post subject:
PostPosted: Wed May 14, 2008 1:16 pm 
Newbie

Joined: Wed Apr 23, 2008 10:51 am
Posts: 4
Location: Lebanon
It turns out that this error was caused by this issue is due to the fact that developer was calling a stored procedure in a loop and for each call requesting a connection via the getSession, this lead to the issue where the system was not able to provide any more connections.
The solution ;obviously; was to batch the calls for the stored procedure

Thanks for the help.


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 4 posts ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.