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

Joseph Lynch edited comment on CASSANDRA-15014 at 2/25/19 6:23 PM:
-------------------------------------------------------------------

Alright, finally figured out why attaching a debugger was causing the tests to 
crash, looks like the {{InstanceClassLoader}} switched from a blacklist to a 
whitelist where we only use the shared class loader for whitelisted classes, I 
just added a whitelist for "com.yourkit" and I was able to attach again.

Just a few comments, +1 after fixing first one.
 * I don't think right now if a jvm-dtest fails the build actually fails (I 
inserted an exception into one of the tests and {{ant test-jvm-dtest}} still 
passed). Perhaps we need {{#!/bin/bash}} and {{set -e}} at the top of the file 
written by {{TestLocator.java}} and {{failonerror}} set on the ant {{exec}} 
line.
 * Do you find that 
[setting|https://github.com/apache/cassandra/compare/trunk...ifesdjeen:CASSANDRA-15014-trunk#diff-2cccd7bf48b7a9cc113ff564acd802a8R1340]
 {{MetaspaceSize}} or {{MaxMetaspaceExpansion}} does anything? In my experience 
they just cause a metaspace OOM before the GC can collect classes. Let's leave 
them out if we don't find they help?
 * After you applied my patch now there is a test-jvm-dtest and a 
test-distributed target. They do different things so maybe we should have both, 
but should we unify the names e.g. "test-jvm-dtest-forking" and 
"test-jvm-dtest" maybe?


was (Author: jolynch):
Alright, finally figured out why attaching a debugger was causing the tests to 
crash, looks like the {{InstanceClassLoader}} switched from a blacklist to a 
whitelist where we only use the shared class loader for whitelisted classes, I 
just added a whitelist for "com.yourkit" and I was able to attach again.

Just a few comments, fix'n'ship.
* I don't think right now if a jvm-dtest fails the build actually fails (I 
inserted an exception into one of the tests and {{ant test-jvm-dtest}} still 
passed). Perhaps we need {{#!/bin/bash}} and {{set -e}} at the top of the file 
written by {{TestLocator.java}} and {{failonerror}} set on the ant {{exec}} 
line. 
* Do you find that 
[setting|https://github.com/apache/cassandra/compare/trunk...ifesdjeen:CASSANDRA-15014-trunk#diff-2cccd7bf48b7a9cc113ff564acd802a8R1340]
 {{MetaspaceSize}} or {{MaxMetaspaceExpansion}} does anything? In my experience 
they just cause a metaspace OOM before the GC can collect classes. Let's leave 
them out if we don't find they help?
* After you applied my patch now there is a test-jvm-dtest and a 
test-distributed target. They do different things so maybe we should have both, 
but should we unify the names e.g. "test-jvm-dtest-forking" and 
"test-jvm-dtest" maybe?

> Unit tests failure on trunk
> ---------------------------
>
>                 Key: CASSANDRA-15014
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-15014
>             Project: Cassandra
>          Issue Type: Bug
>          Components: Test/unit
>            Reporter: Dinesh Joshi
>            Assignee: Alex Petrov
>            Priority: Major
>             Fix For: 4.0, 2.2.x, 3.0.x, 3.11.x
>
>         Attachments: Screen Shot 2019-02-11 at 12.30.19.png, Screen Shot 
> 2019-02-13 at 15.46.28.png, threads_stuck_waiting.png
>
>
> Currently org.apache.cassandra.distributed.test.DistributedReadWritePathTest 
> is failing on trunk with the following error -
> {code:java}
> [junit-timeout] Picked up JAVA_TOOL_OPTIONS: -Dfile.encoding=UTF8
> [junit-timeout] Testsuite: 
> org.apache.cassandra.distributed.test.DistributedReadWritePathTest
> [junit-timeout] Exception in thread "main" java.lang.OutOfMemoryError: 
> Metaspace
> [junit-timeout] Testsuite: 
> org.apache.cassandra.distributed.test.DistributedReadWritePathTest
> [junit-timeout] Testsuite: 
> org.apache.cassandra.distributed.test.DistributedReadWritePathTest Tests run: 
> 1, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 0 sec
> [junit-timeout] 
> [junit-timeout] Testcase: 
> org.apache.cassandra.distributed.test.DistributedReadWritePathTest:readWithSchemaDisagreement:
>  Caused an ERROR
> [junit-timeout] Forked Java VM exited abnormally. Please note the time in the 
> report does not reflect the time until the VM exit.
> [junit-timeout] junit.framework.AssertionFailedError: Forked Java VM exited 
> abnormally. Please note the time in the report does not reflect the time 
> until the VM exit.
> [junit-timeout] at java.util.Vector.forEach(Vector.java:1275)
> [junit-timeout] at java.util.Vector.forEach(Vector.java:1275)
> [junit-timeout] at java.lang.Thread.run(Thread.java:748)
> [junit-timeout] 
> [junit-timeout] 
> [junit-timeout] Test 
> org.apache.cassandra.distributed.test.DistributedReadWritePathTest FAILED 
> (crashed)
> [junitreport] Processing /tmp/cassandra/build/test/TESTS-TestSuites.xml to 
> /tmp/null1041131060
> [junitreport] Loading stylesheet 
> jar:file:/usr/share/ant/lib/ant-junit.jar!/org/apache/tools/ant/taskdefs/optional/junit/xsl/junit-frames.xsl
> [junitreport] Transform time: 277ms
> [junitreport] Deleting: /tmp/null1041131060{code}
> I have noticed sporadic failures in the 
> org.apache.cassandra.distributed.test.* suite.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to