Lilliput: Minified software patches

Palantir
12 min readintermediate
--
View Original

Overview

Lilliput is a tool developed by Palantir to minimize the size of software patches for customers operating in disconnected environments. By reducing platform release sizes by up to 98% for major releases and 93% for minor releases, Lilliput enables more efficient data transfer and quicker updates for systems without Internet access.

What You'll Learn

1

How to implement Lilliput for minimizing software patch sizes

2

Why minimizing binary sizes is crucial for disconnected environments

3

When to use delta packaging for efficient software updates

Prerequisites & Requirements

  • Understanding of software distribution in disconnected environments
  • Familiarity with Java and packaging tools like tar(optional)

Key Questions Answered

How does Lilliput minimize software patch sizes for disconnected environments?
Lilliput minimizes software patch sizes by calculating the delta between two platform versions, allowing only the changes to be transferred instead of the entire platform. This results in significant size reductions, enabling transfers from multiple DVDs to a single CD, with reductions of up to 98% for major releases.
What are the stages of Lilliput's operation?
Lilliput operates in three stages: disassemble, where it analyzes platform binaries; package, which computes the delta between versions; and assemble, where it reconstructs the platform in a disconnected environment using the delta. This structured approach ensures efficient updates.
What challenges does Lilliput face in minimizing delta file sizes?
Lilliput encounters challenges such as ensuring reproducible builds, handling differences in archive checksums, and managing minimized JavaScript and CSS files that can inflate delta sizes. Addressing these issues is crucial for maintaining efficiency in software updates.

Key Statistics & Figures

Reduction in platform release sizes
up to 98% for major releases, 93% for minor releases
This reduction allows transferring updates from multiple DVDs to a single CD.

Technologies & Tools

Some links below are affiliate links. We may earn a commission if you make a purchase.

Key Actionable Insights

1
Implementing Lilliput can drastically reduce the time and resources spent on software updates in disconnected environments. By focusing on delta packaging, teams can streamline their update processes and reduce the burden on engineers.
This approach is particularly beneficial for organizations that operate in secure environments where traditional update methods are impractical.
2
Regularly review and optimize your build processes to ensure reproducibility. This can help maintain consistent SHA256 checksums, which are essential for Lilliput's delta calculations.
By addressing build reproducibility, you can enhance the effectiveness of Lilliput and minimize unnecessary data transfers.

Common Pitfalls

1
Failing to ensure reproducibility in build artifacts can lead to inconsistent delta calculations, resulting in larger than necessary updates.
This occurs when metadata such as build dates changes with each build, affecting the SHA256 checksums. By configuring build tools properly, teams can avoid this issue.
2
Not managing garbage collection effectively can lead to disk space issues over time as outdated files accumulate.
Implementing a simple garbage collection mechanism is crucial for maintaining filesystem health and preventing storage overflow.

Related Concepts

Software Distribution In Disconnected Environments
Delta Packaging Techniques
Microservice Architecture