{"action":"closed","issue":{"url":"https://api.github.com/repos/bumptech/glide/issues/872","repository_url":"https://api.github.com/repos/bumptech/glide","labels_url":"https://api.github.com/repos/bumptech/glide/issues/872/labels{/name}","comments_url":"https://api.github.com/repos/bumptech/glide/issues/872/comments","events_url":"https://api.github.com/repos/bumptech/glide/issues/872/events","html_url":"https://github.com/bumptech/glide/issues/872","id":125386289,"number":872,"title":"Use Glide cache for non-image files?","user":{"login":"minimalviking","id":7045251,"avatar_url":"https://avatars.githubusercontent.com/u/7045251?v=3","gravatar_id":"","url":"https://api.github.com/users/minimalviking","html_url":"https://github.com/minimalviking","followers_url":"https://api.github.com/users/minimalviking/followers","following_url":"https://api.github.com/users/minimalviking/following{/other_user}","gists_url":"https://api.github.com/users/minimalviking/gists{/gist_id}","starred_url":"https://api.github.com/users/minimalviking/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/minimalviking/subscriptions","organizations_url":"https://api.github.com/users/minimalviking/orgs","repos_url":"https://api.github.com/users/minimalviking/repos","events_url":"https://api.github.com/users/minimalviking/events{/privacy}","received_events_url":"https://api.github.com/users/minimalviking/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/bumptech/glide/labels/question","name":"question","color":"d4c5f9"}],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2016-01-07T12:36:37Z","updated_at":"2016-03-19T00:07:31Z","closed_at":"2016-03-19T00:07:31Z","body":"In my app I have a listview with thumbnails of images and videos. Upon row click, the image or video are opened in another fragment. I want to preload the full size images and videos so that opening would be faster. It works perfectly for images, in case of videos I tried to use: \r\n```java\r\nGlide.with(getContext()).load(videoUrl).downloadOnly(new SimpleTarget<File>() {\r\n\r\n\t@Override\r\n\tpublic void onLoadFailed(Exception e, Drawable errorDrawable) {\r\n\t\tsuper.onLoadFailed(e, errorDrawable);\r\n\t}\r\n\r\n\t@Override\r\n\tpublic void onResourceReady(File resource, GlideAnimation<? super File> glideAnimation) {\r\n\t\t\tGlide.with(getContext()).load(resource).asBitmap().diskCacheStrategy(DiskCacheStrategy.SOURCE)\r\n\t\t\t.into(imageview);\r\n\t}\r\n});\r\n```\r\nBut it doesn't work - the second Glide call\r\n```java\r\nGlide.with(getContext()).load(resource).asBitmap().diskCacheStrategy(DiskCacheStrategy.SOURCE)\r\n\t\t\t.into(imageview);\r\n```\r\nfails and `onException` is called with null Exception.\r\n\r\nThe strange thing is that when I download the video file manually and pass it to glide, the thumbnail is loaded correctly.\r\n\r\nIs there any I could download it with Glide and then use it?\r\n"}}