-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
java.lang.InternalError: Thread starting during runtime shutdown #136
Comments
I'm experiencing the same issue only on ART runtime (not Dalvik) with ACRA 4.50. Here is a full, not obfuscated stack trace: |
I see that source of the problem is that starting some new thread (invoked indirectly by obtaining an instance of HttpClient from background thread of SendWorker) occurs too late. So one of the solutions is to create HttpClient instance earlier. |
I am facing the same problem with ART runtime. @koral-- thanks for the quick fix, but is there a proper fix in the works. Also when it is expected to be fixed and part of built jar. To me support of ART seems important as Google wants to replace Dalvik with it in the future. |
The new Android Runtime, default as of Android 5.0, does not allow spawning of threads during shutdown, and doing so raises an exception: java.lang.InternalError: Thread starting during runtime shutdown For reasons I don't fully understand, it appears the the shutdown begins before ACRA even re-raises the exception. So the fact that ACRA waits on the SendWorker is insufficient to prevent this issue from occurring. For example, see issue ACRA#136, which in theory should not occur. This option allows ACRA to be configured to terminate immediately after persisting the report to disk. The report is then sent (per usual) when the application is restarted.
ACRA/acra@4d15be3 This fixes an issue that became apparent after adding our extra crash handler. Two crash logs were being created, where the second was caused by a bug in ACRA. The bug is described here: ACRA/acra#136 and resolved here: ACRA/acra#165
it occur again.
|
Not from ACRA-4.6.0+ it didn't because ACRA no longer uses ThreadSafeClientConnManager. |
Can you tell me what the problem led to this? it's very important to me. |
Your problem is coming from |
The problem exists in acra4.7, Android 5.1.1. Device D5803.
|
Please re-open this, same crash: Acra 4.7 Mutliple times seen on Android 5.0:
|
It is not the same crash as the original issue. |
I'm getting users reporting the following error via the Play Store reporting:
at java.lang.Thread.nativeCreate(Native Method)
at java.lang.Thread.start(Thread.java:1042)
at org.apache.http.impl.conn.tsccm.AbstractConnPool.enableConnectionGC(AbstractConnPool.java:140)
at org.apache.http.impl.conn.tsccm.ThreadSafeClientConnManager.createConnectionPool(ThreadSafeClientConnManager.java:120)
at org.apache.http.impl.conn.tsccm.ThreadSafeClientConnManager.(ThreadSafeClientConnManager.java:98)
at org.acra.e.c.a(HttpRequest.java:214)
at org.acra.e.c.a(HttpRequest.java:141)
at org.acra.sender.HttpSender.a(HttpSender.java:225)
at org.acra.g.a(SendWorker.java:179)
at org.acra.g.a(SendWorker.java:141)
at org.acra.g.run(SendWorker.java:77)
Since it's from users, I can't really know at what point this is occurring. Any ideas? I'm using Acra version 4.5.0.
The text was updated successfully, but these errors were encountered: