Ekaterina Blech, A. Grishchenko, Ivan Kniazkov, Guangtai Liang, Oleg Serebrennikov, A. Tatarnikov, Polina Volkhontseva, Kuzma Yakimets
{"title":"Patternika: A Pattern-Mining-Based Tool For Automatic Library Migration","authors":"Ekaterina Blech, A. Grishchenko, Ivan Kniazkov, Guangtai Liang, Oleg Serebrennikov, A. Tatarnikov, Polina Volkhontseva, Kuzma Yakimets","doi":"10.1109/ISSREW53611.2021.00098","DOIUrl":null,"url":null,"abstract":"Modern software projects typically include a number of third-party libraries. Library migrations (e.g., upgrade/ downgrade/replace some libraries with others) happen frequently due to license violations, known vulnerabilities, feature enhancements and so on, which is laborious and error-prone since that such tasks usually require developers to manually identify mappings between the libraries and then manually change the code. To address this problem, we propose and implement a pattern-mining based tool named Patternika which can help automate such activities. The key idea of the approach is to mine migration patterns from historical migration instances via static code differencing technique upon Abstract Syntax Tree (AST) structures and anti-unification technique upon code differencing graphs, and then apply these patterns to help automatically migrate libraries for future projects (i.e., find and patch source code fragments that contain API references to libraries to be migrated). With experimental evaluations on open data, the pattern mining algorithm provided by Patternika is demonstrated to be fully effective for commercial use. Patternika is now already integrated into an IDE plugin and can be freely downloaded and used by ninety thousands of internal developers intra an IT giant company.","PeriodicalId":385392,"journal":{"name":"2021 IEEE International Symposium on Software Reliability Engineering Workshops (ISSREW)","volume":"47 1","pages":"0"},"PeriodicalIF":0.0000,"publicationDate":"2021-10-01","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":"1","resultStr":null,"platform":"Semanticscholar","paperid":null,"PeriodicalName":"2021 IEEE International Symposium on Software Reliability Engineering Workshops (ISSREW)","FirstCategoryId":"1085","ListUrlMain":"https://doi.org/10.1109/ISSREW53611.2021.00098","RegionNum":0,"RegionCategory":null,"ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":null,"EPubDate":"","PubModel":"","JCR":"","JCRName":"","Score":null,"Total":0}
引用次数: 1
Abstract
Modern software projects typically include a number of third-party libraries. Library migrations (e.g., upgrade/ downgrade/replace some libraries with others) happen frequently due to license violations, known vulnerabilities, feature enhancements and so on, which is laborious and error-prone since that such tasks usually require developers to manually identify mappings between the libraries and then manually change the code. To address this problem, we propose and implement a pattern-mining based tool named Patternika which can help automate such activities. The key idea of the approach is to mine migration patterns from historical migration instances via static code differencing technique upon Abstract Syntax Tree (AST) structures and anti-unification technique upon code differencing graphs, and then apply these patterns to help automatically migrate libraries for future projects (i.e., find and patch source code fragments that contain API references to libraries to be migrated). With experimental evaluations on open data, the pattern mining algorithm provided by Patternika is demonstrated to be fully effective for commercial use. Patternika is now already integrated into an IDE plugin and can be freely downloaded and used by ninety thousands of internal developers intra an IT giant company.