lbehnke / h2database

Automatically exported from code.google.com/p/h2database
0 stars 0 forks source link

MVCC: RuntimeException: Unexpected code path in simple SELECT #150

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
(simple SQL scripts or simple standalone applications are preferred)

Happens sometimes with our production database. Only if MVCC=TRUE. Alas, I
yet don't know how to reproduce it with a small test database (still
investigating). We cannot give our production db to you, sorry. It is not
even possible to extract portions of it, because there are many entangled
tables involved.

What is the expected output? What do you see instead?

our *.trace.db file contains the following exception:

/**/PreparedStatement prep308 = conn2.prepareStatement("select
accessauth0_.AccessAuthorisationSetOID as AccessAu5_1_, accessauth0_.O_ID
as O1_1_, accessauth0_.O_ID as O1_4_0_, accessauth0_.hibernate_version as
hibernate3_4_0_, accessauth0_.accessAuthorisationType as accessAu2_4_0_,
accessauth0_.mandator as mandator4_0_,
accessauth0_.AccessAuthorisationSetOID as AccessAu5_4_0_,
accessauth0_.validFrom as validFrom4_0_, accessauth0_.validTo as
validTo4_0_, accessauth0_.specialAuthorisation as specialA8_4_0_,
accessauth0_.accessProfile as accessPr9_4_0_, accessauth0_.accessWeeklyPlan
as accessW10_4_0_, accessauth0_.accessDoorReader as accessD11_4_0_,
accessauth0_.spaceZone as spaceZone4_0_ from ACC_AUTHORISATION accessauth0_
where accessauth0_.AccessAuthorisationSetOID=?");
12-15 11:46:02 jdbc[4]: 
/**/prep308.setLong(1, 101148L);
12-15 11:46:02 jdbc[4]: 
/**/ResultSet rs1227 = prep308.executeQuery();
12-15 11:46:02 jdbc[4]: SQLException
org.h2.jdbc.JdbcSQLException: General error: java.lang.RuntimeException:
Unexpected code path; SQL statement:
select accessauth0_.AccessAuthorisationSetOID as AccessAu5_1_,
accessauth0_.O_ID as O1_1_, accessauth0_.O_ID as O1_4_0_,
accessauth0_.hibernate_version as hibernate3_4_0_,
accessauth0_.accessAuthorisationType as accessAu2_4_0_,
accessauth0_.mandator as mandator4_0_,
accessauth0_.AccessAuthorisationSetOID as AccessAu5_4_0_,
accessauth0_.validFrom as validFrom4_0_, accessauth0_.validTo as
validTo4_0_, accessauth0_.specialAuthorisation as specialA8_4_0_,
accessauth0_.accessProfile as accessPr9_4_0_, accessauth0_.accessWeeklyPlan
as accessW10_4_0_, accessauth0_.accessDoorReader as accessD11_4_0_,
accessauth0_.spaceZone as spaceZone4_0_ from ACC_AUTHORISATION accessauth0_
where accessauth0_.AccessAuthorisationSetOID=? [50000-118]
    at org.h2.message.Message.getSQLException(Message.java:105)
    at org.h2.message.Message.convert(Message.java:274)
    at org.h2.message.Message.convert(Message.java:243)
    at org.h2.command.Command.executeQueryLocal(Command.java:144)
    at org.h2.command.Command.executeQuery(Command.java:123)
    at
org.h2.jdbc.JdbcPreparedStatement.executeQuery(JdbcPreparedStatement.java:98)
    at
com.mchange.v2.c3p0.impl.NewProxyPreparedStatement.executeQuery(NewProxyPrepared
Statement.java:76)
    at org.hibernate.jdbc.AbstractBatcher.getResultSet(AbstractBatcher.java:208)
    at org.hibernate.loader.Loader.getResultSet(Loader.java:1812)
    at org.hibernate.loader.Loader.doQuery(Loader.java:697)
    at
org.hibernate.loader.Loader.doQueryAndInitializeNonLazyCollections(Loader.java:2
59)
    at org.hibernate.loader.Loader.loadCollection(Loader.java:2019)
    at
org.hibernate.loader.collection.CollectionLoader.initialize(CollectionLoader.jav
a:59)
    at
org.hibernate.persister.collection.AbstractCollectionPersister.initialize(Abstra
ctCollectionPersister.java:587)
    at
org.hibernate.event.def.DefaultInitializeCollectionEventListener.onInitializeCol
lection(DefaultInitializeCollectionEventListener.java:83)
    at org.hibernate.impl.SessionImpl.initializeCollection(SessionImpl.java:1744)
    at
org.hibernate.collection.AbstractPersistentCollection.initialize(AbstractPersist
entCollection.java:366)
    at
org.hibernate.collection.AbstractPersistentCollection.read(AbstractPersistentCol
lection.java:108)
    at org.hibernate.collection.PersistentSet.iterator(PersistentSet.java:186)
    at
com.dorma.abraham.webapp.controller.access.authorisations.EditAuthorisations.set
AccessAuthorisationSet(EditAuthorisations.java:420)
    at
com.dorma.abraham.webapp.controller.access.authorisations.EditAuthorisations.doR
efresh(EditAuthorisations.java:533)
[...] 
[more stack trace from JSF EL evaluation omitted]

What version of the product are you using? On what operating system, file
system, and virtual machine?

H2 1.1.118
Windows XP SP 3
NTFS
Sun JRE 1.6.0-16

Do you know a workaround?

No.

How important/urgent is the problem for you?

Very urgent.

In your view, is this a defect or a feature request?

Defect.

Please provide any additional information below.

H2 is running embedded (jdbc:h2:file:<path>/db;MVCC=TRUE). Using Hibernate
3.2.2 with C3P0 connection pool, keeping 3 connections open all the time.

Original issue reported on code.google.com by dmoeb...@gmx.net on 15 Dec 2009 at 4:07

GoogleCodeExporter commented 9 years ago
Could you check in the .trace.db file if there remaining stack trace is there 
and add
it here? The [more stack trace from JSF EL evaluation omitted] is very 
unfortunate.

Original comment by thomas.t...@gmail.com on 15 Dec 2009 at 4:53

GoogleCodeExporter commented 9 years ago
Of course. Sorry for cutting off the exception cause:

org.h2.jdbc.JdbcSQLException: General error: java.lang.RuntimeException: 
Unexpected
code path; SQL statement:
select accessauth0_.AccessAuthorisationSetOID as AccessAu5_1_, 
accessauth0_.O_ID as
O1_1_, accessauth0_.O_ID as O1_4_0_, accessauth0_.hibernate_version as
hibernate3_4_0_, accessauth0_.accessAuthorisationType as accessAu2_4_0_,
accessauth0_.mandator as mandator4_0_, accessauth0_.AccessAuthorisationSetOID as
AccessAu5_4_0_, accessauth0_.validFrom as validFrom4_0_, accessauth0_.validTo as
validTo4_0_, accessauth0_.specialAuthorisation as specialA8_4_0_,
accessauth0_.accessProfile as accessPr9_4_0_, accessauth0_.accessWeeklyPlan as
accessW10_4_0_, accessauth0_.accessDoorReader as accessD11_4_0_,
accessauth0_.spaceZone as spaceZone4_0_ from ACC_AUTHORISATION accessauth0_ 
where
accessauth0_.AccessAuthorisationSetOID=? [50000-118]
    at org.h2.message.Message.getSQLException(Message.java:105)
    at org.h2.message.Message.convert(Message.java:274)
    at org.h2.message.Message.convert(Message.java:243)
    at org.h2.command.Command.executeQueryLocal(Command.java:144)
    at org.h2.command.Command.executeQuery(Command.java:123)
    at org.h2.jdbc.JdbcPreparedStatement.executeQuery(JdbcPreparedStatement.java:98)
    at
com.mchange.v2.c3p0.impl.NewProxyPreparedStatement.executeQuery(NewProxyPrepared
Statement.java:76)
    at org.hibernate.jdbc.AbstractBatcher.getResultSet(AbstractBatcher.java:208)
    at org.hibernate.loader.Loader.getResultSet(Loader.java:1812)
    at org.hibernate.loader.Loader.doQuery(Loader.java:697)
    at org.hibernate.loader.Loader.doQueryAndInitializeNonLazyCollections(Loader.java:259)
    at org.hibernate.loader.Loader.loadCollection(Loader.java:2019)
    at org.hibernate.loader.collection.CollectionLoader.initialize(CollectionLoader.java:59)
    at
org.hibernate.persister.collection.AbstractCollectionPersister.initialize(Abstra
ctCollectionPersister.java:587)
    at
org.hibernate.event.def.DefaultInitializeCollectionEventListener.onInitializeCol
lection(DefaultInitializeCollectionEventListener.java:83)
    at org.hibernate.impl.SessionImpl.initializeCollection(SessionImpl.java:1744)
    at
org.hibernate.collection.AbstractPersistentCollection.initialize(AbstractPersist
entCollection.java:366)
    at
org.hibernate.collection.AbstractPersistentCollection.read(AbstractPersistentCol
lection.java:108)
    at org.hibernate.collection.PersistentSet.iterator(PersistentSet.java:186)
    at
com.dorma.abraham.webapp.controller.access.authorisations.EditAuthorisations.set
AccessAuthorisationSet(EditAuthorisations.java:420)
    at
com.dorma.abraham.webapp.controller.access.authorisations.EditAuthorisations.doR
efresh(EditAuthorisations.java:533)
    at
com.dorma.abraham.webapp.controller.access.authorisations.EditAuthorisations.ref
resh2(EditAuthorisations.java:524)
    at
com.dorma.abraham.webapp.controller.access.authorisations.EditAuthorisations.get
AccProfAuth(EditAuthorisations.java:1231)
    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 javax.el.BeanELResolver.getValue(BeanELResolver.java:62)
    at javax.el.CompositeELResolver.getValue(CompositeELResolver.java:53)
    at
org.apache.myfaces.el.unified.resolver.FacesCompositeELResolver.getValue(FacesCo
mpositeELResolver.java:140)
    at org.apache.el.parser.AstValue.getValue(AstValue.java:118)
    at org.apache.el.ValueExpressionImpl.getValue(ValueExpressionImpl.java:186)
    at org.apache.jasper.el.JspValueExpression.getValue(JspValueExpression.java:101)
    at javax.faces.component.UIData.getValue(UIData.java:1054)
    at
com.dorma.abraham.webapp.jsf.datatable.HtmlDataTable.initializeDataPager(HtmlDat
aTable.java:1084)
    at
com.dorma.abraham.webapp.jsf.datatable.HtmlDataTable.getDataPager(HtmlDataTable.
java:876)
    at
com.dorma.abraham.webapp.jsf.datascroller.AbrahamDataScroller.getPageCount(Abrah
amDataScroller.java:123)
    at
com.dorma.abraham.webapp.jsf.datascroller.AbrahamDataScrollerRenderer.renderScro
ller(AbrahamDataScrollerRenderer.java:68)
    at
com.dorma.abraham.webapp.jsf.datascroller.AbrahamDataScrollerRenderer.encodeEnd(
AbrahamDataScrollerRenderer.java:58)
    at javax.faces.component.UIComponentBase.encodeEnd(UIComponentBase.java:624)
    at
org.apache.myfaces.shared_impl.renderkit.RendererUtils.renderChild(RendererUtils
.java:522)
    at
org.apache.myfaces.shared_impl.renderkit.html.HtmlGridRendererBase.renderChildre
n(HtmlGridRendererBase.java:231)
    at
org.apache.myfaces.shared_impl.renderkit.html.HtmlGridRendererBase.encodeEnd(Htm
lGridRendererBase.java:102)
    at javax.faces.component.UIComponentBase.encodeEnd(UIComponentBase.java:624)
    at
org.apache.myfaces.shared_impl.renderkit.RendererUtils.renderChild(RendererUtils
.java:522)
    at
org.apache.myfaces.shared_impl.renderkit.html.HtmlGridRendererBase.renderChildre
n(HtmlGridRendererBase.java:231)
    at
org.apache.myfaces.shared_impl.renderkit.html.HtmlGridRendererBase.encodeEnd(Htm
lGridRendererBase.java:102)
    at javax.faces.component.UIComponentBase.encodeEnd(UIComponentBase.java:624)
    at
org.apache.myfaces.shared_impl.renderkit.RendererUtils.renderChild(RendererUtils
.java:522)
    at
org.apache.myfaces.shared_impl.renderkit.html.HtmlGridRendererBase.renderChildre
n(HtmlGridRendererBase.java:231)
    at
org.apache.myfaces.shared_impl.renderkit.html.HtmlGridRendererBase.encodeEnd(Htm
lGridRendererBase.java:102)
    at javax.faces.component.UIComponentBase.encodeEnd(UIComponentBase.java:624)
    at
org.apache.myfaces.shared_tomahawk.renderkit.RendererUtils.renderChild(RendererU
tils.java:522)
    at
org.apache.myfaces.shared_tomahawk.renderkit.RendererUtils.renderChildren(Render
erUtils.java:499)
    at
org.apache.myfaces.custom.htmlTag.HtmlTagRenderer.encodeChildren(HtmlTagRenderer
.java:86)
    at javax.faces.component.UIComponentBase.encodeChildren(UIComponentBase.java:611)
    at
org.apache.myfaces.shared_impl.renderkit.RendererUtils.renderChild(RendererUtils
.java:516)
    at
org.apache.myfaces.shared_impl.renderkit.RendererUtils.renderChildren(RendererUt
ils.java:499)
    at
org.apache.myfaces.shared_impl.renderkit.html.HtmlGroupRendererBase.encodeEnd(Ht
mlGroupRendererBase.java:92)
    at javax.faces.component.UIComponentBase.encodeEnd(UIComponentBase.java:624)
    at
org.apache.myfaces.shared_tomahawk.renderkit.RendererUtils.renderChild(RendererU
tils.java:522)
    at
org.apache.myfaces.custom.tabbedpane.HtmlTabbedPaneRenderer.writeTabsContents(Ht
mlTabbedPaneRenderer.java:563)
    at
org.apache.myfaces.custom.tabbedpane.HtmlTabbedPaneRenderer.encodeEnd(HtmlTabbed
PaneRenderer.java:238)
    at javax.faces.component.UIComponentBase.encodeEnd(UIComponentBase.java:624)
    at
org.apache.myfaces.shared_impl.renderkit.RendererUtils.renderChild(RendererUtils
.java:522)
    at
org.apache.myfaces.shared_impl.renderkit.html.HtmlGridRendererBase.renderChildre
n(HtmlGridRendererBase.java:231)
    at
org.apache.myfaces.shared_impl.renderkit.html.HtmlGridRendererBase.encodeEnd(Htm
lGridRendererBase.java:102)
    at javax.faces.component.UIComponentBase.encodeEnd(UIComponentBase.java:624)
    at
org.apache.myfaces.shared_tomahawk.renderkit.RendererUtils.renderChild(RendererU
tils.java:522)
    at
org.apache.myfaces.shared_tomahawk.renderkit.RendererUtils.renderChildren(Render
erUtils.java:499)
    at
org.apache.myfaces.shared_tomahawk.renderkit.RendererUtils.renderChild(RendererU
tils.java:520)
    at
org.apache.myfaces.shared_tomahawk.renderkit.RendererUtils.renderChildren(Render
erUtils.java:499)
    at
org.apache.myfaces.custom.htmlTag.HtmlTagRenderer.encodeChildren(HtmlTagRenderer
.java:86)
    at javax.faces.component.UIComponentBase.encodeChildren(UIComponentBase.java:611)
    at
org.apache.myfaces.shared_impl.renderkit.RendererUtils.renderChild(RendererUtils
.java:516)
    at
org.apache.myfaces.shared_impl.renderkit.html.HtmlGridRendererBase.renderChildre
n(HtmlGridRendererBase.java:231)
    at
org.apache.myfaces.shared_impl.renderkit.html.HtmlGridRendererBase.encodeEnd(Htm
lGridRendererBase.java:102)
    at javax.faces.component.UIComponentBase.encodeEnd(UIComponentBase.java:624)
    at
org.apache.myfaces.shared_impl.renderkit.RendererUtils.renderChild(RendererUtils
.java:522)
    at
org.apache.myfaces.shared_impl.renderkit.RendererUtils.renderChildren(RendererUt
ils.java:499)
    at
org.apache.myfaces.shared_impl.renderkit.RendererUtils.renderChild(RendererUtils
.java:520)
    at
org.apache.myfaces.shared_impl.renderkit.RendererUtils.renderChildren(RendererUt
ils.java:499)
    at
org.apache.myfaces.shared_impl.renderkit.RendererUtils.renderChild(RendererUtils
.java:520)
    at
org.apache.myfaces.shared_impl.renderkit.RendererUtils.renderChildren(RendererUt
ils.java:499)
    at
com.dorma.abraham.webapp.jsf.modemarker.ModeMarkerRenderer.encodeChildren(ModeMa
rkerRenderer.java:69)
    at javax.faces.component.UIComponentBase.encodeChildren(UIComponentBase.java:611)
    at javax.faces.component.UIComponent.encodeAll(UIComponent.java:250)
    at javax.faces.component.UIComponent.encodeAll(UIComponent.java:257)
    at javax.faces.component.UIComponent.encodeAll(UIComponent.java:257)
    at
org.apache.myfaces.tomahawk.application.jsp.JspTilesTwoViewHandlerImpl.actuallyR
enderView(JspTilesTwoViewHandlerImpl.java:478)
    at
org.apache.myfaces.tomahawk.application.jsp.JspTilesTwoViewHandlerImpl.renderTil
esView(JspTilesTwoViewHandlerImpl.java:200)
    at
org.apache.myfaces.tomahawk.application.jsp.JspTilesTwoViewHandlerImpl.renderVie
w(JspTilesTwoViewHandlerImpl.java:135)
    at
org.apache.myfaces.lifecycle.RenderResponseExecutor.execute(RenderResponseExecut
or.java:41)
    at org.apache.myfaces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:140)
    at org.apache.myfaces.custom.ppr.PPRLifecycleWrapper.render(PPRLifecycleWrapper.java:84)
    at javax.faces.webapp.FacesServlet.service(FacesServlet.java:155)
    at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilt
