【发布时间】:2011-04-28 15:49:43
【问题描述】:
在调试时,Eclipse 中的 Debug 视图会显示调用堆栈。这是伟大的。但我希望能够过滤掉所有我绝对不关心的调用,例如 Spring 和 JUnit runner。
这是我现在调用堆栈的一个示例。我想将条目保持为粗体,同时隐藏所有其他条目。有可能以任何方式做吗? (插件,下一个 Eclipse 版本,配置,...)
com.myproject.mymodule.MyFinderObject.fetchDestinationSettings
com.myproject.mymodule.MyFinderObject.compareCurrentSettings
com.myproject.mymodule.MyFinderObject.compareSettings
sun.reflect.NativeMethodAccessorImpl.invoke0
sun.reflect.NativeMethodAccessorImpl.invoke
sun.reflect.DelegatingMethodAccessorImpl.invoke
java.lang.reflect.Method.invoke
org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection
org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint
org.springframework.aop.framework.ReflectiveMethodInvocation.proceed
com.myproject.caching.CachingInterceptor.invoke
org.springframework.aop.framework.ReflectiveMethodInvocation.proceed
org.springframework.aop.interceptor.ExposeInvocationInterceptor.invoke
org.springframework.aop.framework.ReflectiveMethodInvocation.proceed
org.springframework.aop.framework.JdkDynamicAopProxy.invoke
$Proxy43.doSthWith
com.myproject.mymodule.MyFinderObjectTest.testSettingComparisonForCurrentSettings
sun.reflect.NativeMethodAccessorImpl.invoke0
sun.reflect.NativeMethodAccessorImpl.invoke
sun.reflect.DelegatingMethodAccessorImpl.invoke
java.lang.reflect.Method.invoke
com.myproject.mymodule.MyFinderObjectTest
com.myproject.mymodule.MyFinderObjectTest
com.myproject.mymodule.MyFinderObjectTest
junit.framework.TestResult$1.protect
junit.framework.TestResult.runProtected
junit.framework.TestResult.run
com.myproject.mymodule.MyFinderObjectTest
junit.framework.TestSuite.runTest
junit.framework.TestSuite.run
org.junit.internal.runners.JUnit38ClassRunner.run
org.eclipse.jdt.internal.junit4.runner.JUnit4TestMethodReference
org.eclipse.jdt.internal.junit.runner.TestExecution.run
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main
【问题讨论】:
-
顺便问一下,你认为这会是一个合理的功能请求吗?
-
当然——听起来也没有那么难。将探索调试 API。
-
@espinchi,我在 IntelliJ 中使用了这个功能,它有很大帮助。
-
eclipse bug tracker 中有一个功能请求:2009 年报告,目前仍处于“NEW”状态:bugs.eclipse.org/bugs/show_bug.cgi?id=273194(此评论无助于解决问题,但至少其他人对此感兴趣,也不必搜索eclipse bug tracker)
-
还有一张 Eclipse Bug Tracker 中的票:bugs.eclipse.org/bugs/show_bug.cgi?id=513499(从 2017 年开始,状态:“ASSIGNED”)
标签: java eclipse debugging callstack