https://github.com/apache/airflow/pull/12139 added some new params to the scheduler -- we have "cursory" docs for them in the comments in the config file, but we should have a more details docs in the scheduler.rst page.
airflow/jobs/scheduler_job.py
:type max_tis: int
        :return: list[airflow.models.TaskInstance]
        """
        executable_tis: List[TI] = []
        
        
        pools = models.Pool.slots_stats(lock_rows=True, session=session)
        
        
        pool_slots_free = max(0, sum(pool['open'] for pool in pools.values()))
        if pool_slots_free == 0:
            self.log.debug("All pools are full!")
            return executable_tis
        max_tis = min(max_tis, pool_slots_free)
        
        
        
        query = (
            session.query(TI)
            .outerjoin(TI.dag_run)
            .filter(or_(DR.run_id.is_(None), DR.run_type != DagRunType.BACKFILL_JOB))
            .join(TI.dag_model)
            .filter(not_(DM.is_paused))
            .filter(TI.state == State.SCHEDULED)
            .options(selectinload('dag_model'))
            .limit(max_tis)
        )
        task_instances_to_examine: List[TI] = with_row_locks(
            query,
            of=TI,