Directory Checksum Analysis for Efficient Code Delta Detection

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

Current techniques for identifying similarities and deltas within code are slow and inefficient, particularly in large corpus hierarchies, as they often require checking each file under each node and creating a map of all files/areas of change, which is time-consuming and fails to leverage the benefits of rolling checksums effectively.

Innovation Solution

A code scanning tool that calculates directory level checksums and rolling checksums for both source and target data structures, comparing these to identify the location of changes at the directory and file level, allowing for efficient determination of deltas by focusing on areas of change rather than the entire structure.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Measurement precision

If current techniques check each file under each node and create a map of all files/areas of change, then completeness of change detection is improved, but processing time and efficiency deteriorate

Engineering Contradiction:
Improvecompleteness of change detectionVSAvoidprocessing time
Core Design Contradiction:
Measurement precisionVSLoss of time

Solution Approach 1:

The patent segments the codebase into hierarchical directories and calculates checksums at each directory level. Instead of checking every file individually, the system divides the large corpus into manageable directory segments, computing rolling checksums that can be compared efficiently. This segmentation allows the system to identify which directories contain changes without examining every file, thus maintaining completeness while reducing processing time.

Inventive Principle:
Principle #1Segmentation

Solution Approach 2:

The patent performs preliminary calculation of directory level checksums and rolling checksums before the actual change detection process. By pre-computing these checksums and storing them, the system avoids recalculating them during each comparison operation. This preliminary action enables rapid identification of changes when comparing target code against baseline code, significantly reducing the time required for change detection while maintaining accuracy.

Inventive Principle:
Principle #10Preliminary action

2Measurement precision

If current techniques scan the entire code structure, then accuracy of change identification is improved, but productivity and speed deteriorate

Engineering Contradiction:
Improveaccuracy of change identificationVSAvoidspeed of evaluation
Core Design Contradiction:
Measurement precisionVSProductivity

Solution Approach 1:

The patent extracts only the essential information needed for change detection by calculating rolling checksums at directory levels. Instead of scanning and analyzing every file in the entire code structure, the system extracts checksum values that represent the state of each directory. This extraction approach maintains accuracy in identifying changes while dramatically improving speed by avoiding unnecessary examination of unchanged files and directories.

Inventive Principle:
Principle #2Taking out (Extraction)

Solution Approach 2:

The patent changes the parameter being analyzed from individual file contents to directory-level rolling checksums. By transforming the problem from file-by-file analysis to directory-level checksum comparison, the system achieves the same change identification accuracy but at much higher speed. The rolling checksum parameter captures the essence of directory contents without requiring detailed inspection of each file.

Inventive Principle:
Principle #35Parameter changes

3Reliability

If current techniques analyze large corpus hierarchies in detail, then reliability of security scanning is improved, but complexity of the analysis process deteriorates

Engineering Contradiction:
Improvereliability of security scanningVSAvoidcomplexity of analysis process
Core Design Contradiction:
ReliabilityVSDevice complexity

Solution Approach 1:

The patent implements a nested hierarchical structure where checksums are calculated at multiple levels: individual files, directories, and parent directories. Each level contains checksums of the levels below it, creating a nested structure similar to nested dolls. This nesting allows the system to maintain reliable security scanning by checking specific areas of concern while avoiding the complexity of analyzing the entire hierarchy in detail. The nested checksum structure enables efficient identification of which nested levels contain changes.

Inventive Principle:
Principle #7Nested doll (Nesting)

Data Source

PatentUS11307850B2Efficient change analysis in poly-lingual corpus hierarchies
Publication Date: 2022.04.19 ORACLE INT CORP
  • US11307850B2 patent drawing
  • US11307850B2 patent drawing
  • US11307850B2 patent drawing

AI summary

Techniques to determine deltas of a target data structure against a source data structure. One technique includes obtaining directory level checksums and rolling checksums for a source set of code in a first data structure, obtaining directory level checksums and rolling checksums for a target set of code in a second data structure, comparing the directory level checksums and the rolling checksums obtained for the target set of code against the directory level checksums and the rolling checksums obtained for the source set of code, identifying a location of change data of the target set of code at directory level within the second data structure based on the comparison of the directory level checksums and the rolling checksums obtained for the target set of code against the directory level checksums and the rolling checksums obtained for the source set of code, and outputting the location of the change data.