Run the job, with the option of passing runtime arguments.
Example of a blocking execution and downloading logs once execution is finished.
# Run the job execution = job.run(await_termination=True) # True if job executed successfully print(execution.success) # Download logs out_log_path, err_log_path = execution.download_logs()
Optional[str]: optional runtime arguments for the job
Optional[bool]: if True wait until termination is complete
Execution. The execution object for the submitted run.
Retrieves all executions for the job.
RestAPIError in case the backend fails to retrieve executions.
Application id for the execution
Arguments set for the execution.
Duration in milliseconds the execution ran.
Final status of the execution. Can be UNDEFINED, SUCCEEDED, FAILED or KILLED.
Filesystem user for the execution.
Id of the execution
Name of the job the execution belongs to
Type of the job the execution belongs to
Progress of the execution.
Current state of the execution.
Path in Hopsworks Filesystem to stderr log file
Path in Hopsworks Filesystem to stdout log file
Timestamp when the execution was submitted
Boolean to indicate if execution ran successfully or failed
bool. True if execution ran successfully. False if execution failed or was killed.
User that submitted the execution.
Delete the execution
Potentially dangerous operation
This operation deletes the execution.
Download stdout and stderr logs for the execution
Example for downloading and printing the logs
# Download logs out_log_path, err_log_path = execution.download_logs() out_fd = open(out_log_path, "r") print(out_fd.read()) err_fd = open(err_log_path, "r") print(err_fd.read())
str. Path to downloaded log for stdout.
str. Path to downloaded log for stderr.