refactor: update caching duration for network analysis and enhance layout structure in statistics view for improved readability
This commit is contained in:
@@ -419,7 +419,10 @@ class Statistics extends Component
|
||||
$this->topPortsCurrentPage = 1;
|
||||
|
||||
// Persist the computed analysis for a short period to speed up subsequent loads
|
||||
Cache::put($cacheKey, $analysis, now()->addSeconds(30));
|
||||
// Cache duration is set to 25 seconds (slightly less than the 30s poll interval)
|
||||
// This ensures fresh data is fetched on each poll cycle while still preventing
|
||||
// duplicate requests within the same cycle
|
||||
Cache::put($cacheKey, $analysis, now()->addSeconds(25));
|
||||
|
||||
// Reset retry count on successful load
|
||||
$this->networkAnalysisRetryCount = 0;
|
||||
|
||||
Reference in New Issue
Block a user