-
Notifications
You must be signed in to change notification settings - Fork 38.3k
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
Metaspace out of memory when combining AOP and prototype #29967
Comments
@ZhangChee @rstoyanchev @sbrannen could you assign this to me if it's still open? |
This case still exists. I've tried to find out why this happened. Maybe this is the hint. The solution maybe: Every prototype instance shares the same cglib class instance ( Maybe we need relation cache between cglib class instance and corresponding Bean Class with @component and @scope=SCOPE_PROTOTYPE ? ) I've no authrization to reassign. Let's waiting... T T |
@ZhangChee @backslideZhang |
I m facing this issue as well, Any workaround for this till it get fixed ? @vishalsingh2972 , Can you point me to a workaround if you found one? |
@ZhangChee , have you found any workaround/ |
@ArvindAbi |
Everyone, the creation of a new bean using the prototype scope should not lead to the creation of a new CGLIB class. If that happens, something unexpected happened that we need to debug. In order to do that, please share a small sample that we can run ourselves with instructions to trigger the problem. You can attach a zip to this issue or push the code to a separate GitHub repository. Thank you! |
If you would like us to look at this issue, please provide the requested information. If the information is not provided within the next 7 days this issue will be closed. |
Closing due to lack of requested feedback. If you would like us to look at this issue, please provide the requested information and we will re-open the issue. |
Spring Boot version: 2.3.12.RELEASE, 2.7.8
I've tried to apply AOP ( cglib ) on prototype Bean. Since cglib generates new class every time, metaspace hit OOM at the end.
Below is my code for AOP and prototype Bean:
Below is my Runner
I've referred to this PR, but it seems not work:
The text was updated successfully, but these errors were encountered: