[Mondrian] Hang in mondrian suite under JDK 1.4

Eric McDermid mcdermid at stonecreek.com
Tue Jan 27 19:06:21 EST 2009


Bumping the query limit to 100 seems to have done the trick (a lower  
value might have worked, I just picked a number).

This is a rare case where I can assume the hang wasn't related to my  
code (it occurs on top-of-tree from perforce even if my retroweaver  
changes are backed out).

That said, it looks like our assumption that the upgrade would likely  
be safe was wrong -- mondrian.olap.Util sets a boolean value based on  
a class name which has changed as part of the upgrade.  I'll fix it  
ASAP.

  -- Eric


On Jan 27, 2009, at 2:15 PM, Julian Hyde wrote:

> I've looked into it and it's the high-cardinality dimensions code  
> (again). One of the problems with making iterators look like lists  
> is that there is no obvious place to call 'close' to release  
> resources when something goes wrong.
>
> (John Sichi has made the same observation about our use of  
> java.util.Iterator in the java code generated in Eigenbase's farrago  
> component. But in that case, at least the iterators weren't  
> pretending to be lists.)
>
> Further, the high-cardinality dimension code has an amorphous  
> definition of 'things going wrong', since it uses exceptions like  
> IndexOutOfBoundsException to signal ordinary events.
>
> This code was an architectural mistake, and needs to be removed. Not  
> immediately, but we will stop investing in it.
>
> Eric,
>
> It's likely that the exceptions that are causing the semaphore leak  
> are not bugs in the HCD code itself. My criticism is that the HCD  
> code is that it causes a coding style where error-recovery is error- 
> prone, not that it has errors itself. They may even be bugs in your  
> code. Push up the QueryLimit parameter and see if you can get  
> through the suite and/or find the cause of the bugs.
>
> Julian
>
> From: mondrian-bounces at pentaho.org [mailto:mondrian-bounces at pentaho.org 
> ] On Behalf Of Eric McDermid
> Sent: Tuesday, January 27, 2009 12:12 PM
> To: jhyde at pentaho.com; Mondrian developer mailing list
> Subject: Re: [Mondrian] Hang in mondrian suite under JDK 1.4
>
> As a matter of fact, that's exactly the behavior I've been seeing --  
> both before and after the retroweaver upgrade.
>
> I was just about to send email to the list asking if anyone else had  
> seen the issue, since it is preventing me from validating my  
> Segment.java changes on JDK 1.4.
>
>  -- Eric
>
> On Jan 27, 2009, at 12:57 PM, Julian Hyde wrote:
>
>> I just hit a hang in mondrian's test suite under JDK 1.4 on my  
>> sandbox. Some code is waiting to enter a semaphore - therefore  
>> presumably a lot of semaphores are not being released. I'm guessing  
>> that close() is not being called on SqlStatements, since that is  
>> the only code that uses this semaphore.
>>
>> Or it's a possible bug introduced when Eric upgraded us to  
>> retroweaver 2.07 in change 12289.
>>
>> Or, it could be a bug introduced by code changes in my sandbox.
>>
>> Is anyone else seeing this issue?
>>
>> Julian
>>
>> ------
>> Stack trace:
>>
>> "org.apache.commons.vfs.cache.SoftRefFilesCache 
>> $SoftRefReleaseThread" daemon prio=1 tid=0x0851c8d8 nid=0x2c61 in  
>> Object.wait() [0x9e488000..0x9e4881b8]
>>  at java.lang.Object.wait(Native Method)
>>  at java.lang.ref.ReferenceQueue.remove(ReferenceQueue.java:111)
>>  - locked <0xa12b08d0> (a java.lang.ref.ReferenceQueue$Lock)
>>  at org.apache.commons.vfs.cache.SoftRefFilesCache 
>> $SoftRefReleaseThread.run(SoftRefFilesCache.java:79)
>>
>> "Test thread 0" prio=1 tid=0x084a3bd0 nid=0x2be8 in Object.wait()  
>> [0x9e406000..0x9e4071b8]
>>  at java.lang.Object.wait(Native Method)
>>  - waiting on <0xa1348ca8> (a mondrian.rolap.RolapUtil$Semaphore)
>>  at java.lang.Object.wait(Object.java:429)
>>  at mondrian.rolap.RolapUtil$Semaphore.enter(RolapUtil.java:536)
>>  - locked <0xa1348ca8> (a mondrian.rolap.RolapUtil$Semaphore)
>>  at mondrian.rolap.SqlStatement.execute(SqlStatement.java:91)
>>  at mondrian.rolap.RolapUtil.executeQuery(RolapUtil.java:242)
>>  at mondrian.rolap.RolapUtil.executeQuery(RolapUtil.java:203)
>>  at  
>> mondrian 
>> .rolap.agg.SegmentLoader.createExecuteSql(SegmentLoader.java:340)
>>  at mondrian.rolap.agg.SegmentLoader.load(SegmentLoader.java:75)
>>  at mondrian.rolap.agg.Aggregation.load(Aggregation.java:171)
>>  at  
>> mondrian 
>> .rolap 
>> .agg.AggregationManager.loadAggregation(AggregationManager.java:89)
>>  at mondrian.rolap.FastBatchingCellReader 
>> $Batch.loadAggregation(FastBatchingCellReader.java:493)
>>  at mondrian.rolap.FastBatchingCellReader 
>> $Batch.loadAggregation(FastBatchingCellReader.java:430)
>>  at  
>> mondrian 
>> .rolap 
>> .FastBatchingCellReader.loadAggregation(FastBatchingCellReader.java: 
>> 206)
>>  at  
>> mondrian 
>> .rolap 
>> .FastBatchingCellReader 
>> .loadAggregations(FastBatchingCellReader.java:187)
>>  at mondrian.rolap.RolapResult.executeBody(RolapResult.java:792)
>>  at mondrian.rolap.RolapResult.<init>(RolapResult.java:414)
>>  at mondrian.rolap.RolapConnection.execute(RolapConnection.java:560)
>>  at mondrian.test.TestContext.executeQuery(TestContext.java:474)
>>  at mondrian.test.TestContext.assertQueryReturns(TestContext.java: 
>> 752)
>>  at  
>> mondrian 
>> .test.FoodMartTestCase.assertQueryReturns(FoodMartTestCase.java:122)
>>  at  
>> mondrian 
>> .rolap 
>> .agg 
>> .AggregationOnDistinctCountMeasuresTest 
>> .testCrossJoinMembersWithASingleMember 
>> (AggregationOnDistinctCountMeasuresTest.java:120)
>>  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:324)
>>  at junit.framework.TestCase.runTest(TestCase.java:164)
>>  at junit.framework.TestCase.runBare(TestCase.java:130)
>>  at junit.framework.TestResult$1.protect(TestResult.java:106)
>>  at junit.framework.TestResult.runProtected(TestResult.java:124)
>>  at junit.framework.TestResult.run(TestResult.java:109)
>>  at junit.framework.TestCase.run(TestCase.java:120)
>>  at junit.framework.TestSuite.runTest(TestSuite.java:230)
>>  at junit.framework.TestSuite.run(TestSuite.java:225)
>>  at junit.framework.TestSuite.runTest(TestSuite.java:230)
>>  at junit.framework.TestSuite.run(TestSuite.java:225)
>>  at mondrian.test.MondrianTestRunner$2.run(MondrianTestRunner.java: 
>> 129)
>>  at java.lang.Thread.run(Thread.java:534)
>>
>> "Thread-0" daemon prio=1 tid=0x083317f8 nid=0x2be2 in Object.wait()  
>> [0x9e518000..0x9e5181b8]
>>  at java.lang.Object.wait(Native Method)
>>  - waiting on <0xa1271508> (a java.util.TaskQueue)
>>  at java.util.TimerThread.mainLoop(Timer.java:429)
>>  - locked <0xa1271508> (a java.util.TaskQueue)
>>  at java.util.TimerThread.run(Timer.java:382)
>>
>> "Signal Dispatcher" daemon prio=1 tid=0x080a5200 nid=0x2bdf waiting  
>> on condition [0x00000000..0x00000000]
>>
>> "Finalizer" daemon prio=1 tid=0x0808fbd8 nid=0x2bdd in  
>> Object.wait() [0x9f574000..0x9f5741b8]
>>  at java.lang.Object.wait(Native Method)
>>  - waiting on <0xa0b6dbb0> (a java.lang.ref.ReferenceQueue$Lock)
>>  at java.lang.ref.ReferenceQueue.remove(ReferenceQueue.java:111)
>>  - locked <0xa0b6dbb0> (a java.lang.ref.ReferenceQueue$Lock)
>>  at java.lang.ref.ReferenceQueue.remove(ReferenceQueue.java:127)
>>  at java.lang.ref.Finalizer$FinalizerThread.run(Finalizer.java:159)
>>
>> "Reference Handler" daemon prio=1 tid=0x0808efe8 nid=0x2bdc in  
>> Object.wait() [0x9f5f5000..0x9f5f51b8]
>>  at java.lang.Object.wait(Native Method)
>>  - waiting on <0xa0b6dc18> (a java.lang.ref.Reference$Lock)
>>  at java.lang.Object.wait(Object.java:429)
>>  at java.lang.ref.Reference$ReferenceHandler.run(Reference.java:115)
>>  - locked <0xa0b6dc18> (a java.lang.ref.Reference$Lock)
>>
>> "main" prio=1 tid=0x08058cc0 nid=0x2bd8 in Object.wait()  
>> [0xbfa10000..0xbfa10878]
>>  at java.lang.Object.wait(Native Method)
>>  - waiting on <0xa13cc0e8> (a java.lang.Thread)
>>  at java.lang.Thread.join(Thread.java:1001)
>>  - locked <0xa13cc0e8> (a java.lang.Thread)
>>  at java.lang.Thread.join(Thread.java:1054)
>>  at mondrian.test.MondrianTestRunner.doRun(MondrianTestRunner.java: 
>> 147)
>>  at mondrian.test.Main.run(Main.java:119)
>>  at mondrian.test.Main.runSafe(Main.java:75)
>>  at mondrian.test.Main.main(Main.java:65)
>>
>> "VM Thread" prio=1 tid=0x0808dd70 nid=0x2bdb runnable
>>
>> "VM Periodic Task Thread" prio=1 tid=0x080a7a88 nid=0x2be1 waiting  
>> on condition
>> "Suspend Checker Thread" prio=1 tid=0x080a47a0 nid=0x2bde runnable
>> va.util.TaskQueue)
>>  at java.util.TimerThread.run(Timer.java:382)
>>
>> "Signal Dispatcher" daemon prio=1 tid=0x080a5200 nid=0x2bdf waiting  
>> on condition [0x00000000..0x00000000]
>>
>> "Finalizer" daemon prio=1 tid=0x0808fbd8 nid=0x2bdd in  
>> Object.wait() [0x9f574000..0x9f5741b8]
>>  at java.lang.Object.wait(Native Method)
>>  - waiting on <0xa0b6dbb0> (a java.lang.ref.ReferenceQueue$Lock)
>>  at java.lang.ref.ReferenceQueue.remove(ReferenceQueue.java:111)
>>  - locked <0xa0b6dbb0> (a java.lang.ref.ReferenceQueue$Lock)
>>  at java.lang.ref.ReferenceQueue.remove(ReferenceQueue.java:127)
>>  at java.lang.ref.Finalizer$FinalizerThread.run(Finalizer.java:159)
>>
>> "Reference Handler" daemon prio=1 tid=0x0808efe8 nid=0x2bdc in  
>> Object.wait() [0x9f5f5000..0x9f5f51b8]
>>  at java.lang.Object.wait(Native Method)
>>  - waiting on <0xa0b6dc18> (a java.lang.ref.Reference$Lock)
>>  at java.lang.Object.wait(Object.java:429)
>>  at java.lang.ref.Reference$ReferenceHandler.run(Reference.java:115)
>>  - locked <0xa0b6dc18> (a java.lang.ref.Reference$Lock)
>>
>> "main" prio=1 tid=0x08058cc0 nid=0x2bd8 in Object.wait()  
>> [0xbfa10000..0xbfa10878]
>>  at java.lang.Object.wait(Native Method)
>>  - waiting on <0xa13cc0e8> (a java.lang.Thread)
>>  at java.lang.Thread.join(Thread.java:1001)
>>  - locked <0xa13cc0e8> (a java.lang.Thread)
>>  at java.lang.Thread.join(Thread.java:1054)
>>  at mondrian.test.MondrianTestRunner.doRun(MondrianTestRunner.java: 
>> 147)
>>  at mondrian.test.Main.run(Main.java:119)
>>  at mondrian.test.Main.runSafe(Main.java:75)
>>  at mondrian.test.Main.main(Main.java:65)
>>
>> "VM Thread" prio=1 tid=0x0808dd70 nid=0x2bdb runnable
>>
>> "VM Periodic Task Thread" prio=1 tid=0x080a7a88 nid=0x2be1 waiting  
>> on condition
>> "Suspend Checker Thread" prio=1 tid=0x080a47a0 nid=0x2bde runnable
>> _______________________________________________
>> Mondrian mailing list
>> Mondrian at pentaho.org
>> http://lists.pentaho.org/mailman/listinfo/mondrian
>
> _______________________________________________
> Mondrian mailing list
> Mondrian at pentaho.org
> http://lists.pentaho.org/mailman/listinfo/mondrian

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.pentaho.org/pipermail/mondrian/attachments/20090127/a2d5e177/attachment.html 


More information about the Mondrian mailing list