Hi All,
My application uses MyBatis as ORM and SQLFire as database.
<resultMap type="com.ls.ids.account.model.Account" id="accountMap">
<id property="ssiId" column="ssi_id" />
<result property="acid" column="ACID"/>
<association property="relatedConsultants"
column="ssi_id"
select="getRelatedConsultants" />
<resultMap type="com.ls.ids.consultant.model.Consultant" id="consultantMap">
<id property="ssiId" column="ssi_id"/>
<result property="name" column="name"/>
</resultMap>
<select id="getRelatedConsultants" resultMap="consultantMap">
SELECT cons.ssi_id,cons.name FROM w_consultant cons WHERE cons.SSI_ID = #{relatedSsiId}
</select>
<select id="getAccounts" resultMap="accountMap">
SELECT act.ssi_id,act.acid FROM w_account act
</select>
When I run my testProgram for getAccounts(), the log shows its fetching around 1000 records and suddenly fail with below error message
I searched in net for XJ001.U , it says about outOfMemory issue, I increased tomcat memory size upto 2g but still it fails with same error.
Error Trace:
ERROR: com.ls.ids.business.service.AccountBusinessService - getAccounts() - Caught a general exception:
### Error querying database. Cause: java.sql.SQLException: SQLFire error: SQLSTATE=XJ001,SEVERITY=-1,SQLERRMC: (Server=sqlfireprd1.com[1528],Thread[DRDAConnThread_178,5,sqlfire.daemons]) com.vmware.sqlfire.internal.shared.common.sanity.AssertFailure ASSERT FAILED next() called on scan after scan was closed. XJ001.U
### The error may involve defaultParameterMap
### The error occurred while setting parameters
### Cause: java.sql.SQLException: SQLFire error: SQLSTATE=XJ001,SEVERITY=-1,SQLERRMC: (Server=sqlfireprd1.com[1528],Thread[DRDAConnThread_178,5,sqlfire.daemons]) com.vmware.sqlfire.internal.shared.common.sanity.AssertFailure ASSERT FAILED next() called on scan after scan was closed. XJ001.U
; uncategorized SQLException for SQL []; SQL state [XJ001]; error code [-1]; SQLFire error: SQLSTATE=XJ001,SEVERITY=-1,SQLERRMC: (Server=sqlfireprd1.com[1528],Thread[DRDAConnThread_178,5,sqlfire.daemons]) com.vmware.sqlfire.internal.shared.common.sanity.AssertFailure ASSERT FAILED next() called on scan after scan was closed. XJ001.U; nested exception is java.sql.SQLException: SQLFire error: SQLSTATE=XJ001,SEVERITY=-1,SQLERRMC: (Server=sqlfireprd1.com[1528],Thread[DRDAConnThread_178,5,sqlfire.daemons]) com.vmware.sqlfire.internal.shared.common.sanity.AssertFailure ASSERT FAILED next() called on scan after scan was closed. XJ001.U
com.ls.ids.common.exceptions.IdsSystemException: getAccounts() - Caught a general exception:
### Error querying database. Cause: java.sql.SQLException: SQLFire error: SQLSTATE=XJ001,SEVERITY=-1,SQLERRMC: (Server=sqlfireprd1.com[1528],Thread[DRDAConnThread_178,5,sqlfire.daemons]) com.vmware.sqlfire.internal.shared.common.sanity.AssertFailure ASSERT FAILED next() called on scan after scan was closed. XJ001.U
### The error may involve defaultParameterMap
### The error occurred while setting parameters
### Cause: java.sql.SQLException: SQLFire error: SQLSTATE=XJ001,SEVERITY=-1,SQLERRMC: (Server=sqlfireprd1.com[1528],Thread[DRDAConnThread_178,5,sqlfire.daemons]) com.vmware.sqlfire.internal.shared.common.sanity.AssertFailure ASSERT FAILED next() called on scan after scan was closed. XJ001.U
; uncategorized SQLException for SQL []; SQL state [XJ001]; error code [-1]; SQLFire error: SQLSTATE=XJ001,SEVERITY=-1,SQLERRMC: (Server=sqlfireprd1.com[1528],Thread[DRDAConnThread_178,5,sqlfire.daemons]) com.vmware.sqlfire.internal.shared.common.sanity.AssertFailure ASSERT FAILED next() called on scan after scan was closed. XJ001.U; nested exception is java.sql.SQLException: SQLFire error: SQLSTATE=XJ001,SEVERITY=-1,SQLERRMC: (Server=sqlfireprd1.com[1528],Thread[DRDAConnThread_178,5,sqlfire.daemons]) com.vmware.sqlfire.internal.shared.common.sanity.AssertFailure ASSERT FAILED next() called on scan after scan was closed. XJ001.U
at com.ls.ids.business.service.AccountBusinessService.getAccounts(AccountBusinessService.java:781)
at com.ls.ids.account.test.AccountTest.testGetAllAccounts(AccountTest.java:215)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:44)
at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:15)
at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:41)
at org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:20)
at org.junit.internal.runners.statements.RunBefores.evaluate(RunBefores.java:28)
at org.springframework.test.context.junit4.statements.RunBeforeTestMethodCallbacks.evaluate(RunBeforeTestMethodCallbacks.java:74)
at org.springframework.test.context.junit4.statements.RunAfterTestMethodCallbacks.evaluate(RunAfterTestMethodCallbacks.java:83)
at org.springframework.test.context.junit4.statements.SpringRepeat.evaluate(SpringRepeat.java:72)
at org.springframework.test.context.junit4.SpringJUnit4ClassRunner.runChild(SpringJUnit4ClassRunner.java:231)
at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:49)
at org.junit.runners.ParentRunner$3.run(ParentRunner.java:193)
at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:52)
at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:191)
at org.junit.runners.ParentRunner.access$000(ParentRunner.java:42)
at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:184)
at org.springframework.test.context.junit4.statements.RunBeforeTestClassCallbacks.evaluate(RunBeforeTestClassCallbacks.java:61)
at org.springframework.test.context.junit4.statements.RunAfterTestClassCallbacks.evaluate(RunAfterTestClassCallbacks.java:71)
at org.junit.runners.ParentRunner.run(ParentRunner.java:236)
at org.springframework.test.context.junit4.SpringJUnit4ClassRunner.run(SpringJUnit4ClassRunner.java:174)
at org.eclipse.jdt.internal.junit4.runner.JUnit4TestReference.run(JUnit4TestReference.java:50)
at org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:467)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:683)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:390)
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:197)
Caused by: org.springframework.jdbc.UncategorizedSQLException:
### Error querying database. Cause: java.sql.SQLException: SQLFire error: SQLSTATE=XJ001,SEVERITY=-1,SQLERRMC: (Server=sqlfireprd1.com[1528],Thread[DRDAConnThread_178,5,sqlfire.daemons]) com.vmware.sqlfire.internal.shared.common.sanity.AssertFailure ASSERT FAILED next() called on scan after scan was closed. XJ001.U
### The error may involve defaultParameterMap
### The error occurred while setting parameters
### Cause: java.sql.SQLException: SQLFire error: SQLSTATE=XJ001,SEVERITY=-1,SQLERRMC: (Server=sqlfireprd1.com[1528],Thread[DRDAConnThread_178,5,sqlfire.daemons]) com.vmware.sqlfire.internal.shared.common.sanity.AssertFailure ASSERT FAILED next() called on scan after scan was closed. XJ001.U
; uncategorized SQLException for SQL []; SQL state [XJ001]; error code [-1]; SQLFire error: SQLSTATE=XJ001,SEVERITY=-1,SQLERRMC: (Server=sqlfireprd1.com[1528],Thread[DRDAConnThread_178,5,sqlfire.daemons]) com.vmware.sqlfire.internal.shared.common.sanity.AssertFailure ASSERT FAILED next() called on scan after scan was closed. XJ001.U; nested exception is java.sql.SQLException: SQLFire error: SQLSTATE=XJ001,SEVERITY=-1,SQLERRMC: (Server=sqlfireprd1.com[1528],Thread[DRDAConnThread_178,5,sqlfire.daemons]) com.vmware.sqlfire.internal.shared.common.sanity.AssertFailure ASSERT FAILED next() called on scan after scan was closed. XJ001.U
at org.springframework.jdbc.support.AbstractFallbackSQLExceptionTranslator.translate(AbstractFallbackSQLExceptionTranslator.java:83)
at org.springframework.jdbc.support.AbstractFallbackSQLExceptionTranslator.translate(AbstractFallbackSQLExceptionTranslator.java:80)
at org.springframework.jdbc.support.AbstractFallbackSQLExceptionTranslator.translate(AbstractFallbackSQLExceptionTranslator.java:80)
at org.mybatis.spring.MyBatisExceptionTranslator.translateExceptionIfPossible(MyBatisExceptionTranslator.java:71)
at org.mybatis.spring.SqlSessionTemplate$SqlSessionInterceptor.invoke(SqlSessionTemplate.java:346)
at $Proxy14.selectList(Unknown Source)
at org.mybatis.spring.SqlSessionTemplate.selectList(SqlSessionTemplate.java:189)
at org.apache.ibatis.binding.MapperMethod.executeForList(MapperMethod.java:100)
at org.apache.ibatis.binding.MapperMethod.execute(MapperMethod.java:70)
at org.apache.ibatis.binding.MapperProxy.invoke(MapperProxy.java:38)
at $Proxy15.getAccounts(Unknown Source)
at com.ls.ids.business.service.AccountBusinessService.getAccounts(AccountBusinessService.java:718)
Any Help is highly appreciated.
Thanks in advance,
Sidd