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

Skipping download because it already exists in the Fetch database #701

Open
pvenrod opened this issue Dec 19, 2024 · 0 comments
Open

Skipping download because it already exists in the Fetch database #701

pvenrod opened this issue Dec 19, 2024 · 0 comments

Comments

@pvenrod
Copy link

pvenrod commented Dec 19, 2024

Hi!

My application is skipping a download because it already exists in the Fetch database. This is happening because, by mistake, I am using the same filename for all downloads.

My current integration is quite simple:

val request = Request(result.url, Uri.fromFile(File(file, FILE_NAME))).apply {
     priority = Priority.HIGH
     networkType = NetworkType.ALL
     addHeader(FIXED_URL_HEADER, "true") // This is internal stuff from my app
}

It doens't matter which file url I use, Fetch just check its database before doing any other stuff and, if the internal filename is the same, it skips the download and returns the old file. So my app is not even requesting the file to the server, it is just skipping the download.

I have this problem in production and I don't know how to solve it, as there are a lot of affected users not being able to download the file.

Is there any workaround I can do for those users in production that are already affected? At this moment is not possible to update the code or launch any app update.

Will fetch automatically clean its database after X period? Or is there any workaround to let Fetch think that the new file is not the same as the one that it has in the database, even if the filename is the same?

I have access to the external file and can change its content and url, just in case it helps.

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

1 participant