erChain.java:290)
    at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.
java:206)
    at
org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(Characte
rEncodingFilter.java:96)
    at
org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilte
r.java:76)
    at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilt
erChain.java:235)
    at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.
java:206)
    at org.apache.myfaces.webapp.filter.ExtensionsFilter.doFilter(ExtensionsFilter.java:301)
    at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilt
erChain.java:235)
    at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.
java:206)
    at com.dorma.abraham.webapp.filter.ActionFilter.doFilter(ActionFilter.java:98)
    at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilt
erChain.java:235)
    at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.
java:206)
    at
org.springframework.orm.hibernate3.support.OpenSessionInViewFilter.doFilterInter
nal(OpenSessionInViewFilter.java:198)
    at
org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilte
r.java:76)
    at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilt
erChain.java:235)
    at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.
java:206)
    at com.dorma.abraham.common.web.filter.ExceptionFilter.doFilter(ExceptionFilter.java:91)
    at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilt
erChain.java:235)
    at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.
java:206)
    at
org.acegisecurity.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainP
roxy.java:264)
    at
org.acegisecurity.intercept.web.FilterSecurityInterceptor.invoke(FilterSecurityI
nterceptor.java:107)
    at
org.acegisecurity.intercept.web.FilterSecurityInterceptor.doFilter(FilterSecurit
yInterceptor.java:72)
    at
