java - Making ImageGallery of private Images in S3 Client android -
i trying create imagegallery of s3 bucket in android application. images private won't having specific link each image.
for such private images , amazon has link generator,
s3client.generatepresignedurl(constants.s3_bucket_name, key, expiration);
it generates url let's 1 hour or 2 min expiration set us.
now easy memory caching , stuff, can either use volley or picasso or many other such easy loading libraries.
however there catch. want cache these images in memory. have dynamic link.
how can make picasso or other library use dynamic link cache?
as per information, libraries use url "key" cache, correct? if how can save these images can use these images later when offline, again, have dynamic link url changing every instant maybe need save them key passing s3client.
what solution.
latest picasso
version adopts setting network policies. probably, need set networkpolicy.offline
picasso.request
builder:
picasso.with(this) .load(s3url) .networkpolicy(networkpolicy.offline) .into(imageview);
regarding caching, might want set expiration time cachecontrol
of picasso okhttpclient
, same s3 links.
Comments
Post a Comment