-
Notifications
You must be signed in to change notification settings - Fork 125
Double click on any Live Beans Graph node yields to NullPointerException #300
Comments
It seems to work fine for me. This is what I did step by step:
I also tried double-clicking on the 'class' and 'resource' nodes in the tree viewer. These didn't open anything, perhaps they should, but I never got an NPE in the error log. I also tired opening the beans view from boot dash. I.e. via its 'properties page' by selecting the 'beans' tab. Double-click there doesn't seem to do anything (again, perhaps it should), but it didn't cause any errors. I think we should probably look into why some of the double-click actions I tested don't actually open anything. We'd probably focus on fixing this in the view opend via boot dash as the other view is a 'legacy' view which is meant to be phased out and replaced with the boot-dash-integrated view. However, since I've never seen any errors like the one you describe I'm not sure this has anything to do with your reported problem. So it would be nice if you can add further details that might help reproduce this error (e.g a detailed sequence of steps just like the one I posted here and/or a sample project (if you don't use a easy to recreate sample like a fresh app created from the wizard). |
So my setup is different: I have a Spring application deployed on Tomcat 8.5 and is connected to "Live Beans Graph" via JMX. As you can see from the screenshot below, the graph presents correctly what I have in my context. However when I double-click any node (say filterChains in the screenshot), it will yields a NullPointerException. My OS
My log
|
Okay, the detailed info about OS and such is somewhat useful. But really, what I need to reproduce this is some rather precise steps to set things up exactly as you did. So something like:
I am going to try to figure some of this out myself right now, but you are really making me guess a lot of the details here. |
Here's how far I got:
Not sure what to do next to get a live bean graph for the running app. |
Next steps that I figured out:
|
The NPE is caused by |
... if not targeted to a specific project. Relates to: #300
(comment in Pivotal Tracker added by Kris De Volder:) Fix pushed to master. |
Sorry, didn't plan to make your life more difficult. :( I didn't mentioned that because it is quite standard, but here it is
It is just a standard Spring MVC with Spring security wrapping around it. The bean I clicked is the out-of-the box Spring security class. I will try to with a similar sample spring app when I have a chance.
A standard
just drop the
|
Thanks for extra details. Fortunately I was already able to reproduce the problem using the TcServer that is included by default in STS. Allthough the details of how I did things aren't quite the same as your description, I am fairly confident that the problem is fixed. If you have the time you could confirm that the fix works for your situation by using a nightly distribution build, which you can download here: http://dist.springsource.com/snapshot/STS/nightly-distributions.html PS: For future reference, when it comes to 'sample' apps it best to actually attach a sample app rather than provide a general description. Yes, I could probably coble something together based on that description but, the point is, it will cost some time. Time I could otherwise spend on debugging and fixing the problem (or other problems). Also I would still be guessing about many details. These details may not matter... or they might. Anyhow... in the end, I think all is well since I think I was able to figure out and fix the problem already. |
I'm using Spring IDE Version: 3.9.5.201807030714-RELEASE. Please find the generated error log below:
eclipse.buildId=4.8.0.I20180611-0500
java.version=1.8.0_171
java.vendor=Oracle Corporation
BootLoader constants: OS=linux, ARCH=x86_64, WS=gtk, NL=en_US
Framework arguments: -product org.eclipse.epp.package.java.product
Command-line arguments: -os linux -ws gtk -arch x86_64 -product org.eclipse.epp.package.java.product
This is a continuation of log file /home/user/workspace/.metadata/.bak_0.log
Created Time: 2018-07-13 22:48:27.759
org.eclipse.jface
Error
Sat Jul 14 00:30:54 CEST 2018
Problems occurred when invoking code from plug-in: "org.eclipse.jface".
java.lang.NullPointerException
at org.springframework.ide.eclipse.beans.ui.live.utils.JdtUtils.getJavaProject(JdtUtils.java:41)
at org.springframework.ide.eclipse.beans.ui.live.utils.JdtUtils.getJavaType(JdtUtils.java:65)
at org.springframework.ide.eclipse.beans.ui.live.model.TypeLookupImpl.findType(TypeLookupImpl.java:65)
at org.springframework.ide.eclipse.beans.ui.live.actions.AbstractOpenResourceAction.openInEditor(AbstractOpenResourceAction.java:54)
at org.springframework.ide.eclipse.beans.ui.live.actions.OpenBeanClassAction.run(OpenBeanClassAction.java:52)
at org.springframework.ide.eclipse.beans.ui.livegraph.views.LiveBeansGraphView$1.doubleClick(LiveBeansGraphView.java:131)
at org.eclipse.jface.viewers.StructuredViewer$1.run(StructuredViewer.java:830)
at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:42)
at org.eclipse.ui.internal.JFaceUtil.lambda$0(JFaceUtil.java:44)
at org.eclipse.jface.util.SafeRunnable.run(SafeRunnable.java:173)
at org.eclipse.jface.viewers.StructuredViewer.fireDoubleClick(StructuredViewer.java:827)
at org.eclipse.zest.core.viewers.GraphViewer.access$2(GraphViewer.java:1)
at org.eclipse.zest.core.viewers.GraphViewer$2.mouseDoubleClick(GraphViewer.java:104)
at org.eclipse.swt.widgets.TypedListener.handleEvent(TypedListener.java:197)
at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:86)
at org.eclipse.swt.widgets.Display.sendEvent(Display.java:5686)
at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1370)
at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:4940)
at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:4518)
at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine$5.run(PartRenderingEngine.java:1170)
at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:336)
at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine.run(PartRenderingEngine.java:1059)
at org.eclipse.e4.ui.internal.workbench.E4Workbench.createAndRunUI(E4Workbench.java:153)
at org.eclipse.ui.internal.Workbench.lambda$3(Workbench.java:667)
at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:336)
at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:597)
at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:148)
at org.eclipse.ui.internal.ide.application.IDEApplication.start(IDEApplication.java:152)
at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:196)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:134)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:104)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:388)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:243)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:656)
at org.eclipse.equinox.launcher.Main.basicRun(Main.java:592)
at org.eclipse.equinox.launcher.Main.run(Main.java:1498)
at org.eclipse.equinox.launcher.Main.main(Main.java:1471)
The text was updated successfully, but these errors were encountered: