LAKE: Using Log Files Recorded during Program Execution

LAKE: Using Log Files Recorded during Program Execution

Shaochun Xu, Dapeng Liu
Copyright: © 2014 |Pages: 12
DOI: 10.4018/ijsi.2014100101
OnDemand:
(Individual Articles)
Available
$37.50
No Current Special Offers
TOTAL SAVINGS: $37.50

Abstract

Logging has been mainly used as a helpful debugging aid. Very little literature has mentioned using logs for purposes other than debugging. However, one take is that logs may contain a large amount of information which can be used as knowledge bases for multiple and various purposes, including better understanding software execution. To achieve this purpose, specific coding techniques have to be adopted. In this paper, the authors discuss some scenarios in which logs can be used as a window to investigate more details of software execution, list some related Java code, and exhibit some log pieces to demonstrate the usage. They also propose a few ways to manage log files. The idea they suggest here might help improve the software development process.
Article Preview
Top

Since Java has been adopted to implement LAKE, in the section as to related logging tools, we only introduce those tools written with or for Java language. However, our discussions could be easily generalized since other programming languages have similar or comparable logging tools and principles.

There have been a various Java logging frameworks and toolsets (“Log4j,” 2012; “Simple Logging Facade for Java (SLF4J),” 2004; “Java logging framework,” 2013) which are similar in terms of functionality and share some common designs. Logging is logically broken into three major pieces, though a simpler logging framework may combine multiples of them into one: loggers, which provides an interface for application to send log commands, formatters, which, as its name suggests, organize information into designated format, and appenders, which determine where the information is saved. Loggers are often bundled to Java classes and implemented in the thread-safe (Goetz, 2010) manner. Formatters often add timestamp and class names to the message to be logged. Normally a log is written to hard disk. However, it can be inserted into a database or sent out to designated recipients as through emails. Typically, a logging framework gives programmers flexibility to configure what classes they want to log, how the information will look like, how much information they want to log, etc., without modifying and recompiling the source code; only a textual configuration file needs to be edited.

Complete Article List

Search this Journal:
Reset
Volume 12: 1 Issue (2024)
Volume 11: 1 Issue (2023)
Volume 10: 4 Issues (2022): 2 Released, 2 Forthcoming
Volume 9: 4 Issues (2021)
Volume 8: 4 Issues (2020)
Volume 7: 4 Issues (2019)
Volume 6: 4 Issues (2018)
Volume 5: 4 Issues (2017)
Volume 4: 4 Issues (2016)
Volume 3: 4 Issues (2015)
Volume 2: 4 Issues (2014)
Volume 1: 4 Issues (2013)
View Complete Journal Contents Listing