Cannot attach source code of an HttpServlet [message #1835787] |
Sat, 12 December 2020 17:38 |
Jim Anderson Messages: 109 Registered: October 2014 |
Senior Member |
|
|
Environment:
Eclipse IDE for Enterprise Java Developers
Version: 2020-09 (4.17.0)
It was a struggle, but I have Eclipse IDE up and running. Happily, I have found a bug or two and fixed them already.
My current problem is that I have a null pointer in one of my HttpServlets. Most of my source code is in the directory:
project
src
Eclipse sees the source code in the 'src' directory.
The HttpServlets are in the directory:
project
WebContent
classes
bfs
abc
where 'abc' is the name of the project.
When running the project in debug mode, Eclipse crashs in 'SearchHandler.class' which is in the 'abc' directory. It pops up a tab for the class. Note then when it knows where the source code is, it pops up a tab in the file editor and it displays the code. In the 'SearchHandler.class' tab, it says 'Class File Editor ---- Source not found'.
Just below that, on the same tab, it says, "The source attachment does not contain the source for the file SearchHandler.class. You can change the source attachment by clicking Change Attached Source below."
I click on the button, "Change Attached Source ..." and the "Source Attachment Configuration" window popups up. It has two options, and I have tried both with no success.
Option 1:
Click on the "Workspace location" button and then I have 2 sub-options:
Option 1A: enter the path by hand
Option 1B: browse.
I chose to browse and navigated to the source directory of the HttpServlets shown above.
I then hit the 'OK' button. No acknowledgement or feedback was given. At this point the debug sessions was still running, so I terminated the session and tried starting a new session, but the same error occured.
Option 2:
Click on the "External location' button.
I then navigated the full linux path to the source code directory (it would only accept the directory, not the path to the soruce file) and hit OK. Again, no acknowledgement or feedback. Again, I tried restarting, but no success.
I am at a loss to what else to try.
I must be missing something. Can someone help?
Jim A.
|
|
|
Powered by
FUDForum. Page generated in 0.03126 seconds