Skip to content

iter_list_changed_blocks async

iter_list_changed_blocks(
    second_snapshot_id: SnapshotId,
    *,
    config_overrides: Optional[AsyncEBSClientConfig] = None,
    first_snapshot_id: Optional[SnapshotId] = None,
    next_token: Optional[PageToken] = None,
    max_results: Optional[MaxResults] = None,
    starting_block_index: Optional[BlockIndex] = None,
) -> AsyncIterator[ListChangedBlocksResponse]
Source code in docs_src/capo_ebs/_services/async_ebs.py
async def iter_list_changed_blocks(
    self,
    second_snapshot_id: "capo_ebs.types.snapshot_id.SnapshotId",
    *,
    config_overrides: Optional[AsyncEBSClientConfig] = None,
    first_snapshot_id: Optional["capo_ebs.types.snapshot_id.SnapshotId"] = None,
    next_token: Optional["capo_ebs.types.page_token.PageToken"] = None,
    max_results: Optional["capo_ebs.types.max_results.MaxResults"] = None,
    starting_block_index: Optional["capo_ebs.types.block_index.BlockIndex"] = None,
) -> "AsyncIterator[capo_ebs.types.list_changed_blocks_response.ListChangedBlocksResponse]":
    _token = next_token
    while True:
        _response = await self.list_changed_blocks(
            second_snapshot_id,
            config_overrides=config_overrides,
            first_snapshot_id=first_snapshot_id,
            next_token=_token,
            max_results=max_results,
            starting_block_index=starting_block_index,
        )
        yield _response
        _token = _resolve_path(_response, ("next_token",))
        if not _token:
            break