org.acegisecurity.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainP
roxy.java:274)
    at
org.acegisecurity.ui.ExceptionTranslationFilter.doFilter(ExceptionTranslationFil
ter.java:110)
    at
org.acegisecurity.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainP
roxy.java:274)
    at
org.acegisecurity.providers.anonymous.AnonymousProcessingFilter.doFilter(Anonymo
usProcessingFilter.java:125)
    at
org.acegisecurity.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainP
roxy.java:274)
    at
org.acegisecurity.context.HttpSessionContextIntegrationFilter.doFilter(HttpSessi
onContextIntegrationFilter.java:229)
    at
org.acegisecurity.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainP
roxy.java:274)
    at org.acegisecurity.util.FilterChainProxy.doFilter(FilterChainProxy.java:148)
    at org.acegisecurity.util.FilterToBeanProxy.doFilter(FilterToBeanProxy.java:98)
    at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilt
erChain.java:235)
    at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.
java:206)
    at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)
    at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
    at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)
    at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
    at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
    at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:286)
    at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:845)
    at
org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Pr
otocol.java:583)
    at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
    at java.lang.Thread.run(Thread.java:619)
Caused by: java.lang.RuntimeException: Unexpected code path
    at org.h2.message.Message.throwInternalError(Message.java:185)
    at org.h2.message.Message.throwInternalError(Message.java:198)
    at org.h2.index.MultiVersionCursor.next(MultiVersionCursor.java:144)
    at org.h2.index.IndexCursor.next(IndexCursor.java:166)
    at org.h2.table.TableFilter.next(TableFilter.java:273)
    at org.h2.command.dml.Select.queryFlat(Select.java:490)
    at org.h2.command.dml.Select.queryWithoutCache(Select.java:557)
    at org.h2.command.dml.Query.query(Query.java:236)
    at org.h2.command.CommandContainer.query(CommandContainer.java:82)
    at org.h2.command.Command.executeQueryLocal(Command.java:142)
    ... 135 more

