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
flush API cache / force redownload of API #23
Labels
enhancement
New feature or request
Comments
Every time you start a new r session you create a new client in the back end without knowing it. This will then check for any updates to the api since the last time you used rdhs. If there is any update then the API calls are flushed.
So presuming there is not a new update while you are within your rsession this should never be an issue. However, for I suppose the issue where it does update while you are in an r session then a request forcing the requery could be useful. Will put one in for this (theres one in the get_available_datasets for this sort of thing where you've requested new datasets) and one to flush API calls.
I wonder though how useful it will be as how will someone know or come to find out that during an r session there has been an API update? I only make the check for updates at the beginning of a session so you don't query the data updates endpoint on every API request (to save time/overhead on their server). If you have any ideas of how it makes sense to alert the user about this let me know. Something more intelligent than my first thought of every x minutes since your session started do a check.
From: Jeff Eaton
Sent: Wednesday, May 2, 11:09 PM
Subject: [OJWatson/rdhs] flush API cache / force redownload of API (#23)
To: OJWatson/rdhs
Cc: Subscribed
We got a problem. I have cached version of an API call. But I want to query the API again for updated results.
API calls should have an argument force re-querying the API. It would be convenient to have a function to flush the entire API cache.
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub<#23>, or mute the thread<https://github.com/notifications/unsubscribe-auth/AOiwnXplG7spi_t8YnRobDyDwm4DrFRuks5tui6QgaJpZM4TwPDx>.
|
Thanks -- I think that a check every time you start a new session should be more than sufficient, that sounds good to me.
The issue that arose yesterday was that when I tried to confirm the change to the DR2007SPE surveyId, it did not requery the API, and I had to manually go into my rdhs root and clear out the API cache folder. I thought that I had started a new session for that, but perhaps I didn’t.
On 3 May 2018, at 09:16, OJ Watson <notifications@github.com<mailto:notifications@github.com>> wrote:
Every time you start a new r session you create a new client in the back end without knowing it. This will then check for any updates to the api since the last time you used rdhs. If there is any update then the API calls are flushed.
So presuming there is not a new update while you are within your rsession this should never be an issue. However, for I suppose the issue where it does update while you are in an r session then a request forcing the requery could be useful. Will put one in for this (theres one in the get_available_datasets for this sort of thing where you've requested new datasets) and one to flush API calls.
I wonder though how useful it will be as how will someone know or come to find out that during an r session there has been an API update? I only make the check for updates at the beginning of a session so you don't query the data updates endpoint on every API request (to save time/overhead on their server). If you have any ideas of how it makes sense to alert the user about this let me know. Something more intelligent than my first thought of every x minutes since your session started do a check.
From: Jeff Eaton
Sent: Wednesday, May 2, 11:09 PM
Subject: [OJWatson/rdhs] flush API cache / force redownload of API (#23)
To: OJWatson/rdhs
Cc: Subscribed
We got a problem. I have cached version of an API call. But I want to query the API again for updated results.
API calls should have an argument force re-querying the API. It would be convenient to have a function to flush the entire API cache.
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub<#23>, or mute the thread<https://github.com/notifications/unsubscribe-auth/AOiwnXplG7spi_t8YnRobDyDwm4DrFRuks5tui6QgaJpZM4TwPDx>.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub<#23 (comment)>, or mute the thread<https://github.com/notifications/unsubscribe-auth/AHFXO1MUHeuG1Yb5H7TK2CGWUsKNQo01ks5turzLgaJpZM4TwPDx>.
|
That'll be because although they've changed the names they haven't updated the data updates api to reflect this. I assume this will happen over time but i'll just put the flush in anyway. won't take any time |
addressed in #30 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
We got a problem. I have cached version of an API call. But I want to query the API again for updated results.
The text was updated successfully, but these errors were encountered: