Re: Issue with Ibatis in Websphere
Hi Thanks, for now i have changed my code as Jeff suggested and testing it, still now not seen any major issues, and hope it continues that way. Ashish On 12/19/06, Clinton Begin [EMAIL PROTECTED] wrote: Exactly. This interface isn't perfect either though...I have better ideas. It's fine until you need transactions, then you have to nest try/finally blocks for the session and transaction. Session never did work out how I expected in iBATIS, and really it's just a higher level abstraction for a transaction. So I'd like to see: client.startTransaction(myConnection) implemented that basically does the same thing. But until then, it's how Jeff said. cheers, Clinton On 12/18/06, Jeff Butler [EMAIL PROTECTED] wrote: SqlMapSession session = sqlMapClient.openSession(conn); try { session.queryForList(getItemFormat,myname); } finally { session.close (); } Jeff Butler On 12/18/06, Ashish Kulkarni [EMAIL PROTECTED] wrote: Hi How do i replace my existing code with sqlMapClient.openSession(myConnection); My excisting code is as below client.setUserConnection(conn); client.queryForList(getItemFormat,myname ); Regards Ashish On 12/18/06, Clinton Begin [EMAIL PROTECTED] wrote: GACK.. setUserConnection() is another API we should deprecate. A cleaner way to do it is: SqlMapSession session = sqlMapClient.openSession(myConnection); try { //do work. } finally { session.close (); } Cheers, Clinton On 12/18/06, Jeff Butler [EMAIL PROTECTED] wrote: This is very similar to this issue: http://issues.apache.org/jira/browse/IBATIS-66 Make sure you're calling client.setUserConnection(null) after processing each query. Jeff Butler On 12/18/06, Ashish Kulkarni [EMAIL PROTECTED] wrote: Hi I have attached the sqlmap and xml file with all the sql statements along this mail. On 12/18/06, Larry Meadors [EMAIL PROTECTED] wrote: Can you post your configuration (database and sqlmap)? Larry On 12/18/06, Ashish Kulkarni [EMAIL PROTECTED] wrote: Hi We have a web application running in websphere, and for a while we are seeing some hung threads in websphere, do we did some java dump as insturcted by IBM and we are seeing some of the following messages in the dump. In our java program before calling SQL statemenet we do the following SqlMapClient client =// get connection client from servlet context client.setUserConnection(conn); // do furthr processing of calling SQL statements. I am not sure if this is the issue, but this is the messsage in the dump com.ibatis.common.util.Throttle.increment seems to be currently executing on 11 servlet threads. Since 100% (11 out of 11) of the threads doing servlet work seem to be executing this method, it would seem that there is some possibility that this method and its call path may warrant investigation. Servlets affected: com.pfizer.maps.servlet.MapsBaseServlet [11 occurrances] Callers (servlet threads only): com.ibm.ws.util.ThreadPool$Worker.run [5] com.pfizer.maps.data.planning.GetPlanningData.getTotalData [2] com.pfizer.maps.data.planning.GetProductionData.getTotalData [2] com.ibm.ws.webcontainer.srp.ServletRequestProcessor.dispatchByURI [1] com.ibm.ws.webcontainer.servlet.ServicingServletState.service [1] This is ibaits version Implementation-Title: iBatis sql map Implementation-Version: 2.1.5 build# 582 Can anyone explain what this is, and how can we fix this Ashish
Re: Issue with Ibatis in Websphere
Exactly. This interface isn't perfect either though...I have better ideas. It's fine until you need transactions, then you have to nest try/finally blocks for the session and transaction. Session never did work out how I expected in iBATIS, and really it's just a higher level abstraction for a transaction. So I'd like to see: client.startTransaction(myConnection) implemented that basically does the same thing. But until then, it's how Jeff said. cheers, Clinton On 12/18/06, Jeff Butler [EMAIL PROTECTED] wrote: SqlMapSession session = sqlMapClient.openSession(conn); try { session.queryForList(getItemFormat,myname); } finally { session.close (); } Jeff Butler On 12/18/06, Ashish Kulkarni [EMAIL PROTECTED] wrote: Hi How do i replace my existing code with sqlMapClient.openSession(myConnection); My excisting code is as below client.setUserConnection(conn); client.queryForList(getItemFormat,myname ); Regards Ashish On 12/18/06, Clinton Begin [EMAIL PROTECTED] wrote: GACK.. setUserConnection() is another API we should deprecate. A cleaner way to do it is: SqlMapSession session = sqlMapClient.openSession(myConnection); try { //do work. } finally { session.close (); } Cheers, Clinton On 12/18/06, Jeff Butler [EMAIL PROTECTED] wrote: This is very similar to this issue: http://issues.apache.org/jira/browse/IBATIS-66 Make sure you're calling client.setUserConnection(null) after processing each query. Jeff Butler On 12/18/06, Ashish Kulkarni [EMAIL PROTECTED] wrote: Hi I have attached the sqlmap and xml file with all the sql statements along this mail. On 12/18/06, Larry Meadors [EMAIL PROTECTED] wrote: Can you post your configuration (database and sqlmap)? Larry On 12/18/06, Ashish Kulkarni [EMAIL PROTECTED] wrote: Hi We have a web application running in websphere, and for a while we are seeing some hung threads in websphere, do we did some java dump as insturcted by IBM and we are seeing some of the following messages in the dump. In our java program before calling SQL statemenet we do the following SqlMapClient client =// get connection client from servlet context client.setUserConnection(conn); // do furthr processing of calling SQL statements. I am not sure if this is the issue, but this is the messsage in the dump com.ibatis.common.util.Throttle.increment seems to be currently executing on 11 servlet threads. Since 100% (11 out of 11) of the threads doing servlet work seem to be executing this method, it would seem that there is some possibility that this method and its call path may warrant investigation. Servlets affected: com.pfizer.maps.servlet.MapsBaseServlet [11 occurrances] Callers (servlet threads only): com.ibm.ws.util.ThreadPool$Worker.run [5] com.pfizer.maps.data.planning.GetPlanningData.getTotalData [2] com.pfizer.maps.data.planning.GetProductionData.getTotalData [2] com.ibm.ws.webcontainer.srp.ServletRequestProcessor.dispatchByURI [1] com.ibm.ws.webcontainer.servlet.ServicingServletState.service [1] This is ibaits version Implementation-Title: iBatis sql map Implementation-Version: 2.1.5 build# 582 Can anyone explain what this is, and how can we fix this Ashish
Re: Issue with Ibatis in Websphere
Can you post your configuration (database and sqlmap)? Larry On 12/18/06, Ashish Kulkarni [EMAIL PROTECTED] wrote: Hi We have a web application running in websphere, and for a while we are seeing some hung threads in websphere, do we did some java dump as insturcted by IBM and we are seeing some of the following messages in the dump. In our java program before calling SQL statemenet we do the following SqlMapClient client =// get connection client from servlet context client.setUserConnection(conn); // do furthr processing of calling SQL statements. I am not sure if this is the issue, but this is the messsage in the dump com.ibatis.common.util.Throttle.increment seems to be currently executing on 11 servlet threads. Since 100% (11 out of 11) of the threads doing servlet work seem to be executing this method, it would seem that there is some possibility that this method and its call path may warrant investigation. Servlets affected: com.pfizer.maps.servlet.MapsBaseServlet [11 occurrances] Callers (servlet threads only): com.ibm.ws.util.ThreadPool$Worker.run [5] com.pfizer.maps.data.planning.GetPlanningData.getTotalData [2] com.pfizer.maps.data.planning.GetProductionData.getTotalData [2] com.ibm.ws.webcontainer.srp.ServletRequestProcessor.dispatchByURI [1] com.ibm.ws.webcontainer.servlet.ServicingServletState.service [1] This is ibaits version Implementation-Title: iBatis sql map Implementation-Version: 2.1.5 build# 582 Can anyone explain what this is, and how can we fix this Ashish
Re: Issue with Ibatis in Websphere
Hi I have attached the sqlmap and xml file with all the sql statements along this mail. On 12/18/06, Larry Meadors [EMAIL PROTECTED] wrote: Can you post your configuration (database and sqlmap)? Larry On 12/18/06, Ashish Kulkarni [EMAIL PROTECTED] wrote: Hi We have a web application running in websphere, and for a while we are seeing some hung threads in websphere, do we did some java dump as insturcted by IBM and we are seeing some of the following messages in the dump. In our java program before calling SQL statemenet we do the following SqlMapClient client =// get connection client from servlet context client.setUserConnection(conn); // do furthr processing of calling SQL statements. I am not sure if this is the issue, but this is the messsage in the dump com.ibatis.common.util.Throttle.increment seems to be currently executing on 11 servlet threads. Since 100% (11 out of 11) of the threads doing servlet work seem to be executing this method, it would seem that there is some possibility that this method and its call path may warrant investigation. Servlets affected: com.pfizer.maps.servlet.MapsBaseServlet [11 occurrances] Callers (servlet threads only): com.ibm.ws.util.ThreadPool$Worker.run [5] com.pfizer.maps.data.planning.GetPlanningData.getTotalData [2] com.pfizer.maps.data.planning.GetProductionData.getTotalData [2] com.ibm.ws.webcontainer.srp.ServletRequestProcessor.dispatchByURI [1] com.ibm.ws.webcontainer.servlet.ServicingServletState.service [1] This is ibaits version Implementation-Title: iBatis sql map Implementation-Version: 2.1.5 build# 582 Can anyone explain what this is, and how can we fix this Ashish ?xml version=1.0 encoding=UTF-8 standalone=no? !DOCTYPE sqlMapConfig PUBLIC -//iBATIS.com//DTD SQL Map Config 2.0//EN http://www.ibatis.com/dtd/sql-map-config-2.dtd; sqlMapConfig settings cacheModelsEnabled=true enhancementEnabled=true maxSessions=64 maxTransactions=8 maxRequests=128/ sqlMap resource=com/pfizer/maps/data/sqlmap/sql/Scheduling.xml/ !-- sqlMap resource=com/pfizer/maps/data/sqlmap/sql/sop.xml/-- /sqlMapConfig ?xml version=1.0 encoding=UTF-8 standalone=no? !DOCTYPE sqlMap PUBLIC -//iBATIS.com//DTD SQL Map 2.0//EN http://www.ibatis.com/dtd/sql-map-2.dtd; !-- The SQL in these maps files has purposely been typed with more verbosity than is actually required. For example, many of the selects could have just used SELECT * FROM... instead of listing all of the columns. This is to demonstrate that even complex SQL can be handled and coded and formatted the way SQL was meant to be (i.e. not a bunch of concatenated strings in a Java class). -- sqlMap namespace=Scheduling select id=selectSchedulablePhases resultClass=java.lang.String parameterClass=java.lang.String select distinct a.l098phnu from pl1098 a, pl1083 c where a.l098llco in (select Min(b.l098llco) from pl1098 b, pl1083 d where d.l083code = #value# and d.l083line = b.l098plin ) and c.l083line = a.l098plin and c.l083code = #value# /select select id=getAllFormats resultClass=com.pfizer.maps.planning.common.data.ColorCodeClass Select L081code as name, L081desc as descrption from pl1081 order by L081code /select select id=getItemFormat resultClass=com.pfizer.maps.planning.common.data.ItemFormatMap parameterClass=java.lang.String select distinct L078Item, L078Atr1, L078Atr2 , L081DESC as format1Desc from Pl1062, Pl1078, PL1081 where l062item = L078item and l062scen =#value# and (L078Atr1 ![CDATA[]] ' ' or L078Atr2 ![CDATA[]] ' ') and L078Atr1 = L081CODE /select select id=getItemFormatByView resultClass=com.pfizer.maps.planning.common.data.ItemFormatMap parameterClass=java.lang.String SELECT distinct l078item, L078ATR1, L078ATR2, L078ATR3, L081DESC as format1Desc FROM wp1004c, PL1078 , PL1083, PL1081 WHERE w4ccode = L078item and L083LINE = W4CLINE and L083CODE = #value# and (L078Atr1 ![CDATA[]] ' ' or L078Atr2 ![CDATA[]] ' ') and L078Atr1 = L081CODE /select select id=selectAllView resultClass=com.pfizer.maps.file.planning.PL1082 select L082CODE, L082DESC from PL1082 /select select id=selectGotoView resultClass=com.pfizer.maps.file.planning.PL1082 select L082CODE, L082DESC from PL1082 where L082CODE = #value# /select select id=selectPhaseNumber resultClass=com.pfizer.maps.planning.common.data.ColorCodeClass SELECT DISTINCT L062PHNU as name, R871DESC as descrption FROM pl1062, rs1871 WHERE L062SCEN= #value# and L062PLIN ![CDATA[]] ' ' and L062PHNU = R871CODE ORDER BY L062PHNU /select select id=selectPhaseNumberView resultClass=com.pfizer.maps.planning.common.data.ColorCodeClass SELECT DISTINCT W4CPHNO as name, R871DESC as descrption FROM wp1004c, PL1083, RS1871 where L083LINE =W4CLINE and
Re: Issue with Ibatis in Websphere
This is very similar to this issue: http://issues.apache.org/jira/browse/IBATIS-66 Make sure you're calling client.setUserConnection(null) after processing each query. Jeff Butler On 12/18/06, Ashish Kulkarni [EMAIL PROTECTED] wrote: Hi I have attached the sqlmap and xml file with all the sql statements along this mail. On 12/18/06, Larry Meadors [EMAIL PROTECTED] wrote: Can you post your configuration (database and sqlmap)? Larry On 12/18/06, Ashish Kulkarni [EMAIL PROTECTED] wrote: Hi We have a web application running in websphere, and for a while we are seeing some hung threads in websphere, do we did some java dump as insturcted by IBM and we are seeing some of the following messages in the dump. In our java program before calling SQL statemenet we do the following SqlMapClient client =// get connection client from servlet context client.setUserConnection(conn); // do furthr processing of calling SQL statements. I am not sure if this is the issue, but this is the messsage in the dump com.ibatis.common.util.Throttle.increment seems to be currently executing on 11 servlet threads. Since 100% (11 out of 11) of the threads doing servlet work seem to be executing this method, it would seem that there is some possibility that this method and its call path may warrant investigation. Servlets affected: com.pfizer.maps.servlet.MapsBaseServlet [11 occurrances] Callers (servlet threads only): com.ibm.ws.util.ThreadPool$Worker.run [5] com.pfizer.maps.data.planning.GetPlanningData.getTotalData [2] com.pfizer.maps.data.planning.GetProductionData.getTotalData [2] com.ibm.ws.webcontainer.srp.ServletRequestProcessor.dispatchByURI [1] com.ibm.ws.webcontainer.servlet.ServicingServletState.service [1] This is ibaits version Implementation-Title: iBatis sql map Implementation-Version: 2.1.5 build# 582 Can anyone explain what this is, and how can we fix this Ashish
Re: Issue with Ibatis in Websphere
GACK.. setUserConnection() is another API we should deprecate. A cleaner way to do it is: SqlMapSession session = sqlMapClient.openSession(myConnection); try { //do work. } finally { session.close(); } Cheers, Clinton On 12/18/06, Jeff Butler [EMAIL PROTECTED] wrote: This is very similar to this issue: http://issues.apache.org/jira/browse/IBATIS-66 Make sure you're calling client.setUserConnection(null) after processing each query. Jeff Butler On 12/18/06, Ashish Kulkarni [EMAIL PROTECTED] wrote: Hi I have attached the sqlmap and xml file with all the sql statements along this mail. On 12/18/06, Larry Meadors [EMAIL PROTECTED] wrote: Can you post your configuration (database and sqlmap)? Larry On 12/18/06, Ashish Kulkarni [EMAIL PROTECTED] wrote: Hi We have a web application running in websphere, and for a while we are seeing some hung threads in websphere, do we did some java dump as insturcted by IBM and we are seeing some of the following messages in the dump. In our java program before calling SQL statemenet we do the following SqlMapClient client =// get connection client from servlet context client.setUserConnection(conn); // do furthr processing of calling SQL statements. I am not sure if this is the issue, but this is the messsage in the dump com.ibatis.common.util.Throttle.increment seems to be currently executing on 11 servlet threads. Since 100% (11 out of 11) of the threads doing servlet work seem to be executing this method, it would seem that there is some possibility that this method and its call path may warrant investigation. Servlets affected: com.pfizer.maps.servlet.MapsBaseServlet [11 occurrances] Callers (servlet threads only): com.ibm.ws.util.ThreadPool$Worker.run [5] com.pfizer.maps.data.planning.GetPlanningData.getTotalData [2] com.pfizer.maps.data.planning.GetProductionData.getTotalData [2] com.ibm.ws.webcontainer.srp.ServletRequestProcessor.dispatchByURI [1] com.ibm.ws.webcontainer.servlet.ServicingServletState.service [1] This is ibaits version Implementation-Title: iBatis sql map Implementation-Version: 2.1.5 build# 582 Can anyone explain what this is, and how can we fix this Ashish
Re: Issue with Ibatis in Websphere
Hi How do i replace my existing code with sqlMapClient.openSession(myConnection); My excisting code is as below client.setUserConnection(conn); client.queryForList(getItemFormat,myname ); Regards Ashish On 12/18/06, Clinton Begin [EMAIL PROTECTED] wrote: GACK.. setUserConnection() is another API we should deprecate. A cleaner way to do it is: SqlMapSession session = sqlMapClient.openSession(myConnection); try { //do work. } finally { session.close (); } Cheers, Clinton On 12/18/06, Jeff Butler [EMAIL PROTECTED] wrote: This is very similar to this issue: http://issues.apache.org/jira/browse/IBATIS-66 Make sure you're calling client.setUserConnection(null) after processing each query. Jeff Butler On 12/18/06, Ashish Kulkarni [EMAIL PROTECTED] wrote: Hi I have attached the sqlmap and xml file with all the sql statements along this mail. On 12/18/06, Larry Meadors [EMAIL PROTECTED] wrote: Can you post your configuration (database and sqlmap)? Larry On 12/18/06, Ashish Kulkarni [EMAIL PROTECTED] wrote: Hi We have a web application running in websphere, and for a while we are seeing some hung threads in websphere, do we did some java dump as insturcted by IBM and we are seeing some of the following messages in the dump. In our java program before calling SQL statemenet we do the following SqlMapClient client =// get connection client from servlet context client.setUserConnection(conn); // do furthr processing of calling SQL statements. I am not sure if this is the issue, but this is the messsage in the dump com.ibatis.common.util.Throttle.increment seems to be currently executing on 11 servlet threads. Since 100% (11 out of 11) of the threads doing servlet work seem to be executing this method, it would seem that there is some possibility that this method and its call path may warrant investigation. Servlets affected: com.pfizer.maps.servlet.MapsBaseServlet [11 occurrances] Callers (servlet threads only): com.ibm.ws.util.ThreadPool$Worker.run [5] com.pfizer.maps.data.planning.GetPlanningData.getTotalData [2] com.pfizer.maps.data.planning.GetProductionData.getTotalData [2] com.ibm.ws.webcontainer.srp.ServletRequestProcessor.dispatchByURI [1] com.ibm.ws.webcontainer.servlet.ServicingServletState.service [1] This is ibaits version Implementation-Title: iBatis sql map Implementation-Version: 2.1.5 build# 582 Can anyone explain what this is, and how can we fix this Ashish
Re: Issue with Ibatis in Websphere
SqlMapSession session = sqlMapClient.openSession(conn); try { session.queryForList(getItemFormat,myname); } finally { session.close (); } Jeff Butler On 12/18/06, Ashish Kulkarni [EMAIL PROTECTED] wrote: Hi How do i replace my existing code with sqlMapClient.openSession(myConnection); My excisting code is as below client.setUserConnection(conn); client.queryForList(getItemFormat,myname ); Regards Ashish On 12/18/06, Clinton Begin [EMAIL PROTECTED] wrote: GACK.. setUserConnection() is another API we should deprecate. A cleaner way to do it is: SqlMapSession session = sqlMapClient.openSession(myConnection); try { //do work. } finally { session.close (); } Cheers, Clinton On 12/18/06, Jeff Butler [EMAIL PROTECTED] wrote: This is very similar to this issue: http://issues.apache.org/jira/browse/IBATIS-66 Make sure you're calling client.setUserConnection(null) after processing each query. Jeff Butler On 12/18/06, Ashish Kulkarni [EMAIL PROTECTED] wrote: Hi I have attached the sqlmap and xml file with all the sql statements along this mail. On 12/18/06, Larry Meadors [EMAIL PROTECTED] wrote: Can you post your configuration (database and sqlmap)? Larry On 12/18/06, Ashish Kulkarni [EMAIL PROTECTED] wrote: Hi We have a web application running in websphere, and for a while we are seeing some hung threads in websphere, do we did some java dump as insturcted by IBM and we are seeing some of the following messages in the dump. In our java program before calling SQL statemenet we do the following SqlMapClient client =// get connection client from servlet context client.setUserConnection(conn); // do furthr processing of calling SQL statements. I am not sure if this is the issue, but this is the messsage in the dump com.ibatis.common.util.Throttle.increment seems to be currently executing on 11 servlet threads. Since 100% (11 out of 11) of the threads doing servlet work seem to be executing this method, it would seem that there is some possibility that this method and its call path may warrant investigation. Servlets affected: com.pfizer.maps.servlet.MapsBaseServlet [11 occurrances] Callers (servlet threads only): com.ibm.ws.util.ThreadPool$Worker.run [5] com.pfizer.maps.data.planning.GetPlanningData.getTotalData [2] com.pfizer.maps.data.planning.GetProductionData.getTotalData [2] com.ibm.ws.webcontainer.srp.ServletRequestProcessor.dispatchByURI [1] com.ibm.ws.webcontainer.servlet.ServicingServletState.service [1] This is ibaits version Implementation-Title: iBatis sql map Implementation-Version: 2.1.5 build# 582 Can anyone explain what this is, and how can we fix this Ashish