I am getting an java.lang.OutOfMemoryError and it seems to happen in a point I do reflection:
obj.getClass().getMethod(methodName, (Class[]) null);
What does this indicate? Does anyone know?
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
The code is the same as
It indicates you need to read the Error message carefully as this is highly unlikely to be the cause as it doesn’t creates very little memory.
If it really is the point at which the error occurs, the real cause is likely to be somewhere else. To resolve this you need to memory profile your application, or take a heap dump on OOME or increase the maximum heap size (or all three)