Worklight:加密的缓存大小总是在增加 - 破坏不起作用

时间:2013-05-13 09:44:56

标签: ios local-storage ibm-mobilefirst

我正在使用WL.EncryptedCache并且只在整个用户会话中保存用户ID和密码,一旦用户会话过期或用户明确地从应用程序中退出,我就会使用WL.EncryptedCache.destroy销毁加密缓存。< / p>

May 13 11:51:55 iPhone CardApp[9836] <Warning>: [LOG] clear badge
May 13 11:51:56 iPhone CardApp[9836] <Warning>: Loading stop
May 13 11:51:56 iPhone CardApp[9836] <Warning>: Original Webview bounds {{0, 0}, {320, 460}}, frame {{0, 0}, {320, 460}}
May 13 11:51:56 iPhone CardApp[9836] <Warning>: tabbar bounds: {{0, 411}, {320, 49}}. WebView bounds: {{0, 0}, {320, 411}}
May 13 11:51:56 iPhone CardApp[9836] <Warning>: [ERROR] Invalid argument value '[object Object]', expected null or 'string'.
May 13 11:51:57 iPhone CardApp[9836] <Warning>: [ERROR] [https://mydomain:443/myApp/apps/services/api/CardApp/iphone/query] exception.
May 13 11:51:58 iPhone com.apple.launchd[1] (UIKitApplication:com.apple.mobilephone[0x2e4d][9804]) <Notice>: (UIKitApplication:com.apple.mobilephone[0x2e4d]) Exited: Killed: 9
May 13 11:51:58 iPhone com.apple.launchd[1] (com.apple.tccd[9805]) <Notice>: (com.apple.tccd) Exited: Killed: 9
May 13 11:51:58 iPhone com.apple.launchd[1] (com.apple.librariand[9840]) <Notice>: (com.apple.librariand) Exited: Killed: 9
May 13 11:51:58 iPhone UserEventAgent[13] <Notice>: jetsam: kernel termination snapshot being created
May 13 11:51:58 iPhone com.apple.launchd[1] (com.apple.TextInput.kbd[9823]) <Notice>: (com.apple.TextInput.kbd) Exited: Killed: 9
May 13 11:51:58 iPhone backboardd[26] <Warning>: Application 'UIKitApplication:com.apple.mobilephone[0x2e4d]' exited abnormally with signal 9: Killed: 9
May 13 11:51:58 iPhone com.apple.launchd[1] (UIKitApplication:bh.com.my.CardApp[0xf688][9836]) <Notice>: (UIKitApplication:bh.com.my.CardApp[0xf688]) Exited: Killed: 9
May 13 11:51:58 iPhone backboardd[26] <Warning>: Application 'UIKitApplication:bh.com.my.CardApp[0xf688]' exited abnormally with signal 9: Killed: 9
May 13 11:51:59 iPhone DTPower[5858] <Warning>: Task info failed for task bh.com.my.CardApp
May 13 11:52:01 iPhone ReportCrash[9846] <Error>: libMobileGestalt copySystemVersionDictionaryValue: Could not lookup ReleaseType from system version dictionary
May 13 11:52:01 iPhone ReportCrash[9846] <Notice>: Saved crashreport to /Library/Logs/CrashReporter/LowMemory-2013-05-13-115201.plist using uid: 0 gid: 0, synthetic_euid: 0 egid: 0
May 13 11:53:59 iPhone backboardd[26] <Notice>: Posting 'com.apple.iokit.hid.displayStatus' notifyState=0
May 13 11:53:59 iPhone backboardd[26] <Notice>: MultitouchHID: detection mode: 0->255

我在iOS 5设备中看到的是,本地存储总是在增加App文件夹(文档和数据)的大小。在我的测试中,我首先确保删除该应用程序;接下来我安装了它然后三到四次我只登录并注销...并且缓存大小不断增加。

如上所述,在每次注销时,我都在调用destroy方法,并且它会在销毁后成功执行,如果我搜索密钥,那么它们就不存在,因此被破坏。

最新的v5.0.6中是否有任何修复?目前我正在使用v5.0.5 有解决方法吗?

1 个答案:

答案 0 :(得分:1)

我使用Chrome(Windows 7)在Worklight 5.0.6.1中尝试了EncryptedCache sample;我可以在开发工具(&gt;&gt;资源&gt;&gt;本地存储)中清楚地看到,一旦调用WL.EncryptedCache.destroy,数据就会被删除。

我不认为它在iOS 5或iOS 6中会有任何不同。

注意:在iOS 5中,本地存储被视为可由操作系统随时删除的临时数据。