Experiment & Replay Service Functions

mdml_client.start_experiment(id, topics, producer_kwargs={})

Start an experiment with the MDML Experiment service. Messages produced on all of the specified topics will be saved to a file and upload to S3.

Parameters:
  • id (str) – Unique ID for the experiment
  • topics (list(str)) – Topics to consume from that make up the experiment
  • producer_kwargs (dict) – Dictionary that is passed as kwargs to the underlying producer in this function. Parameter names should be the same as those in a kafka_mdml_producer.
mdml_client.stop_experiment(id, producer_kwargs={})

Stop a previously started experiment. Upon stopping, the experiment service will package all data streamed during an experiment, verify all data is present, and write a file to S3.

Parameters:
  • id (str) – Unique ID for the experiment
  • producer_kwargs (dict) – Dictionary that is passed as kwargs to the underlying producer in this function. Parameter names should be the same as those in a kafka_mdml_producer.
mdml_client.replay_experiment(experiment_id, speed=1, producer_kwargs={})

Replay an experiment - stream data back down their original topics

Parameters:
  • experiment_id (str) – Unique ID of the experiment to replay
  • speed (int) – Speed multiplier used during the replay
  • producer_kwargs (dict) – Dictionary of kwargs for this functions internal producer