RE: Tool to diagnose J2EE/Struts/Oracle problem
Amin: Yes we have have multiple users using sqlplus and everything works ok. SO the database is find. Somehow, the I think the problem is either in the JVM provided with Weblogic or the Oracle drivers because even though the oracle connections are ideled, they cannot be reused. Can you tell me what do you mean by 'hibernate' site. Are you referring to the Oracle site? Regards, Stella Auyeung EDS Digital Enablement - Saginaw 6200 State Street, Suite 1 Saginaw, MI 48603 * phone: 989-497-5766 (8-399) * pager: 989-201-1030 * mailto:[EMAIL PROTECTED] -Original Message- From: Mohd Amin Mohd Din [mailto:[EMAIL PROTECTED] Sent: Wednesday, September 17, 2003 11:07 PM To: 'Struts Users Mailing List' Subject: RE: Tool to diagnose J2EE/Struts/Oracle problem Is your oracle database configured properly? Try connecting multiple users using oem or sqlplus to rule out is the issue is from the database. I had a max cursor reached error before which was attributed to not closing the preparedstatement. Another thing you may try is to use the latest JDBC drivers. There are some issues with 9.0.3 and below drivers, found out on hibernate site. Amin -Original Message- From: Au-Yeung, Stella H [mailto:[EMAIL PROTECTED] Sent: Thursday, September 18, 2003 10:52 AM To: Struts Users Mailing List Subject: Tool to diagnose J2EE/Struts/Oracle problem I am havng a No resource Available problem with my J2EE/Struts/Oracle application. It is saying I don't have any more Oracle connections available. Even I am closing the result set, statement and connection, I am still running into the problem. When I use the Oracle DBA monitor tool, it shows that I have 10 'inactive' connection but then my app will give the 'no resource available' error. So it looks like somehow it is not reusing those inactive connections. Does Gabage Collection release those connections? Does anyone have this problem before? So I am looking for a better 'tool' to find out why GC doesn't release those connections or if those 10 'inactive' connections are actually available to be re-used. Can someone give me a suggestion on this tool or how to troubleshoot the problem? Thanks Stella - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Tool to diagnose J2EE/Struts/Oracle problem
Matt: You mentioned the following: Garbage collection does not release database connections. IN that case, do you know who releases the connections and make it available for re-use after conn.close() has been done. It sounds like you must have read from somewhere that said GC doesn't release connections. Stella -Original Message- From: Sgarlata Matt [mailto:[EMAIL PROTECTED] Sent: Wednesday, September 17, 2003 10:56 PM To: Struts Users Mailing List Subject: Re: Tool to diagnose J2EE/Struts/Oracle problem You should investigate using connection pooling, such as is offered by the DBCP project, which is a Jakarta Commons subproject. Garbage collection does not release database connections. I'm not sure on all the details why not, but there are other reasons to use connection pooling such as performance. - Original Message - From: Au-Yeung, Stella H [EMAIL PROTECTED] To: Struts Users Mailing List [EMAIL PROTECTED] Sent: Wednesday, September 17, 2003 10:52 PM Subject: Tool to diagnose J2EE/Struts/Oracle problem I am havng a No resource Available problem with my J2EE/Struts/Oracle application. It is saying I don't have any more Oracle connections available. Even I am closing the result set, statement and connection, I am still running into the problem. When I use the Oracle DBA monitor tool, it shows that I have 10 'inactive' connection but then my app will give the 'no resource available' error. So it looks like somehow it is not reusing those inactive connections. Does Gabage Collection release those connections? Does anyone have this problem before? So I am looking for a better 'tool' to find out why GC doesn't release those connections or if those 10 'inactive' connections are actually available to be re-used. Can someone give me a suggestion on this tool or how to troubleshoot the problem? Thanks Stella - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Tool to diagnose J2EE/Struts/Oracle problem
Hi again Stella, Let me start by saying that I am also using Struts and Oracle, so we have a similar setup. We were experiencing the same problems you were experiencing until we set up connection pooling. I highly recommend that you develop your app using the org.apache.commons.dbcp.AbandonedObjectPool because it is the only way to make sure you are dealing with connections correctly. To use connections properly you must close them when you are done and this class makes sure you do, otherwise it starts throwing exceptions. For more information, see http://jakarta.apache.org/tomcat/tomcat-4.1-doc/jndi-datasource-examples-howto.html#Database%20Connection%20Pool%20(DBCP)%20Configurations in the section called Preventing db connection pool leaks. For production we are using the pool that comes with Oracle's application server, release 2. Also, additional comments to your specific questions are below. - Original Message - From: Au-Yeung, Stella H [EMAIL PROTECTED] To: 'Struts Users Mailing List' [EMAIL PROTECTED] Sent: Thursday, September 18, 2003 12:10 PM Subject: RE: Tool to diagnose J2EE/Struts/Oracle problem Matt: You mentioned the following: Garbage collection does not release database connections. IN that case, do you know who releases the connections and make it available for re-use after conn.close() has been done. It sounds like you must have read from somewhere that said GC doesn't release connections. To the best of my knowledge conn.close() should close the connection so that it no longer displays as a used connection in Oracle. However, if your app is like mine probably a dozen or so connections are opened for each Action that is performed, so it's hard to ensure you are closing all connections correctly. This is where the AbandonedObjectPool I discussed earlier comes into play. The GC won't call conn.close() for you, and you probably just forgot to close connections in a few places. Even after practicing for weeks I still forget to close connections weekly and AbandonedObjectPool comes to the rescue :) Stella -Original Message- From: Sgarlata Matt [mailto:[EMAIL PROTECTED] Sent: Wednesday, September 17, 2003 10:56 PM To: Struts Users Mailing List Subject: Re: Tool to diagnose J2EE/Struts/Oracle problem You should investigate using connection pooling, such as is offered by the DBCP project, which is a Jakarta Commons subproject. Garbage collection does not release database connections. I'm not sure on all the details why not, but there are other reasons to use connection pooling such as performance. - Original Message - From: Au-Yeung, Stella H [EMAIL PROTECTED] To: Struts Users Mailing List [EMAIL PROTECTED] Sent: Wednesday, September 17, 2003 10:52 PM Subject: Tool to diagnose J2EE/Struts/Oracle problem I am havng a No resource Available problem with my J2EE/Struts/Oracle application. It is saying I don't have any more Oracle connections available. Even I am closing the result set, statement and connection, I am still running into the problem. When I use the Oracle DBA monitor tool, it shows that I have 10 'inactive' connection but then my app will give the 'no resource available' error. So it looks like somehow it is not reusing those inactive connections. Does Gabage Collection release those connections? Does anyone have this problem before? So I am looking for a better 'tool' to find out why GC doesn't release those connections or if those 10 'inactive' connections are actually available to be re-used. Can someone give me a suggestion on this tool or how to troubleshoot the problem? Thanks Stella - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Tool to diagnose J2EE/Struts/Oracle problem
Matt, However, if your app is like mine probably a dozen or so connections are opened for each Action that is performed, so it's hard to ensure you are closing all connections correctly. Do you really have that many nested result sets? If not, then you could reuse the same connections for some of your queries. Reagards, Richard -Original Message- From: Sgarlata Matt [mailto:[EMAIL PROTECTED] Sent: Thursday, September 18, 2003 9:26 AM To: Struts Users Mailing List Subject: Re: Tool to diagnose J2EE/Struts/Oracle problem Hi again Stella, Let me start by saying that I am also using Struts and Oracle, so we have a similar setup. We were experiencing the same problems you were experiencing until we set up connection pooling. I highly recommend that you develop your app using the org.apache.commons.dbcp.AbandonedObjectPool because it is the only way to make sure you are dealing with connections correctly. To use connections properly you must close them when you are done and this class makes sure you do, otherwise it starts throwing exceptions. For more information, see http://jakarta.apache.org/tomcat/tomcat-4.1-doc/jndi-datasource-examples-how to.html#Database%20Connection%20Pool%20(DBCP)%20Configurations in the section called Preventing db connection pool leaks. For production we are using the pool that comes with Oracle's application server, release 2. Also, additional comments to your specific questions are below. - Original Message - From: Au-Yeung, Stella H [EMAIL PROTECTED] To: 'Struts Users Mailing List' [EMAIL PROTECTED] Sent: Thursday, September 18, 2003 12:10 PM Subject: RE: Tool to diagnose J2EE/Struts/Oracle problem Matt: You mentioned the following: Garbage collection does not release database connections. IN that case, do you know who releases the connections and make it available for re-use after conn.close() has been done. It sounds like you must have read from somewhere that said GC doesn't release connections. To the best of my knowledge conn.close() should close the connection so that it no longer displays as a used connection in Oracle. However, if your app is like mine probably a dozen or so connections are opened for each Action that is performed, so it's hard to ensure you are closing all connections correctly. This is where the AbandonedObjectPool I discussed earlier comes into play. The GC won't call conn.close() for you, and you probably just forgot to close connections in a few places. Even after practicing for weeks I still forget to close connections weekly and AbandonedObjectPool comes to the rescue :) Stella -Original Message- From: Sgarlata Matt [mailto:[EMAIL PROTECTED] Sent: Wednesday, September 17, 2003 10:56 PM To: Struts Users Mailing List Subject: Re: Tool to diagnose J2EE/Struts/Oracle problem You should investigate using connection pooling, such as is offered by the DBCP project, which is a Jakarta Commons subproject. Garbage collection does not release database connections. I'm not sure on all the details why not, but there are other reasons to use connection pooling such as performance. - Original Message - From: Au-Yeung, Stella H [EMAIL PROTECTED] To: Struts Users Mailing List [EMAIL PROTECTED] Sent: Wednesday, September 17, 2003 10:52 PM Subject: Tool to diagnose J2EE/Struts/Oracle problem I am havng a No resource Available problem with my J2EE/Struts/Oracle application. It is saying I don't have any more Oracle connections available. Even I am closing the result set, statement and connection, I am still running into the problem. When I use the Oracle DBA monitor tool, it shows that I have 10 'inactive' connection but then my app will give the 'no resource available' error. So it looks like somehow it is not reusing those inactive connections. Does Gabage Collection release those connections? Does anyone have this problem before? So I am looking for a better 'tool' to find out why GC doesn't release those connections or if those 10 'inactive' connections are actually available to be re-used. Can someone give me a suggestion on this tool or how to troubleshoot the problem? Thanks Stella - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED
RE: Tool to diagnose J2EE/Struts/Oracle problem
http://hibernate.bluemars.net/80.html -Original Message- From: Au-Yeung, Stella H [mailto:[EMAIL PROTECTED] Sent: Friday, September 19, 2003 12:06 AM To: 'Struts Users Mailing List' Subject: RE: Tool to diagnose J2EE/Struts/Oracle problem Amin: Yes we have have multiple users using sqlplus and everything works ok. SO the database is find. Somehow, the I think the problem is either in the JVM provided with Weblogic or the Oracle drivers because even though the oracle connections are ideled, they cannot be reused. Can you tell me what do you mean by 'hibernate' site. Are you referring to the Oracle site? Regards, Stella Auyeung EDS Digital Enablement - Saginaw 6200 State Street, Suite 1 Saginaw, MI 48603 * phone: 989-497-5766 (8-399) * pager: 989-201-1030 * mailto:[EMAIL PROTECTED] -Original Message- From: Mohd Amin Mohd Din [mailto:[EMAIL PROTECTED] Sent: Wednesday, September 17, 2003 11:07 PM To: 'Struts Users Mailing List' Subject: RE: Tool to diagnose J2EE/Struts/Oracle problem Is your oracle database configured properly? Try connecting multiple users using oem or sqlplus to rule out is the issue is from the database. I had a max cursor reached error before which was attributed to not closing the preparedstatement. Another thing you may try is to use the latest JDBC drivers. There are some issues with 9.0.3 and below drivers, found out on hibernate site. Amin -Original Message- From: Au-Yeung, Stella H [mailto:[EMAIL PROTECTED] Sent: Thursday, September 18, 2003 10:52 AM To: Struts Users Mailing List Subject: Tool to diagnose J2EE/Struts/Oracle problem I am havng a No resource Available problem with my J2EE/Struts/Oracle application. It is saying I don't have any more Oracle connections available. Even I am closing the result set, statement and connection, I am still running into the problem. When I use the Oracle DBA monitor tool, it shows that I have 10 'inactive' connection but then my app will give the 'no resource available' error. So it looks like somehow it is not reusing those inactive connections. Does Gabage Collection release those connections? Does anyone have this problem before? So I am looking for a better 'tool' to find out why GC doesn't release those connections or if those 10 'inactive' connections are actually available to be re-used. Can someone give me a suggestion on this tool or how to troubleshoot the problem? Thanks Stella - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Tool to diagnose J2EE/Struts/Oracle problem
I am havng a No resource Available problem with my J2EE/Struts/Oracle application. It is saying I don't have any more Oracle connections available. Even I am closing the result set, statement and connection, I am still running into the problem. When I use the Oracle DBA monitor tool, it shows that I have 10 'inactive' connection but then my app will give the 'no resource available' error. So it looks like somehow it is not reusing those inactive connections. Does Gabage Collection release those connections? Does anyone have this problem before? So I am looking for a better 'tool' to find out why GC doesn't release those connections or if those 10 'inactive' connections are actually available to be re-used. Can someone give me a suggestion on this tool or how to troubleshoot the problem? Thanks Stella - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Tool to diagnose J2EE/Struts/Oracle problem
You should investigate using connection pooling, such as is offered by the DBCP project, which is a Jakarta Commons subproject. Garbage collection does not release database connections. I'm not sure on all the details why not, but there are other reasons to use connection pooling such as performance. - Original Message - From: Au-Yeung, Stella H [EMAIL PROTECTED] To: Struts Users Mailing List [EMAIL PROTECTED] Sent: Wednesday, September 17, 2003 10:52 PM Subject: Tool to diagnose J2EE/Struts/Oracle problem I am havng a No resource Available problem with my J2EE/Struts/Oracle application. It is saying I don't have any more Oracle connections available. Even I am closing the result set, statement and connection, I am still running into the problem. When I use the Oracle DBA monitor tool, it shows that I have 10 'inactive' connection but then my app will give the 'no resource available' error. So it looks like somehow it is not reusing those inactive connections. Does Gabage Collection release those connections? Does anyone have this problem before? So I am looking for a better 'tool' to find out why GC doesn't release those connections or if those 10 'inactive' connections are actually available to be re-used. Can someone give me a suggestion on this tool or how to troubleshoot the problem? Thanks Stella - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Tool to diagnose J2EE/Struts/Oracle problem
Is your oracle database configured properly? Try connecting multiple users using oem or sqlplus to rule out is the issue is from the database. I had a max cursor reached error before which was attributed to not closing the preparedstatement. Another thing you may try is to use the latest JDBC drivers. There are some issues with 9.0.3 and below drivers, found out on hibernate site. Amin -Original Message- From: Au-Yeung, Stella H [mailto:[EMAIL PROTECTED] Sent: Thursday, September 18, 2003 10:52 AM To: Struts Users Mailing List Subject: Tool to diagnose J2EE/Struts/Oracle problem I am havng a No resource Available problem with my J2EE/Struts/Oracle application. It is saying I don't have any more Oracle connections available. Even I am closing the result set, statement and connection, I am still running into the problem. When I use the Oracle DBA monitor tool, it shows that I have 10 'inactive' connection but then my app will give the 'no resource available' error. So it looks like somehow it is not reusing those inactive connections. Does Gabage Collection release those connections? Does anyone have this problem before? So I am looking for a better 'tool' to find out why GC doesn't release those connections or if those 10 'inactive' connections are actually available to be re-used. Can someone give me a suggestion on this tool or how to troubleshoot the problem? Thanks Stella - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Tool to diagnose J2EE/Struts/Oracle problem
I think you should try toplink from oracle for your connection to database. -Original Message- From: Au-Yeung, Stella H [mailto:[EMAIL PROTECTED] Sent: Thursday, September 18, 2003 9:52 AM To: Struts Users Mailing List Subject: Tool to diagnose J2EE/Struts/Oracle problem I am havng a No resource Available problem with my J2EE/Struts/Oracle application. It is saying I don't have any more Oracle connections available. Even I am closing the result set, statement and connection, I am still running into the problem. When I use the Oracle DBA monitor tool, it shows that I have 10 'inactive' connection but then my app will give the 'no resource available' error. So it looks like somehow it is not reusing those inactive connections. Does Gabage Collection release those connections? Does anyone have this problem before? So I am looking for a better 'tool' to find out why GC doesn't release those connections or if those 10 'inactive' connections are actually available to be re-used. Can someone give me a suggestion on this tool or how to troubleshoot the problem? Thanks Stella - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Tool to diagnose J2EE/Struts/Oracle problem
Hi hari, Could you provide some more info on using the toplink w.r.t to struts, EJB and oracle database. I would like to see few lines of toplink code. Thanks, Viral -Original Message- From: hari_s [mailto:[EMAIL PROTECTED] Sent: Thursday, September 18, 2003 10:06 AM To: 'Struts Users Mailing List' Subject: RE: Tool to diagnose J2EE/Struts/Oracle problem I think you should try toplink from oracle for your connection to database. -Original Message- From: Au-Yeung, Stella H [mailto:[EMAIL PROTECTED] Sent: Thursday, September 18, 2003 9:52 AM To: Struts Users Mailing List Subject: Tool to diagnose J2EE/Struts/Oracle problem I am havng a No resource Available problem with my J2EE/Struts/Oracle application. It is saying I don't have any more Oracle connections available. Even I am closing the result set, statement and connection, I am still running into the problem. When I use the Oracle DBA monitor tool, it shows that I have 10 'inactive' connection but then my app will give the 'no resource available' error. So it looks like somehow it is not reusing those inactive connections. Does Gabage Collection release those connections? Does anyone have this problem before? So I am looking for a better 'tool' to find out why GC doesn't release those connections or if those 10 'inactive' connections are actually available to be re-used. Can someone give me a suggestion on this tool or how to troubleshoot the problem? Thanks Stella - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Tool to diagnose J2EE/Struts/Oracle problem
You can see more documentation about toplink here. www.otn.oracle.com\products\ias\toplink -Original Message- From: Viral_Thakkar [mailto:[EMAIL PROTECTED] Sent: Thursday, September 18, 2003 11:37 AM To: Struts Users Mailing List Subject: RE: Tool to diagnose J2EE/Struts/Oracle problem Hi hari, Could you provide some more info on using the toplink w.r.t to struts, EJB and oracle database. I would like to see few lines of toplink code. Thanks, Viral -Original Message- From: hari_s [mailto:[EMAIL PROTECTED] Sent: Thursday, September 18, 2003 10:06 AM To: 'Struts Users Mailing List' Subject: RE: Tool to diagnose J2EE/Struts/Oracle problem I think you should try toplink from oracle for your connection to database. -Original Message- From: Au-Yeung, Stella H [mailto:[EMAIL PROTECTED] Sent: Thursday, September 18, 2003 9:52 AM To: Struts Users Mailing List Subject: Tool to diagnose J2EE/Struts/Oracle problem I am havng a No resource Available problem with my J2EE/Struts/Oracle application. It is saying I don't have any more Oracle connections available. Even I am closing the result set, statement and connection, I am still running into the problem. When I use the Oracle DBA monitor tool, it shows that I have 10 'inactive' connection but then my app will give the 'no resource available' error. So it looks like somehow it is not reusing those inactive connections. Does Gabage Collection release those connections? Does anyone have this problem before? So I am looking for a better 'tool' to find out why GC doesn't release those connections or if those 10 'inactive' connections are actually available to be re-used. Can someone give me a suggestion on this tool or how to troubleshoot the problem? Thanks Stella - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]