How the Argent Queue Engine Works-Queues
When initially installed, three queues are created, these queues are called HIGH_PRIORITY, LOW_PRIORITY and QUEUE1; queue names can be up to 32 characters in length, and the more meaningful the name, the better.
A queue is an independent work area within the Argent Queue Engine. Queues in the Argent Queue Engine are independent of each other and provide the primary means of setting the characteristics of the specific Argent Queue Engine. A job is submitted to a queue and the job is executed based on the characteristics of the queue; this is the central precept of the Argent Queue Engine.
The three queues are shown in the screenshot below.
This second screenshot shows the first of the Properties screens where – surprisingly – the properties of the queue are defined and changed.
Queue Property — Name
This is the most important queue property as queues are only referenced by name. Care in selecting the name to reflect its main purpose is obviously useful. In this example this queue – HIGH_PRIORITY – suggests just that, as is discussed below.
Queue Property – Description
In direct contrast to the queue’s Name, the Description field is just for documentation and can contain any string.
Queue Property – Priority And CPU Affinity
The Argent Queue Engine provides complete CPU time-slicing and true stoichiometric allocation. The key to this is the queue’s priority. Argent queue priorities range from 0 to 255, where 255 is the highest. When the Argent Queue Engine needs to allocate ready work in the typical scarce-CPU case, Ready work from the queue with the highest priority is selected, only after all the Ready jobs in the high priority queue are allocated will Ready jobs be selected from the lower priority queues (do remember that most jobs have a high I/O component – the jobs in the highest priority queue may not be in Ready mode, but in Wait mode; in this case, Ready work from lower priority queues is dispatched first).
Thus a queue’s priority is a simple but effective way to allocate jobs of different priorities – you submit time-critical jobs to the queues with the highest priority, and less-urgent jobs to queues with a lower priority.
The queue’s CPU Affinity properties are listed on the third tab of the queue’s Properties. Combining CPU Affinity and Priority provide a uniquely powerful way to control work allocation and execution.
For example, on a eight-way machine (an SMP server with eight CPUs), a low priority queue can be allocated just the last processor – CPU-7 and a priority of 0, while a high priority queue can be allocated all eight processors and a priority of 255. With Argent’s uniquely powerful allocation facilities work flow can be completely optimized. (This discussion is based on real processors – all virtualization products queer the pitch to some extent or another.)
Queue Property – Max Pending Jobs
This property is the maximum number of jobs the queue can hold in addition to the jobs that are actually executing. When the limit is exceeded additional jobs submitted to the queue will be rejected with an error code of 10 (for a complete list of Argent Queue Engine error codes, see https://help.argent.com/index.php?t=ajs_qe_internal_err_code)
Queue Property – Max Executing Jobs
This property is the maximum number of jobs the queue that can be running at the same time. It’s very common to set this to one to enable jobs to be executed serially – one after the other. Another way to accomplish this is to set the job template in the Argent Scheduler – not the Argent Queue Engine, but the central scheduler – to Only One Job Instance To Be Executed At Any Time, as is shown in the screenshot below.
There are advantages and disadvantages of each approach – the drawbacks of specifying the restriction at the queue level are this limitation applies to all jobs, regardless of their name (that is, regardless of their source in the Argent Scheduler); also this only applies to a one queue on one Argent Queue Engine. In contrast, the single instance option at the Argent Scheduler level is controlled by the Argent Scheduler for all the Argent Queue Engines.
Queue Property – Retain Jobs For
This property specifies how long the job is to be retained by the Argent Queue Engine before it is deleted. The job also consists of the job’s log – the output generated by the job and the execution history of the job.