Original comment by dmoeb...@gmx.net on 15 Dec 2009 at 5:37

GoogleCodeExporter commented 9 years ago
I think it's a bug, but without reproducible test case it will be 
very hard for me to reproduce and fix it I'm afraid. Could you send
me the result of:

SELECT * FROM INFORMATION_SCHEMA.SETTINGS 

If you can reproduce it, could you try if it's also reproducible
using version 1.2.125 (using the page store)? I know version 1.2
is still beta, but it would help narrow down the root cause.

Original comment by thomas.t...@gmail.com on 17 Dec 2009 at 11:03

GoogleCodeExporter commented 9 years ago
Here's the result of "SELECT * FROM INFORMATION_SCHEMA.SETTINGS".

I managed to reproduce this exception with 1.2.125 once (with page store), and 
the
stack trace was exactly the same. However, I'm not able to reproduce this issue
permanently with either version.

NAME    VALUE
----    -----
CREATE_BUILD    118
CLUSTER ''
DEFAULT_TABLE_TYPE  0
IGNORECASE  1
WRITE_DELAY 500
DEFAULT_LOCK_TIMEOUT    2000
CACHE_SIZE  16384
info.BUILD_ID   118
info.VERSION_MAJOR  1
info.VERSION_MINOR  1
info.VERSION    1.1.118 (2009-09-04)
property.java.runtime.version   1.6.0_16-b01
property.java.vm.name   Java HotSpot(TM) Server VM
property.java.vendor    Sun Microsystems Inc.
property.os.name    Windows XP
property.os.arch    x86
property.os.version 5.1
property.sun.os.patch.level Service Pack 3
property.file.separator \
property.path.separator ;
property.line.separator 
/n
property.user.country   US
property.user.language  en
property.user.variant   
property.file.encoding  Cp1252
EXCLUSIVE   FALSE
MODE    REGULAR
MULTI_THREADED  0
MVCC    TRUE
QUERY_TIMEOUT   0
LOB_FILES_IN_DIRECTORIES    true
h2.allowBigDecimalExtensions    false
h2.baseDir  null
h2.check    true
h2.check2   false
h2.clientTraceDirectory trace.db/
h2.collatorCacheSize    32000
h2.defaultMaxMemoryUndo 50000
h2.lobFilesInDirectories    true
h2.lobFilesPerDirectory 256
h2.logAllErrors false
h2.logAllErrorsFile h2errors.txt
h2.maxFileRetry 16
h2.maxQueryTimeout  0
h2.lobCloseBetweenReads false
h2.objectCache  true
h2.objectCacheSize  1024
h2.objectCacheMaxPerElementSize 4096
h2.optimizeIn   true
h2.optimizeInJoin   true
h2.optimizeInList   false
h2.optimizeMinMax   true
h2.optimizeSubqueryCache    true
h2.overflowExceptions   true
h2.recompileAlways  false
h2.redoBufferSize   262144
h2.runFinalize  true
h2.scriptDirectory  
h2.serverCachedObjects  64
h2.serverResultSetFetchSize 100
h2.sortNullsHigh    false
CACHE_TYPE  LRU
info.FILE_DISK_WRITE    0
info.FILE_DISK_READ 2009
info.FILE_INDEX_WRITE   13
info.FILE_INDEX_READ    731
info.CACHE_DATA_MAX_SIZE    4194304
info.CACHE_DATA_SIZE    248006
info.CACHE_INDEX_MAX_SIZE   524288
info.CACHE_INDEX_SIZE   39520

