Don't Reinvent the Wheel: Towards Automatic Replacement of Custom Implementations with APIs

Autor: Tufano, Rosalia, Aghajani, Emad, Bavota, Gabriele
Rok vydání: 2022
Předmět:
Druh dokumentu: Working Paper
Popis: Reusing code is a common practice in software development: It helps developers speedup the implementation task while also reducing the chances of introducing bugs, given the assumption that the reused code has been tested, possibly in production. Despite these benefits, opportunities for reuse are not always in plain sight and, thus, developers may miss them. We present our preliminary steps in building RETIWA, a recommender able to automatically identify custom implementations in a given project that are good candidates to be replaced by open source APIs. RETIWA relies on a ``knowledge base'' consisting of real examples of custom implementation-to-API replacements. In this work, we present the mining strategy we tailored to automatically and reliably extract replacements of custom implementations with APIs from open source projects. This is the first step towards building the envisioned recommender.
Databáze: arXiv