Login | Register

Formalising Solutions to REST API Practices as Design (Anti)patterns


Formalising Solutions to REST API Practices as Design (Anti)patterns

Van Tuan, Tran ORCID: https://orcid.org/0000-0002-4234-9038 (2021) Formalising Solutions to REST API Practices as Design (Anti)patterns. Masters thesis, Concordia University.

[thumbnail of Tran_MCompSc_F2021.pdf]
Text (application/pdf)
Tran_MCompSc_F2021.pdf - Accepted Version
Available under License Spectrum Terms of Access.


REST APIs are nowadays the de-facto standard for Web applications. However, as more systems and services adopt the REST architectural style, many problems arise regularly. To avoid these repetitive problems, developers should follow good practices and avoid bad ones. Thus, research on best and bad practices and how to design simple but effective REST APIs is important. Yet, to the best of our knowledge, only a few recurring REST API practices have been codified in the form of design (anti)patterns, which include a name, an intent, a context, and some solutions. There are works on defining or detecting some practices, but not on codifying these practices as patterns. In this thesis, we present the most up-to-date list of REST API practices and formalise them in the form of design (anti)patterns to ease their use by developers. During this formalisation, we also devise and formalise solutions to these practices. Finally, we validate our design (anti)patterns with a survey and interviews of 55 developers, which confirm that our solutions are acceptable by practitioners and reflect real problems and solutions.

Divisions:Concordia University > Gina Cody School of Engineering and Computer Science > Computer Science and Software Engineering
Item Type:Thesis (Masters)
Authors:Van Tuan, Tran
Institution:Concordia University
Degree Name:M. Comp. Sc.
Program:Computer Science
Date:10 August 2021
Thesis Supervisor(s):Guéhéneuc, Yann-Gaël
Keywords:REST API patterns
ID Code:988869
Deposited By: Van Tuan Tran
Deposited On:29 Nov 2021 16:36
Last Modified:29 Nov 2021 16:36
Related URLs:


Birman, K., & Joseph, T. (1987). Exploiting virtual synchrony in distributed systems. In Proceedings of the eleventh ACM Symposium on Operating systems principles (pp. 123–138).

Butler, M. (2001). Implementing content negotiation using CC/PP and WAP UAProf. HP Laboratories Technical Report HPL, 2001(190).

cPanel. (2020). Redirects. https://docs.cpanel.net/cpanel/domains/redirects/.

John Evdemon. (2016). Principles of Service Design: Service Patterns and Anti-Patterns. http://web.archive.org/web/20160807191653/https://msdn.microsoft.com/en-us/library/ms954638.aspx.

Dai, T., He, J., Gu, X., & Lu, S. (2018). Understanding real-world timeout problems in cloud server systems. In 2018 IEEE International Conference on Cloud Engineering (IC2E) (pp. 1–11).

del-boy. (2010). RESTful API. Should I be returning the object that was created / updated?. https://stackoverflow.com/a/1829913/4506315.

Deutskens, E., De Ruyter, K., Wetzels, M., & Oosterveld, P. (2004). Response rate and response quality of internet-based surveys: an experimental study. Marketing letters, 15(1), 21–36.

