Set expiration policy for cache using Google's Volley

前端 未结 2 507
夕颜
夕颜 2020-12-13 07:10

Is it possible to modify the expiration policy for the cache on Google\'s Volley lib? I believe you can implement your own cache, however is there an easy way to do this wi

2条回答
  •  感动是毒
    2020-12-13 07:39

    It seems that currently the cache expiration is controlled solely by the "Cache" headers in the response so basically you are left to the mercy of the server. Whatever server returns in the "Expires" or "max-age=" that will be used. We will have to use our own cache if we need custom expiry policy...

提交回复
热议问题