ArcGis map crashes randomly

1427
7
03-05-2019 01:43 AM
WorldlineMobile
New Contributor

Hello,

I'm using version 100.4.0 of arcgis and I get sometimes random crashes with the following stacktrace :

E/AndroidRuntime: FATAL EXCEPTION: Thread-31
Process: xxx, PID: 32132
com.esri.arcgisruntime.ArcGISRuntimeException: Invalid argument
at com.esri.arcgisruntime.internal.jni.CoreRequest.nativeGetCanceled(Native Method)
at com.esri.arcgisruntime.internal.jni.CoreRequest.h(SourceFile:213)
at com.esri.arcgisruntime.internal.j.b$2.run(SourceFile:199)
at com.esri.arcgisruntime.internal.b.g.b(SourceFile:45)
at com.esri.arcgisruntime.internal.b.e.a(SourceFile:115)
at com.esri.arcgisruntime.internal.b.c.done(SourceFile:44)
at java.util.concurrent.FutureTask.finishCompletion(FutureTask.java:383)
at java.util.concurrent.FutureTask.set(FutureTask.java:234)
at java.util.concurrent.FutureTask.run(FutureTask.java:274)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1162)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:636)
at java.lang.Thread.run(Thread.java:764)

It happens without changing any code when moving on the map (touch), loading the map or clicking. The data set is the same everytime and I have no idea how to reproduce it.

Do you know what can cause this issue ? And could it be possible to have more details on the Exception returned by ArcGIS because it's really not helpful.

Thank you

0 Kudos
7 Replies
by Anonymous User
Not applicable

Hello!

Any chance you could share your code please? I suspect this may be a race condition of some kind, since I see FutureTask in the stacktrace.

Further details on an exception can be explored with calls to getMessage() and getAdditionalMessage() etc

ArcGISRuntimeException| arcgis-android 

Kind regards,

Trevor

0 Kudos
LukeKim
New Contributor

Trevor,

I am experiencing the same issue with v100.4.0. Please find the error logs below that I captured when it happened. 

Thanks,

Luke

 

* 04-17 13:09:59.634 359-359/? A/DEBUG: pid: 18938, tid: 19614, name: Thread-3167 >>> application.package.id <<<
* 04-17 13:09:59.684 359-359/? A/DEBUG: #00 pc 003cddb4 /data/app/application.package.id-1/lib/arm/libruntimecore.so (_ZNSt14__shared_countILN9__gnu_cxx12_Lock_policyE2EEC2ERKS2_+19)
* 04-17 13:09:59.684 359-359/? A/DEBUG: #01 pc 00496e49 /data/app/application.package.id-1/lib/arm/libruntimecore.so
* 04-17 13:09:59.684 359-359/? A/DEBUG: #02 pc 0049bdb9 /data/app/application.package.id-1/lib/arm/libruntimecore.so (RT_Request_getURI+24)
* 04-17 13:09:59.684 359-359/? A/DEBUG: #03 pc 00139a31 /data/app/application.package.id-1/lib/arm/libruntimecore_java.so (Java_com_esri_arcgisruntime_internal_jni_CoreRequest_nativeGetURI+28)
* 04-17 13:09:59.684 359-359/? A/DEBUG: #04 pc 01a1937d /data/app/application.package.id-1/oat/arm/base.odex (offset 0xf07000) (byte[] com.esri.arcgisruntime.internal.jni.CoreRequest.nativeGetURI(long)+88)
* 04-17 13:09:59.685 359-359/? A/DEBUG: #05 pc 01a19a05 /data/app/application.package.id-1/oat/arm/base.odex (offset 0xf07000) (java.lang.String com.esri.arcgisruntime.internal.jni.CoreRequest.f()+80)
* 04-17 13:09:59.685 359-359/? A/DEBUG: #06 pc 015ff4ef /data/app/application.package.id-1/oat/arm/base.odex (offset 0xf07000) (com.esri.arcgisruntime.internal.e.a.a.e com.esri.arcgisruntime.layers.ArcGISTiledLayer$2.a()+82)
* 04-17 13:09:59.685 359-359/? A/DEBUG: #07 pc 015ff625 /data/app/application.package.id-1/oat/arm/base.odex (offset 0xf07000) (java.lang.Object com.esri.arcgisruntime.layers.ArcGISTiledLayer$2.call()+48)

0 Kudos
NathanMellor
Occasional Contributor

Trevor Draeseke

How will the calls to getMessage() and getAdditionalMessage() help us if we have no way of catching this exception?

This is completely outside our code. The FutureTask is spawned by the Runtime, not me. These things are reported by Crashlytics in the field.

I cannot share all my code. I hope that is not required to get help.

I get plenty of these reported through Crashlytics. I do not know how to reproduce them.