Original comment by dmoeb...@gmx.net on 17 Dec 2009 at 1:24

GoogleCodeExporter commented 9 years ago
Thanks... Everything looks normal. What database URL do you use?

Could you please append ;TRACE_LEVEL_FILE=3 to the database URL, 
run your application (until you get the problem) and then send 
me the .trace.db file?

Original comment by thomas.t...@gmail.com on 20 Dec 2009 at 11:08

GoogleCodeExporter commented 9 years ago
Ok, here is the .trace.db file that belogs to this issue.

Original comment by trol...@web.de on 22 Dec 2009 at 9:07

Attachments:

GoogleCodeExporter commented 9 years ago
It's possible that this is a follow-up error of issue 158. We tried to delete a
master record that had children attached to it without cascading delete. After 
that
the MVCC index was probably corrupt. A query on the child records (using the 
foreign
key index) didn't retrieve all results. Could it be that because of this 
situation we
ran into line org.h2.index.MultiVersionCursor.next(MultiVersionCursor.java:144) 
?

PS: the database URL is: jdbc:h2:file:C:/dev/temp/h2-matrix-db/matrix;MVCC=TRUE

Original comment by dmoeb...@gmx.net on 25 Jan 2010 at 9:20

GoogleCodeExporter commented 9 years ago
As far as I understand, this is a duplicate of issue 158. Please tell me if I'm 
wrong.

I'm afraid I will not be able to fix it with version 1.1.x (page store 
disabled). I
think it doesn't make sense to keep the issue open because it works with the 
current
release (page store enabled).

Original comment by thomas.t...@gmail.com on 20 Feb 2010 at 9:50