What code implements such service? a behavior model based feature location approach
Abstract
Enterprises today are keen to unlock new business values of their legacy services towards new trends (e.g., cloud and mobile). To accelerate such process, automatic feature location techniques can enable developers to rapidly locate/understand implementations of certain services (e.g., services to expose, transform or improve). Existing feature location techniques [1-3, 5-10, 32] provide a good foundation but have several key limitations: limited leverage of description sources, less considerations of internal behaviors, and ineffectiveness for the identification of service-relevant code entries. To address these limitations, we propose a behavior model based feature location approach and implement a tool named BMLocator. In the offline phase, BMLocator applies Natural Language Processing (NLP) techniques and static code analysis to extract & behavior models & of code units via considering multiple information sources. While in the online phase, given a service description, BMLocator first extracts its behavior model and then recommends service-relevant code units/entries by matching its behavior model with code units under analysis. Through evaluations with public service requests of open-source projects (e.g., Tomcat and Hadoop), we show that the approach is more effective in recommending service-relevant code entries (e.g., most of entries are prioritized as the first ones) than existing techniques (i.e., TopicXP[37], CVSSearch[6]).