Summary: | Debug Shell with Remote Java Application connection reports "Evaluation failed" for valid expressions | ||
---|---|---|---|
Product: | [Eclipse Project] JDT | Reporter: | David M. Karr <davidmichaelkarr> |
Component: | Debug | Assignee: | JDT-Debug-Inbox <jdt-debug-inbox> |
Status: | NEW --- | QA Contact: | |
Severity: | normal | ||
Priority: | P3 | CC: | sarika.sinha |
Version: | 4.11 | Keywords: | helpwanted |
Target Milestone: | --- | ||
Hardware: | PC | ||
OS: | Windows 7 | ||
Whiteboard: | stalebug |
Description
David M. Karr
2019-05-13 12:37:36 EDT
Could this possibly be caused by running a particular JRE (not JDK) in the container? The image is based on the Alpine JRE image. I was planning on doing some testing today to change the base image to be a JDK-based image. Is there any chance that will make a difference? Have you tried changing suspend=n to suspend=y to let it wait until you attach the debugger. No, but I can't imagine how that could be relevant to this. Do you have a specific reason you're asking about that? After having to fix several other problems, and having some make a JDK-based image available to me, I've determined that this doesn't make any difference. With the JDK-based image, I can see the variables, but nothing useful happens in the Debug Shell view. And now concerning the suggestion to change "suspend" to "y". This had no impact in the application code that I was trying to debug. However, this provided what I hope will be an important clue to someone out there. I also had a breakpoint set in "org.springframework.core.io.ClassPathResource.getInputStream()" to debug an unrelated problem. Normally, when "suspend" is "n", I don't attempt to connect from the debugger until I finally see the "Started Application in ..." message from the SpringBoot framework. If I do that, then I don't hit the breakpoint in ClassPathResource, because it's done with all that work by that time. When I changed "suspend" to "y" and then connected my debugger at closer to startup, it DID hit that breakpoint, and what I discovered was that at that point, the Debug Shell view was working perfectly fine, at that breakpoint. However, when I resumed and let it finish starting up, and then performed the test that hit the breakpoint in my application code, the Debug Shell was then back to being useless, despite the fact that I could see all the variable info in the Variables panel and in hovers. Why would the Debug Shell be working properly at that point in the Spring code, but not in my application code? One difference between these two cases is that when it hits the breakpoint in ClassPathResource, it's in the thread "main", but when it hits the breakpoint in my application code, it's in a "Daemon Thread". In any case, the behavior is consistent. When it hits the Spring code in the main thread, the Debug Shell works fine. When it hits the application code in the Daemon Thread, the Debug Shell doesn't work. Thank you for all the investigations, will see if someone can work on this. This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet. If you have further information on the current state of the bug, please add it. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant. -- The automated Eclipse Genie. This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet. If you have further information on the current state of the bug, please add it. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant. -- The automated Eclipse Genie. |