Multi-threaded Plug-in Compilation for APK Packaging Speed

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

The Android system's packaging tool, Ant, is inefficient for multi-plug-in applications, requiring manual compilation and integration, leading to slow packaging processes.

Innovation Solution

A plug-in packaging method that compiles plug-ins using multi-threading based on a base library, storing the compiled plug-ins in the host project resources, and packaging the executable file and resources into an APK packet together.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Productivity

If manual compilation and integration is used for each plug-in, then the packaging process can be completed, but the packaging speed becomes slow and inefficient

Engineering Contradiction:
Improvepackaging speedVSAvoidcompilation time
Core Design Contradiction:
ProductivityVSLoss of time

Solution Approach 1:

The patent divides the monolithic compilation process into independent parallel compilation tasks for each plug-in module. Each plug-in is compiled separately using multi-threading, allowing simultaneous processing of multiple plug-ins without interfering with each other, thus significantly improving overall packaging speed while reducing total compilation time

Inventive Principle:
Principle #1Segmentation

Solution Approach 2:

The patent performs preliminary compilation of plug-ins before the final packaging stage. By compiling all plug-ins in advance using multi-threaded parallel processing and storing them in temporary directories, the system prepares all necessary components beforehand, eliminating sequential compilation delays during the actual packaging process

Inventive Principle:
Principle #10Preliminary action

Data Source

PatentUS10387169B2Plug-in packaging method, device, terminal and storage media
Publication Date: 2019.08.20 PING AN TECH (SHENZHEN) CO LTD
  • US10387169B2 patent drawing
  • US10387169B2 patent drawing

AI summary

A plug-in packaging method, device, terminal and storage media. The method includes: obtaining an executable file created by compiling a source code of a host project; obtaining a base library of the host project that includes at least one compiled public base method; compiling plug-ins required to be packaged respectively by multi-thread based on the base library of the host project; storing the compiled plug-ins required to be packaged into resources of the host project; and packaging the executable file and the resource of the host project together into an apk packet. The above method could improve the packaging speed of the entire apk.