如何增加LVL缓存有效时间? [英] How to increase LVL cache-valid time?

查看:149
本文介绍了如何增加LVL缓存有效时间?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在我的应用程序实现拉特服务器管理的策略。我知道,拉特服务器响应缓存在设备一段时间,从而使用户能够使用的应用程序,而不INTERENT连接(LVL使用缓存许可证的话)。我想知道,周期究竟有多长,我怎么能增加。 基本上,LVL我实现了检查许可每次应用程序启动时,我想,以增加高速缓存有效时间为60天。

I've implemented LVL server managed policy in my app. I know that lvl server response is cached in a device for some period of time so users are able to use a app without interent connection (lvl uses cached license then). I would like to know exactly how long that period is and how I can increase it. Basically, lvl I've implemented checks license everytime the app starts and I would like to increase cache-valid time to 60 days.

推荐答案

我还没有发现的LVL缓存时间由谷歌服务器设置的实际价值,但我发现怎么改。在 ServerManagedPolicy.java 文件更改:

I haven't found the actual value of the lvl cache-time set by google servers, but I found how to change it. In the ServerManagedPolicy.java file change:

setValidityTimestamp(extras.get("VT"));

到任何你喜欢(在这里30天):

to whatever you like (here to 30 days):

setValidityTimestamp(String.valueOf(System.currentTimeMillis() + (MILLIS_PER_MINUTE * 60 *24*30)));

这篇关于如何增加LVL缓存有效时间?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