A Mixed-method Approach to Recommend Corrections and Correct REST Antipatterns Revision for Supplemental Material
Many companies, e.g., Facebook and YouTube, use the REST architecture and provide REST APIs to their clients. Likeany other software systems, REST APIs need maintenance and must evolve to improve and stay relevant. Antipatterns—poor designpractices—hinder this maintenance and evolution. Although the literature defines many antipatterns and proposes approaches for their(automatic) detection, theircorrectiondid not receive much attention. Therefore,we apply a mixed-method approach to study RESTAPIs and REST antipatterns with the objectives to recommend corrections or, when possible, actually correct the RESTantipatterns.Qualitatively, via case studies, we analyse the evolution of 11 REST APIs, including Facebook, Twitter, and YouTube,over six years. We detect occurrences of eight REST antipatterns in the years 2014, 2017, and 2020 in 17 versions of 11 REST APIs.Thus, we show that (1) REST APIs and antipatterns evolve over time and (2) developers seem to remove antipatterns. Qualitatively via a discourse analysis, we analyse developers’ forums and report that developers are concerned with the occurrences of REST antipatternsand discuss corrections to these antipatterns. Following these qualitative studies, using anengineering-research approach, we proposethe following novel and unique contributions: (1) we describe and compare the corrections of eight REST antipatterns from the academicliterature and from developers’ forums; (2) we devise and describe algorithms to recommend corrections to some of these antipatterns;(3) we present algorithms and a tool to correct some of these antipatterns by intercepting and modifying responses from REST APIs;and, (4) we validate the recommendations and the corrections manually and via a survey answered by 24 REST developers.Thus, wepropose to REST API developers and researchers the first, grounded approach to correct REST antipatterns
Thank you for your interest in our work. We organised the data as follows:
- APs Detection and Traces by SODA-R contains (1) folders with the URIs and the results of the detection of the antipatterns on these URIs and (2) folders with the traces obtained from the URIs. Each folder further divides into as many folders as REST APIs. This data is used throughout the paper.
- StackOverflow Analysis contains the data obtained from StackOverflow pertaining to REST antipatterns and our analysis of the questions and answers in this data. This data is used mostly in Section 3.4.
- APs Corrections by SOCAR contains the results of applying our recommendation/correction approach to the URIs in “1. APs Detection and Traces by SODA-R” above. This data is used from Section 4 onwards.
- Validation Survey and Its Results contains the survey and the participants’ anonymous answers. This data is used mostly in Section 6.
The folder also contains the SOCAR Tool itself (source code and bytecode).
- 1. APs Detection and Traces by SODA-R-20210917T154527Z-001.zip (3.46 MB)
- 2. StackOverflow Analysis-20210917T154549Z-001.zip (147.06 kB)
- 3. APs Corrections by SOCAR-20210917T154600Z-001.zip (1.37 MB)
- 4. Validation Survey and Its Results-20210917T154620Z-001.zip (277.10 kB)