Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

2.2.14 版本, FallbackFactory 不生效. #167

Closed
java001 opened this issue Dec 15, 2023 · 6 comments
Closed

2.2.14 版本, FallbackFactory 不生效. #167

java001 opened this issue Dec 15, 2023 · 6 comments

Comments

@java001
Copy link

java001 commented Dec 15, 2023

不生效的原因是因为: RetrofitInvocationHandler 里面抛的异常不是: RetrofitBlockException.
image

升级版本后, RetrofitClient 的接口无法扫描到, 导致注入不进来.

@chentianming11
Copy link
Collaborator

不是RetrofitBlockException ,说明不是熔断导致的异常,因此不能走熔断逻辑。

@chentianming11
Copy link
Collaborator

升级到哪个版本注入不了?

@java001
Copy link
Author

java001 commented Dec 21, 2023

2.3.14注入不了, 我用spring的扫描和RetrofitScan都试过了, 还是提示报错, 不知道是不是扫描多次会失效, 或者是顺序的问题.

@java001
Copy link
Author

java001 commented Dec 21, 2023

那不是熔断的异常, 要怎么统一处理? 我想统计接口的异常数量.

@chentianming11
Copy link
Collaborator

可以自行实现一个拦截器统计

@java001
Copy link
Author

java001 commented Mar 21, 2024

继承 BaseGlobalInterceptor , try了存库里面了.

@java001 java001 closed this as completed Mar 21, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants