Bug #2564
Machine Performance Metrics with Downtime & Utilization Calculation
0%
Description
Description:
Implement machine performance metrics to evaluate utilization and availability by incorporating charging hours, downtime, and total hours. This will provide accurate insights into machine efficiency and operational health.
Requirements:
Data Calculation Logic
Total Hours (e.g., 24 hrs/day)
Downtime Hours (fault, offline, maintenance)
Available Hours = Total Hours − Downtime
Charging Hours (from session data)
KPIs to be Calculated
Availability () = (Available Hours / Total Hours) × 100
Utilization () = (Charging Hours / Available Hours) × 100
Efficiency (%) = (Charging Hours / Total Hours) × 100
Data Sources
Charging session logs
Machine status / fault logs
Uptime/downtime tracking
Backend Changes
Create aggregation logic for daily machine summary
Store results in a reporting table (e.g., machine_daily_summary)
Optimize queries for performance
API Development
New endpoint to fetch machine performance metrics
Support filters:
Date range
Machine ID
Location
Dashboard Integration
Display KPIs:
Availability %
Utilization %
Efficiency %
Provide daily/weekly trends
Edge Case Handling
Avoid division by zero
Handle missing/partial data
Consider overlapping downtime sessions
Acceptance Criteria:
KPIs are calculated correctly using downtime-inclusive logic
Data is available daily per machine
APIs return accurate and optimized results
Dashboard reflects correct values and trends
System handles edge cases without failure
Notes:
Prefer using actual uptime instead of fixed 24 hrs where applicable
Ensure downtime classification is accurate (planned vs unplanned)
No data to display