beat.web.backend.helpers module¶
-
beat.web.backend.helpers.schedule_experiment(experiment)[source]¶ Schedules the experiment for execution at the backend
Scheduling an experiment only means creating one
models.Jobinstance for each block of the experiment.This function is expected to be called on the web server. The Scheduler is tasked to notice the newly-scheduled experiment and execute it.
-
beat.web.backend.helpers.cancel_experiment(experiment)[source]¶ Cancel the execution of the experiment on the backend
Cancelling an experiment only means marking the experiment as ‘cancelling’.
This function is expected to be called on the web server. The Scheduler is tasked to notice the newly-cancelled experiment and does what it takes.
-
beat.web.backend.helpers.split_new_jobs()[source]¶ Retrieve all the jobs not already splitted, and create the appropriate splits
-
beat.web.backend.helpers.process_newly_cancelled_experiments()[source]¶ Retrieve all the experiments that must be cancelled, and do it
-
beat.web.backend.helpers.is_cache_complete(path, nb_expected_blocks, cache='/scratch/builds/iJyPBhV4/0/beat/beat.web/doc/api/prefix/cache')[source]¶ Check that an entry of the cache is complete
Due to the distributed nature of the platform, with volumes shared by several different machines, a (hopefully) small delay might occur between the writing of a file in the cache on a processing node and its availability on the current machine.
This function checks that all the necessary files are there, and complete.
-
beat.web.backend.helpers.assign_splits_to_workers()[source]¶ Assign existing job splits to available workers from the appropriate queues
-
beat.web.backend.helpers.get_configuration_for_split(split)[source]¶ Retrieve the configuration to be used to execute the provided job split on a worker node
-
beat.web.backend.helpers.on_split_started(split)[source]¶ Must be called each time a split job is started
-
beat.web.backend.helpers.on_split_done(split, result)[source]¶ Must be called each time a split job is successfully completed
-
beat.web.backend.helpers.on_split_fail(split, result)[source]¶ Must be called each time a split job is successfully completed
-
beat.web.backend.helpers.on_split_cancelled(split)[source]¶ Must be called each time a split job is successfully cancelled
-
beat.web.backend.helpers.retrieve_candidate_splits_for_queue(queue)[source]¶ Retrieve the splits assigned to the given queue that could be considered for execution
-
beat.web.backend.helpers.assign_split_to_worker(split, worker)[source]¶ Schedules the split to be executed on a given worker
-
beat.web.backend.helpers.mark_similar_jobs_as_mirror(job)[source]¶ Mark all similar jobs as mirror, and delete their job splits
-
beat.web.backend.helpers.update_dependent_jobs(job)[source]¶ Mark the dependent jobs of the provided one as runnable
Intended to be called after a job is done