Skip to content

Bitmag 1142 integrity gui display checksum age#39

Merged
Bohlski merged 51 commits intomasterfrom
BITMAG-1142-integrity-gui-display-checksum-age
Sep 20, 2022
Merged

Bitmag 1142 integrity gui display checksum age#39
Bohlski merged 51 commits intomasterfrom
BITMAG-1142-integrity-gui-display-checksum-age

Conversation

@ole-v-v
Copy link
Copy Markdown
Contributor

@ole-v-v ole-v-v commented Aug 25, 2022

https://sbforge.org/jira/browse/BITMAG-1142
On the integrity web GUI, for each pillar display configured max age of checksums and age of currently oldest checksum.

@ole-v-v ole-v-v requested review from Bohlski and m-atlantis August 25, 2022 11:05
Copy link
Copy Markdown
Contributor

@Bohlski Bohlski left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Very nice.

Apart from my requested changes, I think it would be nicer looking if in the integrity-GUI the "Age of oldest checksum"-column showed maybe just the current largest unit of time and just had its lowest shown unit set to hours or something like that. Currently the seconds-count keeps updating on every call to /getIntegrityStatus, which is largely irrelevant when it could take years before we update checksums.

Comment thread bitrepository-webclient/src/main/webapp/integrity-service.html Outdated
Comment thread bitrepository-webclient/src/main/webapp/integrity-service.html
@ole-v-v
Copy link
Copy Markdown
Contributor Author

ole-v-v commented Aug 30, 2022

Apart from my requested changes, I think it would be nicer looking if in the integrity-GUI the "Age of oldest checksum"-column showed maybe just the current largest unit of time and just had its lowest shown unit set to hours or something like that.

Thanks, I agree that currently it’s absurdly precise. On the other hand, should the value (unlikely) come down to a few days, I think that we do want hours too. Suggestion for a compromise: Include hours if months are 6 or less. Include minutes if days are 8 or less. Include seconds if days are 0. Never include fraction of second. This generally gives the user a precision of 0.5 % of the age or finer. I don’t find that too fine-grained. And when not perfectly sure, I’d still rather be too precise.

@m-atlantis
Copy link
Copy Markdown
Member

m-atlantis commented Aug 30, 2022

Apart from my requested changes, I think it would be nicer looking if in the integrity-GUI the "Age of oldest checksum"-column showed maybe just the current largest unit of time and just had its lowest shown unit set to hours or something like that.

Thanks, I agree that currently it’s absurdly precise. On the other hand, should the value (unlikely) come down to a few days, I think that we do want hours too. Suggestion for a compromise: Include hours if months are 6 or less. Include minutes if days are 8 or less. Include seconds if days are 0. Never include fraction of second. This generally gives the user a precision of 0.5 % of the age or finer. I don’t find that too fine-grained. And when not perfectly sure, I’d still rather be too precise.

I think that we don't want the timer to update as often as it currently does, so showing seconds is kinda irrelevant - especially since whoever is looking don't really care if it's 45 seconds old.
I think it is gonna be used to see if something is 1 month old compared to years perhaps. And once we no longer need to care about seconds, then we definitely don't want to update the age very often

@m-atlantis m-atlantis closed this Aug 30, 2022
@m-atlantis m-atlantis reopened this Aug 30, 2022
Comment thread bitrepository-webclient/src/main/webapp/integrity-service.html Outdated
Comment thread bitrepository-webclient/src/main/webapp/integrity-service.html Outdated
Comment thread bitrepository-webclient/src/main/webapp/integrity-service.html Outdated
Comment thread bitrepository-webclient/src/main/webapp/integrity-service.html
Comment thread bitrepository-webclient/src/main/webapp/integrity-service.html
Comment thread bitrepository-webclient/src/main/webapp/integrity-service.html Outdated
Comment thread bitrepository-webclient/src/main/webapp/integrity-service.html Outdated
Bohlski and others added 2 commits September 1, 2022 12:57
…start integrity-service so it actually shows correct maxChecksumAge for pillars
* Formats a non-negative Duration to an approximate human-readable string like "1y 2m" or "3h 45m".
* The conversion uses approximate average values for the lengths of days, months and years.
*
* The duration must be non-negative and not longer than 4 382 910 hours (approximately 500 years)
Copy link
Copy Markdown
Contributor Author

@ole-v-v ole-v-v Sep 2, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The validation is in the wrong place here. It should be with the max age setting and should be documented there (since in practice the value comes from there). I suggest we fix that separately after both BITMAG-992 and BITMAG-1142 have been merged. We may also want to consider once more whether 500 years is an appropriate limit (java.time.Duration can handle over 292 000 000 000 years but java.time.Period only 2 100 000 000 years; we need a limit somewhere).

@Bohlski Bohlski merged commit d4039d8 into master Sep 20, 2022
@Bohlski Bohlski deleted the BITMAG-1142-integrity-gui-display-checksum-age branch September 20, 2022 13:36
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

Successfully merging this pull request may close these issues.

3 participants