unofficial mirror of bug-guix@gnu.org 
 help / color / mirror / code / Atom feed
* bug#46780: java-snappy: Test failure on ci.guix.gnu.org
@ 2021-02-25 20:52 Björn Höfling
  2021-02-26 22:08 ` zimoun
  0 siblings, 1 reply; 5+ messages in thread
From: Björn Höfling @ 2021-02-25 20:52 UTC (permalink / raw)
  To: 46780

[-- Attachment #1: Type: text/plain, Size: 1870 bytes --]

java-snappy fails as a dependency of several Java evaluations, for
example:

http://ci.guix.gnu.org/eval/120281?status=failed
http://ci.guix.gnu.org/build/359649/log/raw

These failures exist only on ci.guix.gnu.org, but locally it build
perfectly, even with --rounds=100!

Why? Because our buildmachine has too much memory :-) [And I can
remember, we once had that for another package, I just can't remember
again which one].

What should we do about it? Just disable the test, or something more
complicated?

Analysis:

To analyze, I let it once fail with the -K switch to have the directory

/tmp/guix-build-java-snappy-1.1.7.drv-0/

available. Enter the environment with

$ guix environment java-snappy
$ cd /tmp/guix-build-java-snappy-1.1.7.drv-0/
$ source ./environment-variables
$ cd source
$ ant check
--> everything is fine.  

Then increase the memory used by junit: Edit the build.xml file, add a
huge "maxmemory" property like this :

<junit maxmemory="30G" printsummary="true" ...

Either have enough RAM or add some extra swap space, then run again:

$ ant check

It fails. The junit logs can be found in

src/test/test-reports/TEST-org.xerial.snappy.pool.CachingBufferPoolTest.txt

Testsuite: org.xerial.snappy.pool.CachingBufferPoolTest
Tests run: 4, Failures: 1, Errors: 0, Skipped: 0, Time elapsed: 7.363 sec

Testcase: testDirectByteBuffers took 0.002 sec
Testcase: testSoftReferences took 7.353 sec
        FAILED
count: 2048
junit.framework.AssertionFailedError: count: 2048
        at org.xerial.snappy.pool.CachingBufferPoolTest.testSoftReferences(Unknown
Source)

Testcase: testArrays took 0 sec
Testcase: testAdjustSize took 0 sec

If you look at the test case source code, it tries to allocate about
20GB and hopes that this fails. It just does not fail on huge machines...

Björn

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 195 bytes --]

^ permalink raw reply	[flat|nested] 5+ messages in thread

* bug#46780: java-snappy: Test failure on ci.guix.gnu.org
  2021-02-25 20:52 bug#46780: java-snappy: Test failure on ci.guix.gnu.org Björn Höfling
@ 2021-02-26 22:08 ` zimoun
  2021-02-27 13:58   ` Björn Höfling
  0 siblings, 1 reply; 5+ messages in thread
From: zimoun @ 2021-02-26 22:08 UTC (permalink / raw)
  To: Björn Höfling, 46780

Hi,

On Thu, 25 Feb 2021 at 21:52, Björn Höfling <bjoern.hoefling@bjoernhoefling.de> wrote:

> Then increase the memory used by junit: Edit the build.xml file, add a
> huge "maxmemory" property like this :
>
> <junit maxmemory="30G" printsummary="true" ...

[...]

> If you look at the test case source code, it tries to allocate about
> 20GB and hopes that this fails. It just does not fail on huge machines...

What about adding a phase just before the test?  For example in this
build.xml file fix the max memory to 20G if it is greater.


All the best,
simon




^ permalink raw reply	[flat|nested] 5+ messages in thread

* bug#46780: java-snappy: Test failure on ci.guix.gnu.org
  2021-02-26 22:08 ` zimoun
@ 2021-02-27 13:58   ` Björn Höfling
  2021-02-27 23:29     ` Björn Höfling
  0 siblings, 1 reply; 5+ messages in thread
From: Björn Höfling @ 2021-02-27 13:58 UTC (permalink / raw)
  To: zimoun; +Cc: 46780

