Merge pull request #458 from ascrutae/zhangxin/fix/spring-operationName-failed

fix issue that the span  operation name of spring mvc is null
This commit is contained in:
吴晟 Wu Sheng 2017-09-25 16:28:58 +08:00 committed by GitHub
commit 928e782d43
1 changed files with 2 additions and 0 deletions

View File

@ -30,6 +30,8 @@ public class ControllerServiceMethodInterceptor implements InstanceMethodsAround
RequestMapping methodRequestMapping = method.getAnnotation(RequestMapping.class);
if (methodRequestMapping.value().length > 0) {
requestURL = methodRequestMapping.value()[0];
} else if (methodRequestMapping.path().length > 0) {
requestURL = methodRequestMapping.path()[0];
} else {
requestURL = "";
}