Joanna C. S. Santos, Sara Moshtari, Mehdi Mirakhorli
{"title":"An Automated Approach to Recover the Use-case View of an Architecture","authors":"Joanna C. S. Santos, Sara Moshtari, Mehdi Mirakhorli","doi":"10.1109/ICSA-C50368.2020.00020","DOIUrl":null,"url":null,"abstract":"Many tools and techniques were described in the literature for automated recovery of software architecture from software artifacts, such as code. These approaches generate models of software architecture at different levels of granularity and notations. Whereas there is a vast literature in recovering components, packages, and interactions between them, we lack automated approaches for recovering the use-case view of an architecture. In the 4+1 view of the architecture, use-case view or scenarios represents a view of the architecture in terms of the systems’ core functionalities provided to end-users. This view is essential in understanding the system and its underlying architectural decisions. Manually recovering and documenting the application’s scenarios from source code is time-consuming, as large-scale enterprise systems can have a large number of scenarios. In this NEMI paper, we present a novel automated approach for recovering the scenarios from Web applications source code. These scenarios are shown in use case diagrams alongside with sequence diagrams that further describe how each use case is implemented in the system. Our approach works under the assumption that the URLs (endpoints) of a Web application can give us clues to the system’s use cases. Therefore, our technique combines a set of heuristics and static analysis in order to detect the endpoints in a Java Web application as well as the backend classes and methods that will process the request. Subsequently, it uses Natural Language Processing (NLP) techniques to extract use cases from these identified endpoints and uses the computed program slices to generate sequence diagrams for each identified use case. We conducted an initial evaluation of our approach by detecting endpoints in Sagan, an existing open-source Web application. We then demonstrate the use cases generated and how their implementation looks like through sequence diagrams.","PeriodicalId":202587,"journal":{"name":"2020 IEEE International Conference on Software Architecture Companion (ICSA-C)","volume":"33 1","pages":"0"},"PeriodicalIF":0.0000,"publicationDate":"2020-03-01","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":"0","resultStr":null,"platform":"Semanticscholar","paperid":null,"PeriodicalName":"2020 IEEE International Conference on Software Architecture Companion (ICSA-C)","FirstCategoryId":"1085","ListUrlMain":"https://doi.org/10.1109/ICSA-C50368.2020.00020","RegionNum":0,"RegionCategory":null,"ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":null,"EPubDate":"","PubModel":"","JCR":"","JCRName":"","Score":null,"Total":0}
引用次数: 0
Abstract
Many tools and techniques were described in the literature for automated recovery of software architecture from software artifacts, such as code. These approaches generate models of software architecture at different levels of granularity and notations. Whereas there is a vast literature in recovering components, packages, and interactions between them, we lack automated approaches for recovering the use-case view of an architecture. In the 4+1 view of the architecture, use-case view or scenarios represents a view of the architecture in terms of the systems’ core functionalities provided to end-users. This view is essential in understanding the system and its underlying architectural decisions. Manually recovering and documenting the application’s scenarios from source code is time-consuming, as large-scale enterprise systems can have a large number of scenarios. In this NEMI paper, we present a novel automated approach for recovering the scenarios from Web applications source code. These scenarios are shown in use case diagrams alongside with sequence diagrams that further describe how each use case is implemented in the system. Our approach works under the assumption that the URLs (endpoints) of a Web application can give us clues to the system’s use cases. Therefore, our technique combines a set of heuristics and static analysis in order to detect the endpoints in a Java Web application as well as the backend classes and methods that will process the request. Subsequently, it uses Natural Language Processing (NLP) techniques to extract use cases from these identified endpoints and uses the computed program slices to generate sequence diagrams for each identified use case. We conducted an initial evaluation of our approach by detecting endpoints in Sagan, an existing open-source Web application. We then demonstrate the use cases generated and how their implementation looks like through sequence diagrams.