Skip to content

Commit

Permalink
storcon: block migrations on no heatmap
Browse files Browse the repository at this point in the history
  • Loading branch information
jcsp committed Dec 2, 2024
1 parent 612ac34 commit 9d811dd
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions storage_controller/src/service.rs
Original file line number Diff line number Diff line change
Expand Up @@ -6244,8 +6244,9 @@ impl Service {
// them in an optimization
const DOWNLOAD_FRESHNESS_THRESHOLD: u64 = 10 * 1024 * 1024 * 1024;

if progress.bytes_total < DOWNLOAD_FRESHNESS_THRESHOLD
&& progress.bytes_downloaded != progress.bytes_total
if progress.heatmap_mtime.is_none()
|| progress.bytes_total < DOWNLOAD_FRESHNESS_THRESHOLD
&& progress.bytes_downloaded != progress.bytes_total
|| progress.bytes_total - progress.bytes_downloaded
> DOWNLOAD_FRESHNESS_THRESHOLD
{
Expand Down

0 comments on commit 9d811dd

Please sign in to comment.