Collections functions
General functions
Render functions
Theme permission functions
Resource functions

get_job_type_priority()

Description

Get the default priority for a given job type

Parameters

ColumnTypeDefaultDescription
$type string "" Name of job type e.g. 'collection_download'

Return

int

Location

include/job_functions.php lines 380 to 410

Definition

 
function get_job_type_priority($type="")
    {
    if(
trim($type) != "")
        {
        switch (
trim($type))
            {
            case 
'collection_download':
            case 
'create_download_file':
            case 
'config_export':
            case 
'csv_metadata_export':
                return 
JOB_PRIORITY_USER;
                break;
            
            case 
'create_previews':
            case 
'extract_text':
            case 
'replace_batch_local':
            case 
'create_alt_file':
            case 
'delete_file':
            case 
'replace_batch_local':
            case 
'update_resource':
            case 
'upload_processing':
                return 
JOB_PRIORITY_SYSTEM;
                break;

            default:
                return 
JOB_PRIORITY_SYSTEM;
                break;
            }
        }
    return 
JOB_PRIORITY_SYSTEM;
    }

This article was last updated 3rd October 2022 13:05 Europe/London time based on the source file dated 1st July 2022 11:05 Europe/London time.