bumptech / bumptech/glide

does not load image from cache when url is from s3 presigned.

Open
#4,501 5 comments 0 reactions 0 assignees View on GitHub
Dominant language
Java
Stars
35k
Forks
6.2k
Avg merge
1d 11h
Merged PRs (30d)
8

Description

**Glide Version**:

implementation 'com.github.bumptech.glide:glide:4.11.0'
kapt 'com.github.bumptech.glide:compiler:4.11.0'
implementation 'com.github.bumptech.glide:annotations:4.11.0'
implementation 'jp.wasabeef:glide-transformations:1.0.1'

**Integration libraries**:No any other libraries

**Device/Android Version**: in all android devices

**Issue details / Repro steps / Use case background**:

In recyclerview want to load dynamic url from s3(presigned) and also want to load image from cache but when i am try to load from second time till it not load image from cache.
i also try to save generated url for second time but still it is not working.

**Glide load line / `GlideModule` (if any) / list Adapter code (if any)**:
```in adapter

val requestOptions = RequestOptions()
.signature(ObjectKey(template.thumbUrl!!))
.skipMemoryCache(false)
if (imageLink == null) {
getPresignedUrl(context, thumbname, bucketName) {
imageLink = it
GlideApp.with(context.applicationContext)
.load(template.imageLink)
.placeholder(R.drawable.ic_placeholder)
.apply(requestOptions)
.transform(RoundedCorners(AppUtil.dpToPx(10).toInt()))
.listener(object : OnImageLoad {
override fun onImageLoadSuccess() {
progressBar.viewGone()
}

override fun onImageLoadFailed() {
progressBar.viewGone()
}
})
.into(imageViewTemplate)
}
} else {
GlideApp.with(context)
.load(imageLink)
.placeholder(R.drawable.ic_placeholder)
.apply(requestOptions)
.transform(RoundedCorners(AppUtil.dpToPx(10).toInt()))
.listener(object : OnImageLoad {
override fun onImageLoadSuccess() {
progressBar.viewGone()
}

override fun onImageLoadFailed() {
progressBar.viewGone()
}
})
.into(imageViewTemplate)
}
```

**Layout XML**:
```xml


```

**Stack trace / LogCat**: not found any issue in logcat

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.