String targetName = invocation.getThis().getClass().getName();
String methodName = invocation.getMethod().getName();
Object[] arguments = invocation.getArguments();
MethodCache annotation = invocation.getMethod().getAnnotation(MethodCache.class);
String cacheKey = getCackeKey(targetName, methodName, arguments,annotation);
int expireSeconds = (int)annotation.timeUnit().toSeconds(annotation.expireTime());
return getResult(cacheKey, invocation,expireSeconds);
} else {
return invocation.proceed();
}
}