Parallel Join Optimization for Skewed Data Distribution

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

Massively parallel processing systems face performance degradation due to data skew during parallel joins, leading to excessive load on some processing units and potential 'out of spool space' errors, especially when dealing with large and skewed tables where traditional redistribution or duplication mechanisms are inefficient.

Innovation Solution

The system optimizes join operations by redistributing one relation substantially equally among processing modules and duplicating the other relation, ensuring that none of the processing units exceed spool limits and allowing for balanced processing, thereby reducing spool space requirements and improving system performance.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Productivity

If hash redistribution is used to distribute rows to processing units, then parallel join operations can be performed efficiently when data is evenly distributed, but processing units experience excessive load and spool space exhaustion when data skew is present

Engineering Contradiction:
Improveparallel join operation efficiencyVSAvoidspool space availability
Core Design Contradiction:
ProductivityVSReliability

Solution Approach 1:

The patent segments the data distribution strategy by dividing rows into two categories: frequently occurring join column values are duplicated across all processing units, while less frequent values are redistributed using hash functions. This segmentation allows the system to handle skewed data by ensuring hot data is available everywhere while maintaining efficient parallel processing for less frequent values.

Inventive Principle:
Principle #1Segmentation

Solution Approach 2:

The patent applies local quality by treating different data segments differently based on their characteristics. Frequently occurring values (hot data) receive special treatment through duplication to ensure they are locally available at each processing unit, while less frequent values use standard hash redistribution. This localized optimization resolves the contradiction by adapting the distribution strategy to the specific characteristics of each data segment.

Inventive Principle:
Principle #3Local quality

2Ease of operation

If table duplication is used to handle skewed data, then processing units can access all join column values locally, but spool space requirements increase significantly

Engineering Contradiction:
Improvelocal data access capabilityVSAvoidspool space consumption
Core Design Contradiction:
Ease of operationVSQuantity of substance

Solution Approach 1:

The patent applies partial action by duplicating only the necessary portion of data - specifically, only the rows containing frequently occurring join column values are duplicated across all processing units. This partial duplication provides the local access capability needed to handle skew while avoiding the excessive spool space consumption that would result from duplicating entire tables.

Inventive Principle:
Principle #16Partial or excessive action

Solution Approach 2:

The patent changes the parameter of data distribution by dynamically determining which rows to duplicate based on the frequency of their join column values. Instead of uniformly duplicating all rows or using fixed hash redistribution, the system adjusts the distribution strategy based on data characteristics, duplicating only those rows where the join column values appear frequently enough to justify the spool space expenditure.

Inventive Principle:
Principle #35Parameter changes

3Quantity of substance

If partial redistribution and partial duplication are used for known skewed data, then spool space requirements are reduced, but the approach is disadvantageous when relations are of similar size

Engineering Contradiction:
Improvespool space requirementVSAvoidapplicability to different data scenarios
Core Design Contradiction:
Quantity of substanceVSAdaptability or versatility

Solution Approach 1:

The patent incorporates feedback by analyzing the frequency distribution of join column values and using this information to dynamically determine the optimal mix of duplication and redistribution. The system evaluates the data characteristics and adjusts the distribution strategy accordingly, ensuring that partial duplication is applied only when beneficial and that the approach adapts to different data scenarios including cases where relations are of similar size.

Inventive Principle:
Principle #23Feedback

Solution Approach 2:

The patent applies dynamics by making the data distribution strategy adaptive rather than static. The system dynamically determines which rows to duplicate and which to redistribute based on the observed frequency of join column values. This dynamic approach allows the system to automatically adjust to different data scenarios, including skewed data, evenly distributed data, and cases where relations are of similar size, without requiring manual configuration.

Inventive Principle:
Principle #15Dynamics

Data Source

PatentUS8099409B2System, method, and computer-readable medium for duplication optimization for parallel join operations on similarly large skewed tables
Publication Date: 2012.01.17 TERADATA CORP
  • US8099409B2 patent drawing
  • US8099409B2 patent drawing
  • US8099409B2 patent drawing

AI summary

A system, method, and computer-readable medium for optimizing join operations in a parallel processing system are provided. A respective set of rows of a first table and a second table involved in a join operation are distributed to each of a plurality of processing modules. The join operation comprises a join on a first column of the first table and a second column of the second table. Each of the plurality of processing modules redistributes at least a portion of the rows of the first table distributed thereto substantially equally among the other processing modules and duplicates at least a portion of the rows of the second table distributed thereto among the plurality of processing modules. The disclosed optimization mechanisms provide for reduced spool space requirements for execution of the parallel join operation.