Using Threads to Run Tasks

SAP ASE assigns tasks to thread pools, and all thread pools have threads. Each thread pool includes a scheduler that assigns tasks to threads.

The scheduler assigns—and unassigns—muliplexed tasks to threads as they perform work. The scheduler assignes RTC tasks to a thread once and it stays with that thread until the work is complete.

SAP ASE contains both system-created and user-created thread pools. All system-defined thread pools start with the syb_ prefix (for example syb_default_pool). Names for user-defined thread pools cannot start with the syb_ prefix and must follow the naming conventions for objects (See “SQL Building Blocks,” in the Reference Manual: Blocks). By default, SAP ASE associates user tasks with the syb_default_pool thread pool. Use sp_bindexeclass to associate one or more tasks with a user-created thread pool.