Search in sources :

Example 1 with ReflectiveOperationInvoker

use of org.springframework.boot.actuate.endpoint.invoke.reflect.ReflectiveOperationInvoker in project spring-boot by spring-projects.

the class DiscoveredOperationsFactory method createOperation.

private O createOperation(EndpointId endpointId, Object target, Method method, OperationType operationType, Class<? extends Annotation> annotationType) {
    MergedAnnotation<?> annotation = MergedAnnotations.from(method).get(annotationType);
    if (!annotation.isPresent()) {
        return null;
    }
    DiscoveredOperationMethod operationMethod = new DiscoveredOperationMethod(method, operationType, annotation.asAnnotationAttributes());
    OperationInvoker invoker = new ReflectiveOperationInvoker(target, operationMethod, this.parameterValueMapper);
    invoker = applyAdvisors(endpointId, operationMethod, invoker);
    return createOperation(endpointId, operationMethod, invoker);
}
Also used : ReflectiveOperationInvoker(org.springframework.boot.actuate.endpoint.invoke.reflect.ReflectiveOperationInvoker) OperationInvoker(org.springframework.boot.actuate.endpoint.invoke.OperationInvoker) ReflectiveOperationInvoker(org.springframework.boot.actuate.endpoint.invoke.reflect.ReflectiveOperationInvoker)

Aggregations

OperationInvoker (org.springframework.boot.actuate.endpoint.invoke.OperationInvoker)1 ReflectiveOperationInvoker (org.springframework.boot.actuate.endpoint.invoke.reflect.ReflectiveOperationInvoker)1