public static Object executeOnInstance(Object object, Method method, Object[] args) {
        Method targetMethod = methodByName(object.getClass(), method.getName());
        if (targetMethod == null) {
            throw new IllegalArgumentException(format(
                    "Signature of method %s is not compatible with the object %s",
                    method.getName(), object.getClass().getSimpleName()));
        }
        try {
            return targetMethod.invoke(object, args);
        } catch (Exception ex) {
            throw new RibbonProxyException(format(
                    "Failed to execute method %s on object %s",
                    method.getName(), object.getClass().getSimpleName()), ex);
        }
    }
A collection of helper methods.

@author Tomasz Bak
ribbon/src/main/java/com/netflix/ribbon/proxy/Utils.java