PDA

View Full Version : [Mondrian] RE: VirtualCubeTest.testCalculatedMemberAcrossCubesfailing on SMP



Pappyn Bart
01-22-2007, 03:40 AM
Hi John,

I have been busy together with Julian trying to simulate this problem.

However, I cannot reproduce the problem on any of the workstations I am
able to test on. On my pc, a single processor - windows pc, the problem
cannot be simulated. On virtual pc Linux, the problem does not occur.

On a 2-way SMP - windows 2003 machine, the problem does not occur
either.

Everything is tested against derby. Please note that I notice the
problem
also occurs in Julian's nightly tests, but never on mysql, only on derby
and oracle.

Since I cannot simulate the problem, Julian told me he will look into
the matter.

Kind regards,
Bart

-----Original Message-----
From: John V. Sichi [mailto:jsichi (AT) gmail (DOT) com]
Sent: maandag 22 januari 2007 0:56
To: Bart Pappyn
Cc: Pappyn Bart; mondrian (AT) pentaho (DOT) org; mondrian-devel (AT) lists (DOT) sf.net
Subject: VirtualCubeTest.testCalculatedMemberAcrossCubes failing on SMP

Hi Bart,

With your recent changes, I always get the error below when running this
test on a 4-way SMP machine as part of the full "ant test" regression
(using Derby as DB). I cannot reproduce it on my laptop (single CPU),
and I cannot reproduce it if I only run this test by itself in
isolation. If I sync back to change number 8462, the problem is gone.

[java] There was 1 failure:
[java] 1)
testCalculatedMeasureAcrossCubes(mondrian.rolap.VirtualCubeTest)junit.fr
amework.ComparisonFailure:
Expected:
[java] Axis #0:
[java] {}
[java] Axis #1:
[java] {[Measures].[Unit Sales]}
[java] {[Measures].[Units Shipped]}
[java] {[Measures].[Shipped per Ordered]}
[java] {[Measures].[Profit per Unit Shipped]}
[java] Axis #2:
[java] {[Product].[All Products].[Drink], [Time].[1997].[Q1]}
[java] {[Product].[All Products].[Drink], [Time].[1997].[Q2]}
[java] {[Product].[All Products].[Drink], [Time].[1997].[Q3]}
[java] {[Product].[All Products].[Drink], [Time].[1997].[Q4]}
[java] {[Product].[All Products].[Food], [Time].[1997].[Q1]}
[java] {[Product].[All Products].[Food], [Time].[1997].[Q2]}
[java] {[Product].[All Products].[Food], [Time].[1997].[Q3]}
[java] {[Product].[All Products].[Food], [Time].[1997].[Q4]}
[java] {[Product].[All Products].[Non-Consumable],
[Time].[1997].[Q1]}
[java] {[Product].[All Products].[Non-Consumable],
[Time].[1997].[Q2]}
[java] {[Product].[All Products].[Non-Consumable],
[Time].[1997].[Q3]}
[java] {[Product].[All Products].[Non-Consumable],
[Time].[1997].[Q4]}
[java] Row #0: 5,976
[java] Row #0: 4637.0
[java] Row #0: 77.59%
[java] Row #0: $1.50
[java] Row #1: 5,895
[java] Row #1: 4501.0
[java] Row #1: 76.35%
[java] Row #1: $1.60
[java] Row #2: 6,065
[java] Row #2: 6258.0
[java] Row #2: 103.18%
[java] Row #2: $1.15
[java] Row #3: 6,661
[java] Row #3: 5802.0
[java] Row #3: 87.10%
[java] Row #3: $1.38
[java] Row #4: 47,809
[java] Row #4: 37153.0
[java] Row #4: 77.71%
[java] Row #4: $1.64
[java] Row #5: 44,825
[java] Row #5: 35459.0
[java] Row #5: 79.11%
[java] Row #5: $1.62
[java] Row #6: 47,440
[java] Row #6: 41545.0
[java] Row #6: 87.57%
[java] Row #6: $1.47
[java] Row #7: 51,866
[java] Row #7: 34706.0
[java] Row #7: 66.91%
[java] Row #7: $1.91
[java] Row #8: 12,506
[java] Row #8: 9161.0
[java] Row #8: 73.25%
[java] Row #8: $1.76
[java] Row #9: 11,890
[java] Row #9: 9227.0
[java] Row #9: 77.60%
[java] Row #9: $1.65
[java] Row #10: 12,343
[java] Row #10: 9986.0
[java] Row #10: 80.90%
[java] Row #10: $1.59
[java] Row #11: 13,497
[java] Row #11: 9291.0
[java] Row #11: 68.84%
[java] Row #11: $1.86

