Dynamic Thread Pool Sizing for Task Execution

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

Determining the optimal number of concurrent threads for task execution is challenging, as allocating too few threads leads to sequential execution, while too many introduce overhead, and the optimal thread pool size varies across applications and tasks.

Innovation Solution

A system that estimates total execution time for tasks using statistical models based on historical data and machine learning, selecting the number of threads that minimizes execution time while balancing thread management overhead.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Loss of time

If the number of concurrent threads is increased to execute subtasks in parallel, then the task completion time is reduced, but the thread management overhead increases

Engineering Contradiction:
Improvetask completion timeVSAvoidthread management overhead
Core Design Contradiction:
Loss of timeVSDevice complexity

Solution Approach 1:

The system dynamically adjusts the thread pool size parameter based on task characteristics and historical performance data. By changing the number of threads from a fixed value to a dynamically determined parameter, the system optimizes the balance between parallel processing benefits and management overhead for each specific task execution context.

Inventive Principle:
Principle #35Parameter changes

Solution Approach 2:

The system uses historical data about task execution performance to feedback into thread pool size determination. By analyzing past task completion times and outcomes, the system learns optimal thread configurations and uses this feedback to make informed decisions about thread allocation for current tasks, reducing both completion time and unnecessary overhead.

Inventive Principle:
Principle #23Feedback

2Ease of manufacture

If the thread pool size is set to a fixed value, then the system is simple to implement, but it cannot adapt to varying task requirements and execution patterns

Engineering Contradiction:
Improveimplementation simplicityVSAvoidadaptability to task requirements
Core Design Contradiction:
Ease of manufactureVSAdaptability or versatility

Solution Approach 1:

The system transitions from a static, fixed thread pool size to a dynamic configuration that adapts to varying task requirements. The thread pool size is determined on-demand based on task characteristics, historical performance data, and execution patterns, allowing the system to automatically adjust to different workloads while maintaining implementation simplicity through automated decision-making.

Inventive Principle:
Principle #15Dynamics

Solution Approach 2:

The system performs self-optimization by automatically determining the optimal thread pool size based on historical data and task analysis, without requiring manual configuration or external intervention. This self-service capability maintains implementation simplicity while achieving high adaptability to varying task requirements.

Inventive Principle:
Principle #25Self-service

Data Source

PatentUS11593163B2Selecting threads for concurrent processing of data
Publication Date: 2023.02.28 ORACLE INT CORP
  • US11593163B2 patent drawing
  • US11593163B2 patent drawing
  • US11593163B2 patent drawing

AI summary

The embodiments disclosed herein relate to using machine learning to allocate a number of concurrent processes for minimizing the completion time for executing a task having multiple subtasks. Historical data comprising a variety of subtask types with actual completion times is mined to create a set of statistical models for predicting completion time for a type of subtask. To minimize the total time to complete execution of a new task, a certain number of threads is allocated to execute subtasks of the new task. The certain number of threads is determined based on the predicted completion time for the subtasks using the respective statistical model. Threads are assigned to subtasks based on the predicted completion time for the subtasks, and the subtasks assigned to each thread are scheduled for execution.