in YARN scheduling , capacity scheduler will pre-assign the resource of the job. its called queue. so if JOB-1 is long running rater than JOB-2. Then How Resource Manager Decide in Capacity Scheduler, which Job will run on which Queue?
In YARN's Capacity Scheduler, queues are configured with guaranteed resource capacities. Users submit jobs to specific queues, not the Resource Manager deciding where. The Resource Manager then allocates available resources (containers) to jobs within their designated queue, prioritizing based on factors like queue capacity, current usage, and job priority. If a queue is underutilized, it can "borrow" resources from others.