Grails 2.5.6中的Segfault / SIGSEGV运行功能测试

时间:2018-08-16 10:31:30

标签: grails segmentation-fault functional-testing sigsegv jvm-crash

在Grails 2.5.6中运行功能测试时,我们会看到一个Segfault:

我已向Oracle(https://bugs.openjdk.java.net/browse/JDK-8209525)提交了一份报告,Oracle最初建议关闭-javaagent JVM选项,该选项似乎已被Grails打开(Spring Loaded自动重载)和-Xverify:none选项,但我尝试了-no-reloading和-Ddisable.auto.recompile = true选项,但似乎都没有真正影响该选项。

我想知道这与Grails有什么特别的关系吗?是否有Grails用户遇到过此类段错误。

|org.modelcatalogue.core.remoteTesting.HistoryIsPopulatedAccordingToModelActivitySpec : started
| Running 246 spock tests... 61 of 246
2018-08-16 10:40:28,372 [RxComputationScheduler-4] INFO  elasticsearch.ElasticSearchService  - Indexing NEW_TESTING_MODEL [168@0.0.1] (DRAFT:DataClass:168)0
2018-08-16 10:40:29,315 [RxComputationScheduler-4] INFO  elasticsearch.ElasticSearchService  - Indexing NEW_TESTING_MODEL [168@0.0.1] (DRAFT:DataClass:168)0
2018-08-16 10:40:29,548 [RxComputationScheduler-7] INFO  elasticsearch.ElasticSearchService  - Indexing TEST_ELEMENT [169@0.0.1] (DRAFT:DataElement:169)0
2018-08-16 10:40:30,123 [http-nio-8190-exec-9] INFO  core.RelationshipService  - Relationship NEW_TESTING_MODEL =[contains]=> TEST_ELEMENT checked for presence but not found. Finding relationship is slow, consider using 'skipUniqueChecking' flag for optimistic relationship linking.
2018-08-16 10:40:30,124 [http-nio-8190-exec-9] INFO  core.RelationshipService  - Relationship NEW_TESTING_MODEL =[contains]=> TEST_ELEMENT checked for presence but not found. Finding relationship is slow, consider using 'skipUniqueChecking' flag for optimistic relationship linking.
2018-08-16 10:40:30,371 [RxComputationScheduler-4] INFO  elasticsearch.ElasticSearchService  - Indexing Relationship[id: 76, source: NEW_TESTING_MODEL [168@0.0.1] (DRAFT:DataClass:168), destination: TEST_ELEMENT [169@0.0.1] (DRAFT:DataElement:169), type: containment]0
2018-08-16 10:40:42,515 [RxComputationScheduler-1] INFO  elasticsearch.ElasticSearchService  - Indexing Boolean [30@0.0.1] (FINALIZED:DataType:30)0
2018-08-16 10:40:42,581 [http-nio-8190-exec-1] INFO  elasticsearch.ElasticSearchService  - Indexing Relationship[id: 77, source: Boolean [30@0.0.1] (FINALIZED:DataType:30), destination: Boolean [170@0.0.1] (DRAFT:DataType:170), type: origin]2
#
# A fatal error has been detected by the Java Runtime Environment:
#
#  SIGSEGV (0xb) at pc=0x00000001098d13e4, pid=8654, tid=0x0000000000005103
#
# JRE version: OpenJDK Runtime Environment (8.0_181-b02) (build 1.8.0_181-b02)
# Java VM: OpenJDK 64-Bit Server VM (25.181-b02 mixed mode bsd-amd64 compressed oops)
# Problematic frame:
# V  [libjvm.dylib+0xf33e4]  GraphBuilder::try_inline_full(ciMethod*, bool, Bytecodes::Code, Instruction*)+0x4d6
#
# Failed to write core dump. Core dumps have been disabled. To enable core dumping, try "ulimit -c unlimited" before starting Java again
#
# An error report file with more information is saved as:
# /Users/james/Documents/work/metadata_consulting/our_code/repositories/MetadataConsulting/ModelCataloguePluginTesting/ModelCatalogueCorePluginTestApp/hs_err_pid8654.log
#
# Compiler replay data is saved as:
# /Users/james/Documents/work/metadata_consulting/our_code/repositories/MetadataConsulting/ModelCataloguePluginTesting/ModelCatalogueCorePluginTestApp/replay_pid8654.log
#
# If you would like to submit a bug report, please visit:
#   http://www.azulsystems.com/support/
#
| Failure:  Verify that the history is populated according to activity made on a model(org.modelcatalogue.core.remoteTesting.HistoryIsPopulatedAccordingToModelActivitySpec)
|  org.openqa.selenium.WebDriverException: unknown error: Element <span class="catalogue-element-treeview-name ng-binding text-warning" ng-class="{ 'text-warning': element.status == 'DRAFT', 'text-info': element.status == 'PENDING', 'text-danger': (element.status == 'DEPRECATED' || element.undone) }" ng-click="select(node)">...</span> is not clickable at point (46, 312). Other element would receive the click: <div modal-render="true" tabindex="-1" role="dialog" class="modal fade ng-isolate-scope basic-edit-modal-prompt in" uib-modal-animation-class="fade" modal-in-class="in" ng-style="{'z-index': 1050 + index*10, display: 'block'}" uib-modal-window="modal-window" window-class="basic-edit-modal-prompt" size="lg" index="0" animate="animate" modal-animation="true" style="z-index: 1050; display: block;">...</div>
  (Session info: chrome=68.0.3440.106)
  (Driver info: chromedriver=2.41.578706 (5f725d1b4f0a4acbf5259df887244095596231db),platform=Mac OS X 10.12.6 x86_64) (WARNING: The server did not provide any stacktrace information)
Command duration or timeout: 39 milliseconds
Build info: version: '2.51.0', revision: '1af067dbcaedd7d2ab9af5151fc471d363d97193', time: '2016-02-05 11:20:57'
System info: host: 'James-Dais-Mac-Pro.local', ip: '10.0.3.44', os.name: 'Mac OS X', os.arch: 'x86_64', os.version: '10.12.6', java.version: '1.8.0_181'
Driver info: org.openqa.selenium.chrome.ChromeDriver
Capabilities [{mobileEmulationEnabled=false, hasTouchScreen=false, platform=MAC, acceptSslCerts=false, goog:chromeOptions={debuggerAddress=localhost:55832}, acceptInsecureCerts=false, webStorageEnabled=true, browserName=chrome, takesScreenshot=true, javascriptEnabled=true, setWindowRect=true, unexpectedAlertBehaviour=, applicationCacheEnabled=false, rotatable=false, networkConnectionEnabled=false, chrome={chromedriverVersion=2.41.578706 (5f725d1b4f0a4acbf5259df887244095596231db), userDataDir=/var/folders/66/h2wxz6293nlfy9gjy8x061pc0000gp/T/.org.chromium.Chromium.cCLhz3}, takesHeapSnapshot=true, pageLoadStrategy=normal, databaseEnabled=false, handlesAlerts=true, version=68.0.3440.106, browserConnectionEnabled=false, nativeEvents=true, locationContextEnabled=true, cssSelectorsEnabled=true}]
Session ID: f0cfd12a1e830d8e80ac49b992f138ad
    at org.openqa.selenium.remote.ErrorHandler.createThrowable(ErrorHandler.java:206)
    at org.openqa.selenium.remote.ErrorHandler.throwIfResponseFailed(ErrorHandler.java:158)
    at org.openqa.selenium.remote.RemoteWebDriver.execute(RemoteWebDriver.java:678)
    at org.openqa.selenium.remote.RemoteWebElement.execute(RemoteWebElement.java:327)
    at org.openqa.selenium.remote.RemoteWebElement.click(RemoteWebElement.java:85)
    at geb.navigator.NonEmptyNavigator.click(NonEmptyNavigator.groovy:432)
    at geb.content.TemplateDerivedPageContent.click(TemplateDerivedPageContent.groovy:72)
    at org.modelcatalogue.core.geb.DataModelTreeViewModule.select(DataModelTreeViewModule.groovy:58)
    at geb.content.TemplateDerivedPageContent.methodMissing(TemplateDerivedPageContent.groovy:85)
    at org.modelcatalogue.core.remoteTesting.HistoryIsPopulatedAccordingToModelActivitySpec.Verify that the history is populated according to activity made on a model(HistoryIsPopulatedAccordingToModelActivitySpec.groovy:135)

|org.modelcatalogue.core.remoteTesting.HistoryIsPopulatedAccordingToModelActivitySpec : finished

来自hs_err的一些堆栈信息:

Stack: [0x0000700010e8a000,0x0000700010f8a000],  sp=0x0000700010f88f20,  free space=1019k
Native frames: (J=compiled Java code, j=interpreted, Vv=VM code, C=native code)
V  [libjvm.dylib+0xf33e4]  GraphBuilder::try_inline_full(ciMethod*, bool, Bytecodes::Code, Instruction*)+0x4d6
V  [libjvm.dylib+0xf3ba6]  GraphBuilder::try_inline(ciMethod*, bool, Bytecodes::Code, Instruction*)+0xde
V  [libjvm.dylib+0xf4bfe]  GraphBuilder::invoke(Bytecodes::Code)+0xb5a
V  [libjvm.dylib+0xf72a3]  GraphBuilder::iterate_bytecodes_for_block(int)+0x2449
V  [libjvm.dylib+0xf3a75]  GraphBuilder::iterate_all_blocks(bool)+0x6f
V  [libjvm.dylib+0xf8061]  GraphBuilder::GraphBuilder(Compilation*, IRScope*)+0x2cd
V  [libjvm.dylib+0xfd804]  IRScope::IRScope(Compilation*, IRScope*, int, ciMethod*, int, bool)+0x154
V  [libjvm.dylib+0xfd8b5]  IR::IR(Compilation*, ciMethod*, int)+0x85
V  [libjvm.dylib+0xe7be1]  Compilation::build_hir()+0xa7
V  [libjvm.dylib+0xe7d70]  Compilation::compile_java_method()+0x58
V  [libjvm.dylib+0xe7f99]  Compilation::compile_method()+0x6d
V  [libjvm.dylib+0xe81ae]  Compilation::Compilation(AbstractCompiler*, ciEnv*, ciMethod*, int, BufferBlob*)+0x1a2
V  [libjvm.dylib+0xe89a0]  Compiler::compile_method(ciEnv*, ciMethod*, int)+0x90
V  [libjvm.dylib+0x1b3d78]  CompileBroker::invoke_compiler_on_method(CompileTask*)+0x5b2
V  [libjvm.dylib+0x1b62bf]  CompileBroker::compiler_thread_loop()+0x291
V  [libjvm.dylib+0x53eca1]  JavaThread::thread_main_inner()+0x9b
V  [libjvm.dylib+0x540366]  JavaThread::run()+0x1c0
V  [libjvm.dylib+0x4609ea]  java_start(Thread*)+0xf6
C  [libsystem_pthread.dylib+0x393b]  _pthread_body+0xb4
C  [libsystem_pthread.dylib+0x3887]  _pthread_body+0x0
C  [libsystem_pthread.dylib+0x308d]  thread_start+0xd
C  0x0000000000000000


Current CompileTask:
C1:1144349 36863   !   3       org.modelcatalogue.core.persistence.DataModelGormService$$EnhancerBySpringCGLIB$$651ed01a::findById (304 bytes)

VM参数等:

VM Arguments:
jvm_args: -Dfile.encoding=UTF-8 -Xmx1536M -Xms128M -Dgrails.fork.parent.process.port=55737 -Dgrails.fork.active=true -Dgrails.build.execution.context=/private/var/folders/66/h2wxz6293nlfy9gjy8x061pc0000gp/T/ModelCatalogueCorePluginTestApp8133164502043084747grails-execution-context -Dgrails.home=/Users/james/.grails/wrapper/2.5.6/grails-2.5.6 -javaagent:/Users/james/.grails/wrapper/2.5.6/grails-2.5.6/lib/org.springframework/springloaded/jars/springloaded-1.2.7.RELEASE.jar -Xverify:none -Dspringloaded.synchronize=true -Djdk.reflect.allowGetCallerClass=true -Dspringloaded=profile=grails;cacheDir=/Users/james/.grails/2.5.6 
java_command: org.grails.plugins.tomcat.fork.ForkedTomcatServer
java_class_path (initial): /Users/james/.sdkman/candidates/java/8.0.181-zulu/lib/tools.jar:/Users/james/.grails/wrapper/2.5.6/grails-2.5.6/lib/org.codehaus.groovy/groovy-all/jars/groovy-all-2.4.10.jar:/Users/james/.grails/wrapper/2.5.6/grails-2.5.6/lib/org.slf4j/jcl-over-slf4j/jars/jcl-over-slf4j-1.7.21.jar:/Users/james/.grails/wrapper/2.5.6/grails-2.5.6/lib/org.codehaus.gant/gant_groovy1.8/jars/gant_groovy1.8-1.9.6.jar:/Users/james/.grails/wrapper/2.5.6/grails-2.5.6/lib/org.apache.tomcat.embed/tomcat-embed-logging-log4j/jars/tomcat-embed-logging-log4j-7.0.70.jar:/Users/james/.grails/wrapper/2.5.6/grails-2.5.6/dist/grails-plugin-log4j-2.5.6.jar:/Users/james/.grails/wrapper/2.5.6/grails-2.5.6/lib/log4j/log4j/jars/log4j-1.2.17.jar:/Users/james/.grails/wrapper/2.5.6/grails-2.5.6/dist/grails-bootstrap-2.5.6.jar:/Users/james/.grails/wrapper/2.5.6/grails-2.5.6/lib/org.apache.ant/ant-launcher/jars/ant-launcher-1.9.4.jar:/Users/james/.grails/wrapper/2.5.6/grails-2.5.6/lib/org.apache.ant/ant-junit/jars/ant-junit-1.9.4.jar:/Users/james/.grails/wrapper/2.5.6/grails-2.5.6/lib/jline/jline/jars/jline-2.12.jar:/Users/james/.grails/wrapper/2.5.6/grails-2.5.6/lib/org.slf4j/slf4j-api/jars/slf4j-api-1.7.21.jar:/Users/james/.grails/wrapper/2.5.6/grails-2.5.6/lib/org.fusesource.jansi/jansi/jars/jansi-1.11.jar:/Users/james/.grails/wrapper/2.5.6/grails-2.5.6/lib/org.apache.ant/ant-trax/jars/ant-trax-1.7.1.jar:/Users/james/.grails/wrapper/2.5.6/grails-2.5.6/lib/org.apache.ivy/ivy/jars/ivy-2.3.0.jar:/Users/james/.grails/wrapper/2.5.6/grails-2.5.6/lib/org.apache.ant/ant/jars/ant-1.9.4.jar:/Users/james/.m2/repository/org/apache/tomcat/embed/tomcat-embed-el/8.0.33/tomcat-embed-el-8.0.33.jar:/Users/james/.m2/repository/org/apache/tomcat/embed/tomcat-embed-jasper/8.0.33/tomcat-embed-jasper-8.0.33.jar:/Users/james/.m2/repository/org/apache/tomcat/embed/tomcat-embed-logging-log4j/8.0.33/tomcat-embed-logging-log4j-8.0.33.jar:/Users/james/.m2/repository/org/apache/tomcat/embed/tomcat-embed-websock
Launcher Type: SUN_STANDARD

Environment Variables:
JAVA_HOME=/Users/james/.sdkman/candidates/java/8.0.181-zulu
PATH=/Users/james/.sdkman/candidates/maven/current/bin:/Users/james/.sdkman/candidates/java/8.0.181-zulu/bin:/Users/james/.sdkman/candidates/groovy/current/bin:/Users/james/.sdkman/candidates/grails/2.5.6/bin:/Users/james/.sdkman/candidates/gradle/current/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/Applications/Neo4j Community Edition 3.2.3.app/Contents/Resources/app/bin/
SHELL=/usr/local/bin/bash

Signal Handlers:
SIGSEGV: [libjvm.dylib+0x584aa5], sa_mask[0]=11111111011111110111111111111111, sa_flags=SA_ONSTACK|SA_RESTART|SA_SIGINFO
SIGBUS: [libjvm.dylib+0x584aa5], sa_mask[0]=11111111011111110111111111111111, sa_flags=SA_RESTART|SA_SIGINFO
SIGFPE: [libjvm.dylib+0x45dfdc], sa_mask[0]=11111111011111110111111111111111, sa_flags=SA_RESTART|SA_SIGINFO
SIGPIPE: [libjvm.dylib+0x45dfdc], sa_mask[0]=11111111011111110111111111111111, sa_flags=SA_RESTART|SA_SIGINFO
SIGXFSZ: [libjvm.dylib+0x45dfdc], sa_mask[0]=11111111011111110111111111111111, sa_flags=SA_RESTART|SA_SIGINFO
SIGILL: [libjvm.dylib+0x45dfdc], sa_mask[0]=11111111011111110111111111111111, sa_flags=SA_RESTART|SA_SIGINFO
SIGUSR1: SIG_DFL, sa_mask[0]=00000000000000000000000000000000, sa_flags=none
SIGUSR2: [libjvm.dylib+0x45dafa], sa_mask[0]=00100000000000000000000000000000, sa_flags=SA_RESTART|SA_SIGINFO
SIGHUP: [libjvm.dylib+0x45c0c5], sa_mask[0]=11111111011111110111111111111111, sa_flags=SA_RESTART|SA_SIGINFO
SIGINT: [libjvm.dylib+0x45c0c5], sa_mask[0]=11111111011111110111111111111111, sa_flags=SA_RESTART|SA_SIGINFO
SIGTERM: [libjvm.dylib+0x45c0c5], sa_mask[0]=11111111011111110111111111111111, sa_flags=SA_RESTART|SA_SIGINFO
SIGQUIT: [libjvm.dylib+0x45c0c5], sa_mask[0]=11111111011111110111111111111111, sa_flags=SA_RESTART|SA_SIGINFO

0 个答案:

没有答案