[java] Actual:
[java] Axis #0:
[java] {}
[java] Axis #1:
[java] {[Measures].[Unit Sales]}
[java] {[Measures].[Units Shipped]}
[java] {[Measures].[Shipped per Ordered]}
[java] {[Measures].[Profit per Unit Shipped]}
[java] Axis #2:
[java] {[Product].[All Products].[Drink], [Time].[1997].[Q1]}
[java] {[Product].[All Products].[Drink], [Time].[1997].[Q2]}
[java] {[Product].[All Products].[Drink], [Time].[1997].[Q3]}
[java] {[Product].[All Products].[Drink], [Time].[1997].[Q4]}
[java] {[Product].[All Products].[Food], [Time].[1997].[Q1]}
[java] {[Product].[All Products].[Food], [Time].[1997].[Q2]}
[java] {[Product].[All Products].[Food], [Time].[1997].[Q3]}
[java] {[Product].[All Products].[Food], [Time].[1997].[Q4]}
[java] {[Product].[All Products].[Non-Consumable],
[Time].[1997].[Q1]}
[java] {[Product].[All Products].[Non-Consumable],
[Time].[1997].[Q2]}
[java] {[Product].[All Products].[Non-Consumable],
[Time].[1997].[Q3]}
[java] {[Product].[All Products].[Non-Consumable],
[Time].[1997].[Q4]}
[java] Row #0: 5,976
[java] Row #0: 4637.0
[java] Row #0: 77.59%
[java] Row #0:
[java] Row #1: 5,895
[java] Row #1: 4501.0
[java] Row #1: 76.35%
[java] Row #1:
[java] Row #2: 6,065
[java] Row #2: 6258.0
[java] Row #2: 103.18%
[java] Row #2:
[java] Row #3: 6,661
[java] Row #3: 5802.0
[java] Row #3: 87.10%
[java] Row #3:
[java] Row #4: 47,809
[java] Row #4: 37153.0
[java] Row #4: 77.71%
[java] Row #4:
[java] Row #5: 44,825
[java] Row #5: 35459.0
[java] Row #5: 79.11%
[java] Row #5:
[java] Row #6: 47,440
[java] Row #6: 41545.0
[java] Row #6: 87.57%
[java] Row #6:
[java] Row #7: 51,866
[java] Row #7: 34706.0
[java] Row #7: 66.91%
[java] Row #7:
[java] Row #8: 12,506
[java] Row #8: 9161.0
[java] Row #8: 73.25%
[java] Row #8:
[java] Row #9: 11,890
[java] Row #9: 9227.0
[java] Row #9: 77.60%
[java] Row #9:
[java] Row #10: 12,343
[java] Row #10: 9986.0
[java] Row #10: 80.90%
[java] Row #10:
[java] Row #11: 13,497
[java] Row #11: 9291.0
[java] Row #11: 68.84%
[java] Row #11:

JVS

______________________________________________________________________
This email has been scanned by the Email Security System.
______________________________________________________________________

_______________________________________________
Mondrian mailing list
Mondrian (AT) pentaho (DOT) org
http://lists.pentaho.org/mailman/listinfo/mondrian

John V. Sichi
01-22-2007, 06:11 AM
Pappyn Bart wrote:
> Hi John,
>
> I have been busy together with Julian trying to simulate this problem.

OK. I looked through the code changes but couldn't spot anything obvious.

While I was reviewing, I did notice one unrelated thing. In your
original code, you were using Thread.getId(), and -1 as an invalid
thread ID. Then you had to change it to System.identityHashCode(thread)
for 1.4-compatibility. However, I don't think there's any guarantee
that identityHashCode can't return -1 (even though it's unlikely given
that most JVM's implement it as a pointer address), so is the following
test in RolapStar.clearCachedAggregations still correct?

if (aggregationKey.getThreadId() == threadId) {
it.remove();
}

JVS
_______________________________________________
Mondrian mailing list
Mondrian (AT) pentaho (DOT) org
http://lists.pentaho.org/mailman/listinfo/mondrian