code: def update_points_in_loop(
      peer_url, collection_name, offset=0, throttle=False, duration=None
  ):
      start = time.time()
      limit = 3
  
      while True:
          upsert_random_points(
              peer_url, limit, collection_name, offset=offset
          )
          offset += limit
  
          if throttle:
              sleep(0.1)
          if duration is not None and (time.time() - start) > duration:
              break
  
file_path: qdrant/tests/consensus_tests/test_shard_snapshot_transfer_cancel.py
imports: import multiprocessing
  import pathlib
  from time import sleep
  from .fixtures import upsert_random_points, create_collection
  from .utils import *
label_desc: Use image node_id 1 for calling a global function with example usage: update_points_in_loop(peer_url, collection_name, offset, throttle, duration) without return types