You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@pig.apache.org by "Koji Noguchi (JIRA)" <ji...@apache.org> on 2012/09/21 20:45:07 UTC

[jira] [Commented] (PIG-2926) TestPoissonSampleLoader failing on rhel environment

    [ https://issues.apache.org/jira/browse/PIG-2926?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13460691#comment-13460691 ] 

Koji Noguchi commented on PIG-2926:
-----------------------------------

I have no understanding of how this loader works, but the difference is coming at 

{noformat}
106             long availRedMem = (long) (Runtime.getRuntime().maxMemory() * heapPerc);
{noformat}

Inside build.xml, test is set up to use -Xmx1024m, however
On my mac, maxMemory() returns 1037959168 whereas on my rhel environemt, it returns 954466304. 

Hardcoding this value in the code would make the test pass.

On my macbook.
$ java -version
java version "1.6.0_33"
Java(TM) SE Runtime Environment (build 1.6.0_33-b03-424-10M3720)
Java HotSpot(TM) 64-Bit Server VM (build 20.8-b03-424, mixed mode)

On rhel node.
> java -version
java version "1.6.0_33"
Java(TM) SE Runtime Environment (build 1.6.0_33-b03)
Java HotSpot(TM) Server VM (build 20.8-b03, mixed mode)
                
> TestPoissonSampleLoader failing on rhel environment
> ---------------------------------------------------
>
>                 Key: PIG-2926
>                 URL: https://issues.apache.org/jira/browse/PIG-2926
>             Project: Pig
>          Issue Type: Bug
>            Reporter: Koji Noguchi
>            Priority: Minor
>
> Testing on rhel environment, TestPoissonSampleLoader fails with 
> {noformat}
> Testcase: testNumSamples took 22.077 sec
>         FAILED
> expected:<47> but was:<42>
> junit.framework.AssertionFailedError: expected:<47> but was:<42>
>         at org.apache.pig.test.TestPoissonSampleLoader.testNumSamples(TestPoissonSampleLoader.java:125)
> {noformat}
> From 
> {noformat}
> 124         count = testNumSamples("0.0001", "100");
> 125         assertEquals(count, 42);
> {noformat}
> This runs fine on my mac environment.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira