-
Notifications
You must be signed in to change notification settings - Fork 32
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
Review last updated information that is cached #68
Comments
I now see this is used in the expanded stats view, but still the data is returned for all child items in the browsing table. We shouldn't do this, and maybe it's worth to even simplify the data we display in the expanded view. |
When it comes to stats, I think I changed the code not to export unnecessary fields. Did you recalculate the stats? |
Yes, definitely — please consider this issue in the context of #62 and the Still, the main concerning point here is that there is too much information being cached. In browsing tables only the Since with the recent changes we are already required to run a server-wide |
In the detailed stats view, we can definitely use only timestamps as well. So feel free to remove all datetime fields. Where specifically are they currently used? |
The rendering of last actions is already using timestamps in the detailed view, so the rest of datetimes are redundant. Regarding the other fields, So the cached information would be reduced to: {
"lastupdated": {
"mtime": <int:timestamp>,
"source": <string:unit-source>,
"uid": <int:unit-id>,
}
} or in case we decide not to display last updated information besides the date: {
"lastupdated": <int:timestamp>
} |
As I understand, we're referring to the 'Last updated' column used in the browser table, and to the 'Updates' section in the expanded stats. The first one indeed requires only the timestamp and is heavily used, while the other seems to be less useful. So if our only reason to cache extra data is to display this 'Updates' section, we can ditch it and store only the timestamp. |
Your understanding is correct, and totally agree with what you say (it's in line with what I was proposing above). I'll update #75 so that we cache timestamps only. |
While checking #62, I realized that the cached information for the Last Updated column contains more information than we actually use.
With the new browsing table, we are only interested in the timestamp for the
creation_time
. Thelastupdated
key in the cache contains the following information though:Unless there's a use-case I am missing, we should reduce this to a single value and hence make better use of the server memory. This would also simplify the initial queries for refreshing the data.
The text was updated successfully, but these errors were encountered: