def calc_bookies_for_workload(write_events_per_second, event_size, performance_profile):
    """
    Given the Bookkeeper throughput saturation points provided in the performance profile, we derive the necessary
    number of Bookies to effectively absorb a given write workload.
    :param write_events_per_second: Number of write events per second in the target workload.
    :param event_size: Typical event size.
    :param performance_profile: Class containing the performance of Bookkeeper in the target environment.
    :return: Number of Bookies to absorb the target workload.
    """
    bookie_saturation_point_for_event_size = 0
    for (es, events_sec) in performance_profile.bookie_saturation_points:
        # We analyzed some pre-defined event sizes.
        if event_size == es:
            bookie_saturation_point_for_event_size = events_sec
            break
    return int(write_events_per_second / bookie_saturation_point_for_event_size + 1)