Only common step I can see is that an offline vector map is loaded (from vtpk).

Fatal Exception: com.esri.arcgisruntime.ArcGISRuntimeException: Invalid argument
       at com.esri.arcgisruntime.internal.jni.CoreRequest.nativeGetCanceled(SourceFile)
       at com.esri.arcgisruntime.internal.jni.CoreRequest.h(SourceFile:213)
       at com.esri.arcgisruntime.internal.j.b$2.run(SourceFile:199)
       at com.esri.arcgisruntime.internal.b.g.b(SourceFile:45)
       at com.esri.arcgisruntime.internal.b.e.a(SourceFile:115)
       at com.esri.arcgisruntime.internal.b.c.done(SourceFile:44)
       at java.util.concurrent.FutureTask.finishCompletion(FutureTask.java:383)
       at java.util.concurrent.FutureTask.set(FutureTask.java:234)
       at java.util.concurrent.FutureTask.run(FutureTask.java:274)
       at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1162)
       at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:636)
       at java.lang.Thread.run(Thread.java:764)

Fatal Exception: com.esri.arcgisruntime.ArcGISRuntimeException: Invalid argument
       at com.esri.arcgisruntime.internal.jni.CoreRequest.nativeHandleResponse(SourceFile)
       at com.esri.arcgisruntime.internal.jni.CoreRequest.a(SourceFile:274)
       at com.esri.arcgisruntime.internal.j.b$2.run(SourceFile:200)
       at com.esri.arcgisruntime.internal.b.g.b(SourceFile:45)
       at com.esri.arcgisruntime.internal.b.e.a(SourceFile:115)
       at com.esri.arcgisruntime.internal.b.c.done(SourceFile:44)
       at java.util.concurrent.FutureTask.finishCompletion(FutureTask.java:383)
       at java.util.concurrent.FutureTask.set(FutureTask.java:234)
       at java.util.concurrent.FutureTask.run(FutureTask.java:274)
       at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1162)
       at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:636)
       at java.lang.Thread.run(Thread.java:764)

Nathan

0 Kudos
by Anonymous User
Not applicable

Thanks for letting us know about this. I've spoken with our engineers and they put a fix in 100.5 which they believe addresses this bug. Can you please let me know if you still run into these issues in 100.5? Thanks!

0 Kudos
CollinEmpting
New Contributor

Trevor Draeseke

I am having a similar issue with random crashes while zooming out on our client which recently updated to 100.4.0:

Java frames: (J=compiled Java code, j=interpreted, Vv=VM code)
j com.esri.arcgisruntime.internal.jni.CoreTileRequest.nativeGetTileKey(J)J+0
j com.esri.arcgisruntime.internal.jni.CoreTileRequest.l()Lcom/esri/arcgisruntime/internal/jni/CoreTileKey;+4
j com.esri.arcgisruntime.layers.ArcGISTiledLayer$2.a()Lcom/esri/arcgisruntime/internal/io/handler/request/e;+4
j com.esri.arcgisruntime.layers.ArcGISTiledLayer$2.call()Ljava/lang/Object;+1
J 18649 C2 java.util.concurrent.ThreadPoolExecutor.runWorker(Ljava/util/concurrent/ThreadPoolExecutor$Worker;)V (225 bytes) @ 0x0000000005f28f74 [0x0000000005f28dc0+0x1b4]
J 16533 C1 java.util.concurrent.ThreadPoolExecutor$Worker.run()V (9 bytes) @ 0x0000000003245d0c [0x0000000003245c00+0x10c]
J 19131 C2 java.lang.Thread.run()V (17 bytes) @ 0x00000000041abaec [0x00000000041abaa0+0x4c]
v ~StubRoutines::call_stub

We won't be able to update to 100.5 because we are locked in to Java 8 for the moment.  Is there plans to address this bug in a minor version update to 100.4.0?  If not do you know if there is any su@@ggested mitigation we can apply?

-Collin

0 Kudos
MarkBaird
Esri Regular Contributor

Collin Empting 

Are you using the Java or the Android SDK?  From your comment about Java 8, I'm thinking you are not using Android.

If you are using Android, your code should work fine moving to 100.5.  There are also very good reasons for moving to 100.5 for Android because this is the version we added 64bit support which will be required shortly for apps hosted in the Google Play store.

On the other hand if you are actually using the Java SDK I can see your issue.  100.5 for the Java SDK was released against Java 11 (Open JDK for reasons I'm sure you are aware).  If this the case, you should reach out to our support team who may be able to assist.

Mark

0 Kudos
CollinEmpting
New Contributor

Mark Baird

Sorry, I just realized this was under the Android SDK forum.  I am working with the Java SDK.  I will go ahead and reach out in the correct place.

Thanks,

Collin

0 Kudos