-
Notifications
You must be signed in to change notification settings - Fork 175
chore(BA-2789): Add warning logs in storage implementations when used, limit bytes are under 0 #6359
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
chore(BA-2789): Add warning logs in storage implementations when used, limit bytes are under 0 #6359
Changes from 2 commits
Commits
Show all changes
7 commits
Select commit
Hold shift + click to select a range
3e8938f
feat: Add warning logs in storage implementations when used, limit by…
seedspirit 573863e
docs: Add news fragment
seedspirit 350b90c
Apply suggestion from @Copilot
HyeockJinKim 6063815
feat: Add info about cause of negative bytes got returned in log
seedspirit 8d68b93
misc: Enhance log readability
seedspirit 6dc81bb
refactor: Unify log
seedspirit 11af14d
refactor: Remove line break from log
seedspirit File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1 @@ | ||
| Add warning logs in storage implementations when used, limit bytes are under 0 | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -217,6 +217,13 @@ async def describe_quota_scope( | |
| # By default, report command displays the sizes in the 1 KiB unit. | ||
| used_bytes = int(used_kbs) * 1024 | ||
| hard_limit_bytes = int(hard_limit_kbs) * 1024 | ||
| if used_bytes < 0 or hard_limit_bytes < 0: | ||
| log.warning( | ||
| "Used bytes < 0 ({}) or limit bytes < 0 ({}) for quota scope {} in XFS", | ||
| used_bytes, | ||
| hard_limit_bytes, | ||
| quota_scope_id, | ||
| ) | ||
|
Comment on lines
+219
to
+226
Collaborator
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I think you should log report to check original response. |
||
| return QuotaUsage(used_bytes, hard_limit_bytes) | ||
|
|
||
| async def update_quota_scope( | ||
|
|
||
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.