An Approach to Recommendation of Verbosity Log Levels Based on Logging Intention

H. Anu, Jie Chen, Wenchang Shi, Jianwei Hou, Bin Liang, Bo Qin
{"title":"An Approach to Recommendation of Verbosity Log Levels Based on Logging Intention","authors":"H. Anu, Jie Chen, Wenchang Shi, Jianwei Hou, Bin Liang, Bo Qin","doi":"10.1109/ICSME.2019.00022","DOIUrl":null,"url":null,"abstract":"Verbosity levels of logs are designed to discriminate highly diverse runtime events, which facilitates system failure identification through simple keyword search (e.g., fatal, error). Verbosity levels should be properly assigned to logging statements, as inappropriate verbosity levels would confuse users and cause a lot of redundant maintenance effort. However, to achieve such a goal is not an easy task due to the lack of practical specifications and guidelines towards verbosity log level usages. The existing research has built a classification model on log related quantitative metrics such as log density to improve logging level practice. Though such quantitative metrics can reveal logging characteristics, their contributions on logging level decision are limited, since valuable logging intention information buried in logging code context can not be captured. In this paper, we propose an automatic approach to help developers determine the appropriate verbosity log levels. More specially, our approach discriminates different verbosity log level usages based on code context features that contain underlying logging intention. To validate our approach, we implement a prototype tool, VerbosityLevelDirector, and perform a case study to measure its effectiveness on four well-known open source software projects. Evaluation results show that VerbosityLevelDirector achieves high performance on verbosity level discrimination and outperforms the baseline approaches on all those projects. Furthermore, through applying noise handling technique, our approach can detect previously unknown inappropriate verbosity level configurations in the code repository. We have reported 21 representative logging level errors with modification advice to issue tracking platforms of the examined software projects and received positive feedback from their developers. The above results confirm that our work can help developers make a better logging level decision in real-world engineering.","PeriodicalId":106748,"journal":{"name":"2019 IEEE International Conference on Software Maintenance and Evolution (ICSME)","volume":null,"pages":null},"PeriodicalIF":0.0000,"publicationDate":"2019-09-01","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":"17","resultStr":null,"platform":"Semanticscholar","paperid":null,"PeriodicalName":"2019 IEEE International Conference on Software Maintenance and Evolution (ICSME)","FirstCategoryId":"1085","ListUrlMain":"https://doi.org/10.1109/ICSME.2019.00022","RegionNum":0,"RegionCategory":null,"ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":null,"EPubDate":"","PubModel":"","JCR":"","JCRName":"","Score":null,"Total":0}
引用次数: 17

Abstract

Verbosity levels of logs are designed to discriminate highly diverse runtime events, which facilitates system failure identification through simple keyword search (e.g., fatal, error). Verbosity levels should be properly assigned to logging statements, as inappropriate verbosity levels would confuse users and cause a lot of redundant maintenance effort. However, to achieve such a goal is not an easy task due to the lack of practical specifications and guidelines towards verbosity log level usages. The existing research has built a classification model on log related quantitative metrics such as log density to improve logging level practice. Though such quantitative metrics can reveal logging characteristics, their contributions on logging level decision are limited, since valuable logging intention information buried in logging code context can not be captured. In this paper, we propose an automatic approach to help developers determine the appropriate verbosity log levels. More specially, our approach discriminates different verbosity log level usages based on code context features that contain underlying logging intention. To validate our approach, we implement a prototype tool, VerbosityLevelDirector, and perform a case study to measure its effectiveness on four well-known open source software projects. Evaluation results show that VerbosityLevelDirector achieves high performance on verbosity level discrimination and outperforms the baseline approaches on all those projects. Furthermore, through applying noise handling technique, our approach can detect previously unknown inappropriate verbosity level configurations in the code repository. We have reported 21 representative logging level errors with modification advice to issue tracking platforms of the examined software projects and received positive feedback from their developers. The above results confirm that our work can help developers make a better logging level decision in real-world engineering.
查看原文
分享 分享
微信好友 朋友圈 QQ好友 复制链接
本刊更多论文
基于日志意图的详细日志级别推荐方法
日志的详细程度被设计为区分高度不同的运行时事件,这有助于通过简单的关键字搜索(例如,fatal, error)来识别系统故障。应该适当地为日志语句分配详细级别,因为不适当的详细级别会使用户感到困惑,并导致大量冗余的维护工作。然而,要实现这样的目标并不是一件容易的事情,因为缺乏针对冗长日志级别用法的实用规范和指导方针。已有研究建立了测井密度等测井相关定量指标的分类模型,以提高测井水平的实践水平。虽然这些量化指标可以揭示日志特征,但它们对日志级别决策的贡献有限,因为无法捕获隐藏在日志代码上下文中的有价值的日志意图信息。在本文中,我们提出了一种自动方法来帮助开发人员确定适当的冗长日志级别。更具体地说,我们的方法基于包含底层日志记录意图的代码上下文特性来区分不同的冗长日志级别用法。为了验证我们的方法,我们实现了一个原型工具,VerbosityLevelDirector,并执行了一个案例研究来衡量它在四个知名开源软件项目上的有效性。评估结果表明,VerbosityLevelDirector在冗长级别识别方面取得了优异的成绩,并且在所有这些项目上都优于基线方法。此外,通过应用噪声处理技术,我们的方法可以检测代码存储库中以前未知的不适当的冗长级别配置。我们已经向审查软件项目的发行跟踪平台报告了21个具有代表性的日志级别错误和修改建议,并收到了开发人员的积极反馈。以上结果证实,我们的工作可以帮助开发人员在实际工程中做出更好的日志级别决策。
本文章由计算机程序翻译,如有差异,请以英文原文为准。
求助全文
约1分钟内获得全文 去求助
来源期刊
自引率
0.00%
发文量
0
期刊最新文献
Same App, Different Countries: A Preliminary User Reviews Study on Most Downloaded iOS Apps Towards Better Understanding Developer Perception of Refactoring Decomposing God Classes at Siemens Self-Admitted Technical Debt Removal and Refactoring Actions: Co-Occurrence or More? A Validation Method of Self-Adaptive Strategy Based on POMDP
×
引用
GB/T 7714-2015
复制
MLA
复制
APA
复制
导出至
BibTeX EndNote RefMan NoteFirst NoteExpress
×
×
提示
您的信息不完整,为了账户安全,请先补充。
现在去补充
×
提示
您因"违规操作"
具体请查看互助需知
我知道了
×
提示
现在去查看 取消
×
提示
确定
0
微信
客服QQ
Book学术公众号 扫码关注我们
反馈
×
意见反馈
请填写您的意见或建议
请填写您的手机或邮箱
已复制链接
已复制链接
快去分享给好友吧!
我知道了
×
扫码分享
扫码分享
Book学术官方微信
Book学术文献互助
Book学术文献互助群
群 号:481959085
Book学术
文献互助 智能选刊 最新文献 互助须知 联系我们:info@booksci.cn
Book学术提供免费学术资源搜索服务,方便国内外学者检索中英文文献。致力于提供最便捷和优质的服务体验。
Copyright © 2023 Book学术 All rights reserved.
ghs 京公网安备 11010802042870号 京ICP备2023020795号-1