Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to check if cache is actually operational? #10

Closed
FastNinja opened this issue Jan 3, 2018 · 4 comments
Closed

How to check if cache is actually operational? #10

FastNinja opened this issue Jan 3, 2018 · 4 comments

Comments

@FastNinja
Copy link

I need to verify that app actually using cache when it is supposed to use cache instead of downloading the file.

I am not sure how exactly do that?
Options:

  • some kind of debugInfo might be helpful that can be switched on or off?
  • Callback (crazy idea):
   image: new CachedNetworkImageProvider(imageUrl, 
              onImageProvided: (imageFile, fromCache) => 
                  { /*
                       here developers can do something with file, or log, or alternate for how long it 
 should stay etc...
                    */
                    } ),

but basically I want to see somewhere:

 loaded from from URL 'www.site.com/file.png',
 used file from cache 'www.site.com/file.png',
...
...
used file from cache 'www.site.com/file.png',
@renefloor
Copy link
Contributor

Yes options for loging would be a good idea. The callback is more work and kind of a breaking change. Do you see much use for that?

I guess I will add some debug logging with the option to turn it on or off.

@FastNinja
Copy link
Author

logs are enough for sure!

@renefloor
Copy link
Contributor

For issue #8 I was already building some logging, so will add that in a next release.

@renefloor
Copy link
Contributor

Added in the Cache Manager so this will be added in the next release.

@expilu expilu mentioned this issue Jul 23, 2020
2 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants