简体   繁体   English

当记录数为 50k 时,带有过滤器的 IBM JsonStore FindAll 不带过滤器在 IOS 中不起作用

[英]IBM JsonStore FindAll with filter ot without Filter not working in IOS when the records count is 50k

Hi I have a JSONSTORE with encryption enabled and i have a Store called Assets in this i store upto 50k+ records and i try to retrieve the all the records unique value using Filter option in the JSONStore and it works perfectly in the android devices but when it comes to IOS the API keeps on loading without any result / error.嗨,我有一个启用加密的 JSONSTORE,我有一个名为 Assets 的商店,我存储多达 50k+ 条记录,我尝试使用 JSONStore 中的 Filter 选项检索所有记录的唯一值,它在 android 设备中完美运行,但是当它来到 IOS,API 继续加载,没有任何结果/错误。 WL.JSONStore.get("Assets").findAll({filter : ["ASSETID"]}) WL.JSONStore.get("Assets").findAll() I am using Cordova IOS -> 4.5.4 JSONStore Plugin -> 8.0.2019121604 (Tried latest as well same result) WL.JSONStore.get("Assets").findAll({filter : ["ASSETID"]}) WL.JSONStore.get("Assets").findAll()我正在使用 Cordova IOS -> 4.5.4 JSONStore 插件 - > 8.0.2019121604(尝试过最新的结果也是一样的)

Can you explain why you're trying to load 50k records into memory ?你能解释为什么你试图将 50k 条记录加载到内存中吗? This is typically bad design and there is no way 50k records are needed in the app at a given time.这通常是糟糕的设计,在给定时间应用程序中不可能需要 50k 条记录。 You should always query the subset of records you're interested in. If you want to display all 50k in a list, you should still paginate your results and display them.您应该始终查询您感兴趣的记录子集。如果您想在列表中显示所有 50k,您仍然应该对结果进行分页并显示它们。

The behavior depends on the memory available on the device, plus the memory management of iOS.该行为取决于设备上可用的内存,以及 iOS 的内存管理。

Furthermore, loading so many records will cause iOS to terminate background apps leading to poor experience for your users.此外,加载如此多的记录会导致 iOS 终止后台应用程序,从而导致用户体验不佳。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM