apm-sniffer/optional-plugins/optional-spring-plugins/resttemplate-6.x-plugin/src/main/java/org/apache/skywalking/apm/plugin/spring/resttemplate/v6x/sync/RestResponseInterceptor.java [39:50]:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    public Object afterMethod(EnhancedInstance objInst, Method method, Object[] allArguments, Class<?>[] argumentsTypes,
        Object ret) throws Throwable {

        ClientHttpResponse response = (ClientHttpResponse) allArguments[2];
        int statusCode = response.getStatusCode().value();
        AbstractSpan span = ContextManager.activeSpan();
        Tags.HTTP_RESPONSE_STATUS_CODE.set(span, statusCode);
        if (statusCode >= 400) {
            span.errorOccurred();
        }
        return ret;
    }
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -



apm-sniffer/apm-sdk-plugin/spring-plugins/resttemplate-commons/src/main/java/org/apache/skywalking/apm/plugin/spring/resttemplate/sync/RestResponseInterceptor.java [39:50]:
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    public Object afterMethod(EnhancedInstance objInst, Method method, Object[] allArguments, Class<?>[] argumentsTypes,
        Object ret) throws Throwable {

        ClientHttpResponse response = (ClientHttpResponse) allArguments[2];
        int statusCode = response.getStatusCode().value();
        AbstractSpan span = ContextManager.activeSpan();
        Tags.HTTP_RESPONSE_STATUS_CODE.set(span, statusCode);
        if (statusCode >= 400) {
            span.errorOccurred();
        }
        return ret;
    }
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -



