-
Notifications
You must be signed in to change notification settings - Fork 17
feat: use same duration functions #3156
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
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
This PR refactors duration formatting functions to use more consistent and descriptive naming conventions. The changes rename formatUptimeInSeconds to formatDurationSeconds and formatMsToUptime to formatDurationMs to better reflect their generic duration formatting purpose rather than being specific to uptime.
- Renamed duration formatting functions to more descriptive names
- Updated all usages across the codebase consistently
- Improved the Operations duration column to use the standardized formatting approach
Reviewed changes
Copilot reviewed 8 out of 8 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| src/utils/dataFormatters/dataFormatters.ts | Renamed core formatting functions and updated documentation |
| src/utils/dataFormatters/test/formatDuration.test.ts | Updated test suite to use new function names |
| src/containers/Tenant/Diagnostics/Partitions/columns/columns.tsx | Updated partition lag/idle time formatting calls |
| src/containers/Tenant/Diagnostics/Consumers/columns/columns.tsx | Updated consumer lag/idle time formatting calls |
| src/containers/Tenant/Diagnostics/Consumers/TopicStats/ConsumersTopicStats.tsx | Updated topic stats formatting calls |
| src/containers/Operations/columns.tsx | Replaced custom duration formatting with standardized function and removed unnecessary imports |
| src/components/VDiskPopup/VDiskPopup.tsx | Updated VDisk replication time formatting |
| src/components/VDiskInfo/VDiskInfo.tsx | Updated VDisk info time formatting and imports |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
8 files reviewed, no comments
e22effc to
e22147f
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
8 files reviewed, 1 comment
Closes #3133
CI Results
Test Status:⚠️ FLAKY
📊 Full Report
Test Changes Summary ⏭️2
⏭️ Skipped Tests (2)
Bundle Size: ✅
Current: 62.34 MB | Main: 62.34 MB
Diff: 0.28 KB (-0.00%)
✅ Bundle size unchanged.
ℹ️ CI Information