Skip to content

CA-399629: make daily-license-check aware of never #6104

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

Merged
merged 4 commits into from
Nov 6, 2024

Conversation

psafont
Copy link
Member

@psafont psafont commented Nov 5, 2024

The license field is not always a valid date, sometimes it contains a special
value to signify there's no expiry date.

let serialize_expiry = function
| None ->
"never"
| Some date when Date.equal date never ->
Copy link
Contributor

Choose a reason for hiding this comment

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

Should we test for date >= never?

Copy link
Member Author

Choose a reason for hiding this comment

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

technically, only that timestamp is supposed to be never

@psafont psafont force-pushed the late-licenses branch 2 times, most recently from 6b174ee to f3bf203 Compare November 6, 2024 16:23
The license field is not always a valid date, sometimes it contains a special
value to signify there's no expiry date.

Signed-off-by: Pau Ruiz Safont <pau.ruizsafont@cloud.com>
Internalize the concept of expiration dates, including "never", and use Date to
manage all the dates, instead of using unix time

Signed-off-by: Pau Ruiz Safont <pau.ruizsafont@cloud.com>
This now matches the concept of xenserver's licensing daemon, which changed it
in the last year.

Signed-off-by: Pau Ruiz Safont <pau.ruizsafont@cloud.com>
Instead use the Date, Ptime and Ptime.Span

Signed-off-by: Pau Ruiz Safont <pau.ruizsafont@cloud.com>
@psafont psafont added this pull request to the merge queue Nov 6, 2024
Merged via the queue into xapi-project:master with commit 85c8bcd Nov 6, 2024
15 checks passed
@psafont psafont deleted the late-licenses branch November 6, 2024 17:37
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