O'Reilly logo

J2EE™ and Beyond: Design, Develop, and Deploy World-Class Java™ Software by Art Taylor

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

The Benefits of Logging

Logging can be used to debug an application and determine the root cause of a failure, or to track program and user activity, and to provide a journal of the work being performed with a program for security reasons.

While there are not many who suggest that logging is unnecessary, there are those who argue there are better techniques for debugging than producing excessive log output. There is also the question of when to turn on debugging log output and what is involved in doing that. In its most primitive form, a series of output statements can be written into a Java application to debug the program, as shown below. Removing debugging would then require that all modules with the output statements would need to be removed—a ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required