Java program terminates unexpectedly without any error message -
I have written a Java program that needs to process thousands of text files (all memory needs to be loaded on ). It works fine with 123 input files, but when I run it to process around 5000 files, it ends unexpectedly in the middle of the road, without any error message / exception Can be wrong, give clues about this?
I am using jdk1.6 on Mac OS leopard with 2 GB RAM.
Given that this is your program, I recommend that you do the following:
First, change the main
method so that everything is done in a try / grip block which reports all the incomplete exceptions; Something like this:
public static zero main (string [] arghhhhh) {try {...} hold (throwable ex) {System.err.println ("Uncoded exception" Pre .getMessage ()); Ex.printStackTrace (System.err); Second, look anywhere that you can catch them and "squash" the unexpected exception and can not report them. Thirdly, you can call anywhere system.exit ()
It can be quietly in libraries too ... if you are using badly written text .
If those measures do not give you the answer, then try to understand how the application is coming out
By adding trace print statement to key points, by running from the debugger with the breakpoint set on key points or
Comments
Post a Comment