Skip to content

usage backup: Raw usage/usage display to record time duration of usage#5005

Closed
Pearl1594 wants to merge 1 commit into
apache:4.15from
shapeblue:usage-bkp-timeduration
Closed

usage backup: Raw usage/usage display to record time duration of usage#5005
Pearl1594 wants to merge 1 commit into
apache:4.15from
shapeblue:usage-bkp-timeduration

Conversation

@Pearl1594
Copy link
Copy Markdown
Contributor

Description

This PR ensure consistency between usage details stored across different resource types. For the sake of consistency, backup usage record will show the time duration of backup usage in the raw_usage / usage_display fields.

Types of changes

  • Breaking change (fix or feature that would cause existing functionality to change)
  • New feature (non-breaking change which adds functionality)
  • Bug fix (non-breaking change which fixes an issue)
  • Enhancement (improves an existing feature and functionality)
  • Cleanup (Code refactoring and cleanup, that may add test cases)

Feature/Enhancement Scale or Bug Severity

Bug Severity

  • BLOCKER
  • Critical
  • Major
  • Minor
  • Trivial

Screenshots (if appropriate):

How Has This Been Tested?

@Pearl1594 Pearl1594 changed the base branch from master to 4.15 May 10, 2021 06:41
@Pearl1594 Pearl1594 added this to the 4.15.1.0 milestone May 10, 2021
@Pearl1594
Copy link
Copy Markdown
Contributor Author

@blueorangutan package

@Pearl1594 Pearl1594 requested a review from yadvr May 10, 2021 10:10
@Pearl1594
Copy link
Copy Markdown
Contributor Author

@blueorangutan package

@blueorangutan
Copy link
Copy Markdown

@Pearl1594 a Jenkins job has been kicked to build packages. I'll keep you posted as I make progress.

@blueorangutan
Copy link
Copy Markdown

Packaging result: ✔️ centos7 ✖️ centos8 ✖️ debian. SL-JID 554

final Long vmId = backupInfo.getVmId();
final Long zoneId = backupInfo.getZoneId();
final Long offeringId = backupInfo.getOfferingId();
float usage = runningTime / 1000f / 60f / 60f;
Copy link
Copy Markdown
Contributor

@GutoVeronezi GutoVeronezi May 10, 2021

Choose a reason for hiding this comment

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

@Pearl1594 as this calculation is done several times in the code, we could create an utility to it.

@yadvr yadvr removed this from the 4.15.1.0 milestone May 12, 2021
@sureshanaparti sureshanaparti added this to the 4.16.0.0 milestone Jul 19, 2021
@weizhouapache
Copy link
Copy Markdown
Member

@Pearl1594 does this pr fix #4982 ? is it ready for review ?

@nvazquez

@nvazquez
Copy link
Copy Markdown
Contributor

nvazquez commented Aug 2, 2021

Hi @Pearl1594, @weizhouapache has created PR #5259 to fix #4982, can you please sync to work on a unified solution?

@Pearl1594
Copy link
Copy Markdown
Contributor Author

Will do @nvazquez @weizhouapache - Thanks.

@nvazquez
Copy link
Copy Markdown
Contributor

Hi @Pearl1594 any update on this? Can both PRs be integrated into a single one to fix the issue #4982?

@Pearl1594
Copy link
Copy Markdown
Contributor Author

Hi @nvazquez - was held up in other tasks, hence wasn't able to test #5259. However, on doing a code review, I believe, both PRs solve the same issue, and @weizhouapache's solution would be less disruptive and more apt to address the issue - so maybe we could go ahead with #5259. I'll spend some time testing it as well. Apologies for the delay.

@yadvr yadvr modified the milestones: 4.16.0.0, 4.15.2.0 Aug 31, 2021
@yadvr
Copy link
Copy Markdown
Member

yadvr commented Aug 31, 2021

@Pearl1594 tentatively moving to 4.15.2.0 milestone - please advise if it's feasible/ready for 4.15?

@Pearl1594
Copy link
Copy Markdown
Contributor Author

Since PR #5259 addresses the same issue - I'll close this PR

@Pearl1594 Pearl1594 closed this Aug 31, 2021
@yadvr yadvr removed this from the 4.15.2.0 milestone Aug 31, 2021
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.

7 participants