Skip to content

Commit

Permalink
ad-hoc patch: persist.read_step()
Browse files Browse the repository at this point in the history
  • Loading branch information
elazarg committed Aug 1, 2024
1 parent 2c577a6 commit 3307cbe
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion save_snapshot.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@
from concurrent.futures import ThreadPoolExecutor, Future
from typing import Iterator

from checkpoint import persist
from checkpoint.qmp_client import SimpleQmpClient

logging.basicConfig(level=logging.INFO)
Expand Down Expand Up @@ -125,7 +126,7 @@ async def relay_qmp_dumps(qmp_port: int, server: Server) -> None:
for index in server:
async with vm.pause(server.sleep_duration_ms):
current_next_file = f"{folder}/{index}.b.dump"
next_prev_file = f"{folder}/{index + 1}.a.dump"
next_prev_file = f"{folder}/{index + persist.read_step()}.a.dump"
await vm.dump(current_next_file)
os.link(current_next_file, next_prev_file)
p: Future[int] = executor.submit(count_diff, folder, index)
Expand Down

0 comments on commit 3307cbe

Please sign in to comment.