Ellis, B., Stylos, J., & Myers, B. (2007). The factory pattern in API design: A usability evaluation. In 29th International Conference on Software Engineering (ICSE'07) (pp. 302–312).

Fowler, M.. Richardson Maturity Model. http://martinfowler.com/articles/richardsonMaturityModel.html.

Fowler, M. (2012). Patterns of Enterprise Application Architecture: Pattern Enterpr Applica Arch. Addison-Wesley.

Fredrich, T. (2012). Restful service best practices. Recommendations for Creating Web Services, 1–34.

Gamma, E., Helm, R., Johnson, R., & Vlissides, J. (1993). Design patterns: Abstraction and reuse of object-oriented design. In European Conference on Object-Oriented Programming (pp. 406–431).

Google. Common Design Patterns. https://cloud.google.com/apis/design/design_patterns.

Ruslan Yakushev. (2008). Using the URL Rewrite Module. https://docs.microsoft.com/en-us/iis/extensions/url-rewrite-module/using-the-url-rewrite-module.

iswinky. (2016). RESTful API. Should I be returning the object that was created / updated?. https://softwareengineering.stackexchange.com/q/314066/243384.

Iyer, S., Rowstron, A., & Druschel, P. (2002). Squirrel: A decentralized peer-to-peer web cache. In Proceedings of the twenty-first annual symposium on Principles of distributed computing (pp. 213–222).

Kaminski, P., Litoiu, M., & Müller, H. (2006). A design technique for evolving web services. In Proceedings of the 2006 conference of the Center for Advanced Studies on Collaborative research (pp. 23–es).

Kohlhoff, C., & Steele, R. (2003). Evaluating SOAP for high performance business applications: Real-time trading systems. In International World Wide Web Conference.

Lalanda, P. (1998). Shared repository pattern. In Proc. 5th Annual Conference on the Pattern Languages of Programs.

Landis, J., & Koch, G. (1977). The measurement of observer agreement for categorical data. biometrics, 159–174.

Leitner, P., Michlmayr, A., Rosenberg, F., & Dustdar, S. (2008). End-to-end versioning support for web services. In 2008 IEEE International Conference on Services Computing (pp. 59–66).

Lemlouma, T., & Laya\"\ida, N. (2001). Nac: A basic core for the adaptation and negotiation of multimedia services. Opera Project, INRIA.

Li, J., Xiong, Y., Liu, X., & Zhang, L. (2013). How does web service API evolution affect clients?. In 2013 IEEE 20th International Conference on Web Services (pp. 300–307).

Liskin, O., Singer, L., & Schneider, K. (2011). Teaching old services new tricks: adding HATEOAS support as an afterthought. In Proceedings of the Second International Workshop on RESTful Design (pp. 3–10).

Lublinsky, B.. (2009). Versioning in SOA. https://docs.microsoft.com/en-us/previous-versions/bb491124(v=msdn.10).

Martin, R. (2002). Agile software development: principles, patterns, and practices. Prentice Hall.

Martin, R., Grenning, J., & Brown, S. (2018). Clean architecture: a craftsman's guide to software structure and design. Prentice Hall.

Masse, M. (2011). REST API Design Rulebook: Designing Consistent RESTful Web Service Interfaces. O'Reilly Media, Inc..

Masashi Narumoto. Caching. https://docs.microsoft.com/en-us/azure/architecture/best-practices/caching.

John Luo, Anderson, R., & Smith, S.. (2019). Response caching in ASP.NET Core. https://docs.microsoft.com/en-us/aspnet/core/performance/caching/response?view=aspnetcore-5.0.

Microsoft. (2016). https://git.io/JGRwC.

Murphy, L., Alliyu, T., Macvean, A., Kery, M., & Myers, B. (2017). Preliminary Analysis of REST API Style Guidelines. Ann Arbor, 1001, 48109.

NGINX. Converting rewrite rules. http://nginx.org/en/docs/http/converting_rewrite_rules.html.

Nurseitov, N., Paulson, M., Reynolds, R., & Izurieta, C. (2009). Comparison of JSON and XML data interchange formats: a case study.. Caine, 9, 157–162.

Andreas Paepcke (1993). Object-oriented programming: the CLOS perspective. MIT Press.

Palma, F., Dubois, J., Moha, N., & Guéhéneuc, Y.G. (2014). Detection of REST patterns and antipatterns: a heuristics-based approach. In International Conference on Service-Oriented Computing (pp. 230–244).

Palma, F., Gonzalez-Huerta, J., Founi, M., Moha, N., Tremblay, G., & Guéhéneuc, Y.G. (2017). Semantic analysis of restful apis for the detection of linguistic patterns and antipatterns. International Journal of Cooperative Information Systems, 26(02), 1742001.

Petrillo, F., Merle, P., Moha, N., & Guéhéneuc, Y.G. (2016). Are REST APIs for cloud computing well-designed? An exploratory study. In International Conference on Service-Oriented Computing (pp. 157–170).

Rabinovich, M., & Spatscheck, O. (2002). Web caching and replication. (Vol. 67) Addison-Wesley Boston, USA.

Ralph, P., Baltes, S., Bianculli, D., Dittrich, Y., Felderer, M., Feldt, R., Filieri, A., Furia, C., Graziotin, D., He, P., & others (2020). ACM SIGSOFT empirical standards. ACM SIGSOFT.

Stefan Tilkov. (2008). REST Anti-Patterns. https://www.infoq.com/articles/rest-anti-patterns/.

Rodriguez, J., Crasso, M., Zunino, A., & Campo, M. (2010). Automatically detecting opportunities for web service descriptions improvement. In Conference on e-Business, e-Services and e-Society (pp. 139–150).

Rodr\'\iguez, C., Baez, M., Daniel, F., Casati, F., Trabucco, J., Canali, L., & Percannella, G. (2016). REST APIs: a large-scale analysis of compliance with principles and best practices. In International conference on web engineering (pp. 21–39).

Apache. (2021). The rewrite Valve. https://tomcat.apache.org/tomcat-10.0-doc/rewrite.html.

Turnquist, G.. (2013). https://spring.io/guides/gs/caching/.

Vukovic, M., Laredo, J., Muthusamy, V., Slominski, A., Vaculin, R., Tan, W., Naik, V., Silva-Lepe, I., Kumar, A., Srivastava, B., & others (2016). Riding and thriving on the API hype cycle. Communications of the ACM, 59(3), 35–37.

Wessels, D. (2001). Web caching. O'Reilly Media, Inc..

William Eastbury. (2019). Asynchronous Request-Reply pattern. https://docs.microsoft.com/en-us/azure/architecture/patterns/async-request-reply.

Schreibmann, V., & Braun, P. (2015). Model-driven Development of RESTful APIs.. In WEBIST (pp. 5–14).
All items in Spectrum are protected by copyright, with all rights reserved. The use of items is governed by Spectrum's terms of access.

Repository Staff Only: item control page

Downloads per month over past year

Research related to the current document (at the CORE website)
- Research related to the current document (at the CORE website)
Back to top Back to top