[-- Attachment #1: Type: text/plain, Size: 1247 bytes --]

On Fri, 26 Feb 2021 23:08:42 +0100
zimoun <zimon.toutoune@gmail.com> wrote:

> Hi,
> 
> On Thu, 25 Feb 2021 at 21:52, Björn Höfling
> <bjoern.hoefling@bjoernhoefling.de> wrote:
> 
> > Then increase the memory used by junit: Edit the build.xml file,
> > add a huge "maxmemory" property like this :
> >
> > <junit maxmemory="30G" printsummary="true" ...  
> 
> [...]
> 
> > If you look at the test case source code, it tries to allocate about
> > 20GB and hopes that this fails. It just does not fail on huge
> > machines...  
> 
> What about adding a phase just before the test?  For example in this
> build.xml file fix the max memory to 20G if it is greater.

The build.xml is auto-generated by our ant-build-system. So we could
add some parameter into it. But I found this too much of an overkill,
and working on the ant-build-system would mean this goes into staging
(we have too many Java package).

Thus, at first I thought the idea with the additional phase wouldn't
fit here. But at the second glimpse: The build.xml file definitely
already exists before running the tests (even before build). So we
could add a phase that substitutestars and adds the maxmemory parameter
in the build.xml.

Björn




[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 195 bytes --]

^ permalink raw reply	[flat|nested] 5+ messages in thread

* bug#46780: java-snappy: Test failure on ci.guix.gnu.org
  2021-02-27 13:58   ` Björn Höfling
@ 2021-02-27 23:29     ` Björn Höfling
  2021-03-01 10:50       ` zimoun
  0 siblings, 1 reply; 5+ messages in thread
From: Björn Höfling @ 2021-02-27 23:29 UTC (permalink / raw)
  To: zimoun; +Cc: 46780-done

[-- Attachment #1: Type: text/plain, Size: 1025 bytes --]

On Sat, 27 Feb 2021 14:58:47 +0100
Björn Höfling <bjoern.hoefling@bjoernhoefling.de> wrote:

> On Fri, 26 Feb 2021 23:08:42 +0100
> zimoun <zimon.toutoune@gmail.com> wrote:
> 
> > What about adding a phase just before the test?  For example in this
> > build.xml file fix the max memory to 20G if it is greater.  

Thanks for the idea.

I first tested it with maxmemory="1M" and this fails with a OOM-error
on my pc, thus I knew this setting is really honored.

Now I set it to 2G and sent a patch under commit:

23dcf4339d1dc102b2c509a151734f4caff793bd

And it works now on Berlin:

https://ci.guix.gnu.org/build/361691/details

Closing.

Björn

PS: While looking at the Cuirass logs, I remembered the other
memory-problem we head, it was with java-kafka-clients:

https://ci.guix.gnu.org/build/361612/details
https://debbugs.gnu.org/cgi/bugreport.cgi?bug=40554

At first sight, we could try the same trick here. I will investigate
this in the next week, if not someone else is quicker.

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 195 bytes --]

^ permalink raw reply	[flat|nested] 5+ messages in thread

* bug#46780: java-snappy: Test failure on ci.guix.gnu.org
  2021-02-27 23:29     ` Björn Höfling
@ 2021-03-01 10:50       ` zimoun
  0 siblings, 0 replies; 5+ messages in thread
From: zimoun @ 2021-03-01 10:50 UTC (permalink / raw)
  To: Björn Höfling; +Cc: 46780-done

Hi,

On Sun, 28 Feb 2021 at 00:29, Björn Höfling <bjoern.hoefling@bjoernhoefling.de> wrote:

> I first tested it with maxmemory="1M" and this fails with a OOM-error
> on my pc, thus I knew this setting is really honored.
>
> Now I set it to 2G and sent a patch under commit:
>
> 23dcf4339d1dc102b2c509a151734f4caff793bd
>
> And it works now on Berlin:
>
> https://ci.guix.gnu.org/build/361691/details
>
> Closing.

Cool if it worked! :-)


Cheers,
simon




^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2021-03-01 10:57 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-02-25 20:52 bug#46780: java-snappy: Test failure on ci.guix.gnu.org Björn Höfling
2021-02-26 22:08 ` zimoun
2021-02-27 13:58   ` Björn Höfling
2021-02-27 23:29     ` Björn Höfling
2021-03-01 10:50       ` zimoun

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).