Compressing the discovery cache
まだ誰も着手していません。
評価
- 難易度
- 4/5
- 見積もり時間
- 3〜5日
- 初心者へのやさしさ
- 48/100
- issue の種類
- 機能追加
- 明瞭さ
- おおむね明確
- 活発さ
- 静か
- 技術スタック
- python
調査の方向性
まず、v2.114.0 のキャッシュサイズをベースラインとして、discovery cache の documents ディレクトリを作成および読み取るコードを特定します。Python 標準ライブラリで利用できる圧縮アプローチを比較し、キャッシュが Docker イメージにどのようにパッケージ化されているかを確認します。キャッシュが大幅に小さくなり、ライブラリから引き続き利用可能で、build または deploy のサイズが改善されれば完了です。
索引モデルが issue の本文から書いたものです。
説明
#2315 shaved off a bit more than 20MB of the discovery cache, by removing the json indentation.
Currently there's still 74.6MB remaining, and it appears to be growing steadily over time (from 81MB on 2023-03-31 to 94MB on 2024-01-15).
So while #2315 definitely helped, I believe that it's a good idea to consider reducing the size even further. I believe that this could significantly improve build/deploy times of the many docker images that use this library. For reference, the current latest python-slim docker image is less than 50MB.
An easy win would be to use compression.
To illustrate: if I manually zip the entire documents directory of 74.6MB in v2.114.0 using the pop-os default gnome archive manager, I end up with an archive of 11.9MB.
Creating a documents.tar.xz in the same way makes this 4.6MB.
It should be possible to achieve similar levels of compression by using Python's standard compression libraries, e.g. zlib, zipfile, or lzma.
- 主要言語
- Python
- スター
- 8.9k
- フォーク
- 2.6k
- 平均マージ
- 2日 1時間
- マージ済み PR(30日)
- 16
コントリビューションガイド
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
googleapis/google-api-python-client のほかの issue
-
難易度 2/5 1〜3時間 初心者へのやさしさ 68/100
-
難易度 2/5 1〜3時間 初心者へのやさしさ 75/100
-
難易度 1/5 1時間未満 初心者へのやさしさ 92/100
-
เมตาแมส オープン
難易度 1/5 1時間未満 初心者へのやさしさ 10/100
-
難易度 4/5 3〜5日 初心者へのやさしさ 52/100
googleapis/google-api-python-client の issue をすべて見る
似ている issue
-
area: harness bug status: needs-triage
難易度 2/5 1〜3時間 初心者へのやさしさ 75/100
Human-Agent-Society/reef#625 ·
-
難易度 2/5 1〜3時間 初心者へのやさしさ 70/100
-
難易度 1/5 1時間未満 初心者へのやさしさ 80/100
learningequality/kolibri#15351 · コメント 2 件 ·
-
難易度 2/5 1〜3時間 初心者へのやさしさ 75/100
-
Name consistency オープン
難易度 2/5 1〜3時間 初心者へのやさしさ 75/100
eellak/triplestore#65 · コメント 1 件 ·