-
Notifications
You must be signed in to change notification settings - Fork 2.6k
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
Getting OutOfMemoryError: pthread_create on Android 4, 6, 7 #664
Comments
Hello @Sdghasemi, please use this issue template to help me understand the issue at hand. Are you using wss? Normally we are not spawning a lot of new threads, especially on the client side.... Greetings |
I've read the issue template, I'll provide you as much as info I can so we can spot where the problem is coming from.
As you see, the instances disposed properly in |
Hello @Sdghasemi, you should not read it but use it instead! For example when you started this issue, you did not mention that you are somehow reconnecting the websocket, Without such information I would just have closed this issue with "cannot-reproduce". For me it is not clear what you are doing so such a template is important!! Greetings |
Since this I'm using web socket as a part of a huge codebase, I'm afraid I can not make a simple sample representing the problem to reproduce (I myself couldn't reproduce it either, but there are a number of crashes tell me this is happening). I'm trying to find out where this crashes might get produced, or maybe there is no way the library could cause it! Expected BehaviorThere's a function somewhere creating pool threads repeatedly which shouldn't without proper disposal. Current BehaviorThe threads memory runs out and a crash happens with this stack trace:
Possible SolutionFind out where is coming from, maybe a result of creating instances of Steps to Reproduce (for bugs)A link to the problem: http://crashes.to/s/0915cc05563 Debug log (for bugs)There is no particular debug log, since the bug is not related to the web socket transactions itself. ContextI'm afraid I have no idea, If I had I could reproduce it somehow. Your EnvironmentI have provided everything relevant to the issue in this comment and previous ones. Thanks for your help. |
Hello @Sdghasemi, thank you again for the details especially for the link. Am I understanding the site correctly that there are 476 threads running? Going through this list it looks like you are spawning a lot of pool-threads. Also just for your information, I will be on holiday for a week so don't expect any answers in this time ;) Hope this still helps you! Greetings |
Hello @marci4, |
First of all thanks for the great library.
As I mentioned I'm getting below error on all Android APIs I'm using except 21 and 22 (Android 5):
Also there are about 620 identical threads with below stack along with the crash on Crashlytics:
I was hoping if someone can help me with the issue, thanks in advance.
The text was updated successfully, but these errors were encountered: