Purpose
Many REpresentational State Transfer (RESTful) Web services suffered from anti-patterns problem, which may diminish the sustainability of the services. The anti-patterns problem could happen in the code of the programme or the uniform resource identifiers (URIs) of RESTful Web services. This study aims to address the problem by proposing a technique and an algorithm for detecting anti-patterns in RESTful Web services. Specifically, the technique is designed based on URIs parsing process.
Design/methodology/approach
The study was conducted following the design science research process, which has six activities, namely, identifying problems, identifying solutions, design the solutions, demonstrate the solution, evaluation and communicate the solution. The proposed technique was embedded in an algorithm and evaluated in four phases covering the process of extracting the URIs, implementing the anti-pattern detection algorithm, detecting the anti-patterns and validating the results.
Findings
The results of the study suggested an acceptable level of accuracy for the anti-patterns detection with 82.30% of precision, 87.86% of recall and 84.93% of F-measure.
Practical implications
The technique and the algorithm can be used by developers of RESTful Web services to detect possible anti-pattern occurrences in the service-based systems.
Originality/value
The technique is personalised to detect amorphous URI and ambiguous name anti-patterns in which it scans the Web service URIs using specified rules and compares them with pre-determined syntax and corpus.