I want to write a aop to grpc interface method, how can i get generic type from StreamObserver
@Around(value = "execution(* com.test.grpc.controller.*.*(..))")
public void around(ProceedingJoinPoint point) throws Throwable {
long methodStartTime = System.currentTimeMillis();
String methodName = point.getSignature().getDeclaringTypeName() +
"." + point.getSignature().getName();
point.proceed();
}
You can't, since it is generic.
I don't know enough about aop to provide alternatives.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.