File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

debuging WEB app without source codes [ECLIPSE]

 
Jan Krystof
Greenhorn
Posts: 3
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello,

firstly, I feel that this group (EJB and other Java EE tech...) is perhaps not the best one for this question..., however I guess that here will be experienced guys which I need. Nevertheless, my topic is related to J2EE isuues so I hope this topic will not be kicked off.

I have war file with NO source codes and I need to debug it. I use Eclipse so I did import the WAR file into my IDE. I was able to place breakpoint into the desired file since the respective `.class` file was automatically decompiled into `.java` file with use of JadClipse plug-in. But However, the breakpoint was not working. Then I decided to use jad.exe to decompile all classes into java source files and put them int src folder. Then I found a lot of erros, since the classes used generics and the jad.exe was not able to deal with type erasure.

Do you have any suggestions how to overcome this problem and be able to debug such project?

thanks

Jan
 
E Armitage
Rancher
Posts: 989
9
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
If you are meant to be debugging the code then the source code should be made available to you.
Otherwise you are stuck with hacking away with JD-Ecplise and JAD and manually fixing the code until it compiles.
 
Jeanne Boyarsky
author & internet detective
Marshal
Posts: 33671
316
Eclipse IDE Java VI Editor
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Jan,
I think IDEs and other tools is a better fit. I'm moving this thread there - a link will stay in the original location.
 
Peter Johnson
author
Bartender
Posts: 5852
7
Android Eclipse IDE Ubuntu
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Also, rather that decompiling all of the .class files and then trying to get them all to work, only decompile the one or two classes that you really need to work on. Then when you get them to compile, simply replace just those couple of class files in the original WAR. This is what I do when I need to make corrections to binaries I get from others. I do this even if I have access to the sources.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic