【发布时间】:2020-03-24 14:51:30
【问题描述】:
我正在创建一个应用程序,您可以在其中创建多种类型的帐户,数据存储在 SQLite 数据库中,并使用 Geocoder 验证地址输入。然而,地理编码器似乎只有在我冷启动模拟器或清除应用程序的存储后才能工作。我认为这是因为地理编码器获取位置所需的时间太长,因此它只会引发异常。但是我不知道是什么导致了这种滞后,因为我已经做了很多事情来尝试优化运行时,即。增加模拟器的存储和使用异步任务。我收到的错误消息是 grpc failed。一些 logcat 消息是:
I/le.walkinclini: NativeAlloc concurrent copying GC freed 68211(2747KB) AllocSpace objects, 0(0B) LOS objects, 49% free, 3487KB/6974KB, paused 661us total 105.541ms
I/AssistStructure: Flattened final assist data: 1600 bytes, containing 1 windows, 7 views
I/Choreographer: Skipped 300 frames! The application may be doing too much work on its main thread.
【问题讨论】:
标签: android database performance geocoding geocode