惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

Jina AI
Jina AI
C
Cybersecurity and Infrastructure Security Agency CISA
美团技术团队
J
Java Code Geeks
博客园 - 聂微东
罗磊的独立博客
Hugging Face - Blog
Hugging Face - Blog
博客园 - 【当耐特】
小众软件
小众软件
博客园 - 三生石上(FineUI控件)
Apple Machine Learning Research
Apple Machine Learning Research
大猫的无限游戏
大猫的无限游戏
让小产品的独立变现更简单 - ezindie.com
让小产品的独立变现更简单 - ezindie.com
博客园 - 叶小钗
雷峰网
雷峰网
爱范儿
爱范儿
阮一峰的网络日志
阮一峰的网络日志
V
Visual Studio Blog
腾讯CDC
酷 壳 – CoolShell
酷 壳 – CoolShell
有赞技术团队
有赞技术团队
Google DeepMind News
Google DeepMind News
The Cloudflare Blog
博客园 - Franky
Engineering at Meta
Engineering at Meta
IT之家
IT之家
Last Week in AI
Last Week in AI
Recent Announcements
Recent Announcements
The Register - Security
The Register - Security
Application and Cybersecurity Blog
Application and Cybersecurity Blog
T
The Exploit Database - CXSecurity.com
I
Intezer
V
Vulnerabilities – Threatpost
Simon Willison's Weblog
Simon Willison's Weblog
NISL@THU
NISL@THU
S
Security @ Cisco Blogs
T
Tenable Blog
cs.CV updates on arXiv.org
cs.CV updates on arXiv.org
Project Zero
Project Zero
H
Hacker News: Front Page
SecWiki News
SecWiki News
L
LINUX DO - 最新话题
Hacker News: Ask HN
Hacker News: Ask HN
Forbes - Security
Forbes - Security
C
CERT Recently Published Vulnerability Notes
T
Threatpost
N
News and Events Feed by Topic
Webroot Blog
Webroot Blog
Recent Commits to openclaw:main
Recent Commits to openclaw:main
V2EX - 技术
V2EX - 技术

Alexander Larsson

Testing composefs in Silverblue Announcing composefs 1.0 Composefs state of the union Using Composefs in OSTree Quadlet, an easier way to run system containers Compatibility in a sandboxed world Putting container updates on a diet Introducing GVariant schemas Gthree – ready to play
Scaling Flathub 100x
alexl · 2020-11-21 · via Alexander Larsson

Skip to content

Flatpak relies on OSTree to distribute apps. This means that flatpak repositories, such as Flathub, are really just OSTree repositories. At the core of an OSTree repository is the summary file, which describes the content of the repository.  This is similar to the metadata that “apt-get update” downloads.

Every time you do an flatpak install it needs the information in the summary file. The file is cached between operations, but any time the repository changes the local copy needs to be updated.

This can be pretty slow, with Flathub having around 1000 applications (times 4 architectures). In addition, the more applications there are, the more likely it is that one has been updated since the last time which means you need to update.

This isn’t yet a major problem for Flathub, but its just a matter of time before it is, as apps keep getting added:

This is particularly problematic if we want to add new architectures, as that multiplies the number of applications.

So, the last month I’ve been working in OSTree and Flatpak to solve this by changing the flatpak repository format. Today I released Flatpak 1.9.2 which is the first version to support the new format, and Flathub is already serving it (and the old format for older clients).

The new format is not only more efficient, it is also split by architecture meaning each user only downloads a subset of the total summary. Additionally there is a delta-based incremental update method for updating from a previous version.

Here are some data for the latest Flathub summary:

  • Original summary: 6,6M  (1.8M compressed)
  • New (x86-64) summary: 2.7M (554k compressed)
  • Delta from previous summary: 20k

So, if you’re able to use the delta, then it needs 100 times less network bandwidth compared to the original (compressed) summary and will be much faster.

Also, this means we can finally start looking at supporting other architectures in Flathub, as doing so will not inconvenience users of the major architectures.

To the future and beyond!