Use the Right Tools to De­bug Java Ap­pli­ca­tions

De­bug­ging code is an es­sen­tial part of the pro­gram de­vel­op­ment cy­cle, and de­bug­ging Java ap­pli­ca­tions has its own spe­cial prob­lems. In this ar­ti­cle, the au­thor analy­ses the causes of prob­lems in Java code, and sug­gests ways and means to de­bug them.

OpenSource For You - - Contents -

Java pro­grams are al­ways com­plex to de­bug and an­a­lyse due to their ver­sa­til­ity in sup­port­ing a lot of fea­tures, plat­forms, etc. When writ­ing Java pro­grams, one of the pri­mary con­cerns the de­vel­oper has to ad­dress is the pro­vi­sion of a de­bug fa­cil­ity for fu­ture use, to solve any prob­lem that may oc­cur in a test en­vi­ron­ment or even in a real-time client en­vi­ron­ment.

The de­bug­ging fa­cil­ity would de­pend on the types of prob­lems that might arise dur­ing Java pro­gram ex­e­cu­tion. These prob­lems would de­pend upon:

1. Fea­tures used (like de­vice in­ter­face, ex­ter­nal con­nec­tiv­ity like file han­dling, data­base us­age)

2. Con­cept im­ple­mented/linked (like RMI, JDBC, threads, com­mu­ni­ca­tion with other Java pro­grams)

3. GUI fa­cil­ity 4. User interaction with a util­ity, script, GUI, etc 5. Com­pat­i­bil­ity (like the OS han­dled, JDK ver­sion sup­ported, etc)

Clas­si­fi­ca­tion of Java prob­lems

Based on these fac­tors and other mi­nor cat­e­gories, we can clas­sify prob­lems in Java ap­pli­ca­tions as fol­lows:

1. Mem­ory re­lated prob­lems

2. Syn­chro­ni­sa­tion/thread re­lated is­sues

3. Com­mu­ni­ca­tion re­lated prob­lems (back­end, in­ter­face and GUI)

4. Prob­lems re­lated to the data­base, con­nec­tiv­ity and file han­dling

5. Is­sues linked to the bound­ary con­di­tion

6. Na­tive/JNI re­lated is­sues

Newspapers in English

Newspapers from India

© PressReader. All rights reserved.