tvl-depot/tvix/nar-bridge
Connor Brewster 85421b7f97 feat(tvix/store/nar-info): Support async blob upload
Right now all blob uploads are performed synchronously, this means if a
NAR contains many small files, the import time is dominated by round
trip time to the blob service. For small files, we can buffer them in
memory and upload them asynchronously to the blob service. Before
returning we make sure to join all the uploads to make sure they
complete successfully before responding OK.

This reduces time to import a bash-interactive closure on my machine
from 1m19s to 7s.

Change-Id: Ica3695c159e6c8ad8769281ac20d037e3143e856
Reviewed-on: https://cl.tvl.fyi/c/depot/+/10679
Tested-by: BuildkiteCI
Reviewed-by: flokli <flokli@flokli.de>
Autosubmit: Connor Brewster <cbrewster@hey.com>
2024-01-23 17:01:16 +00:00
..
cmd/nar-bridge-http feat(tvix/store/nar-bridge): Setup OpenTelemetry 2024-01-23 15:50:53 +00:00
pkg feat(tvix/store/nar-info): Support async blob upload 2024-01-23 17:01:16 +00:00
testdata fix(tvix/nar-bridge): Fix directory stack tracking 2023-09-17 13:34:00 +00:00
.gitignore feat(tvix/nar-bridge): add nar-bridge-pathinfo command 2023-10-05 15:02:12 +00:00
default.nix feat(tvix/store/nar-info): Support async blob upload 2024-01-23 17:01:16 +00:00
go.mod feat(tvix/store/nar-info): Support async blob upload 2024-01-23 17:01:16 +00:00
go.sum feat(tvix/store/nar-info): Support async blob upload 2024-01-23 17:01:16 +00:00
README.md feat(tvix/nar-bridge): init 2023-09-17 13:24:53 +00:00

//tvix/nar-bridge

This exposes a HTTP Binary cache interface (GET/HEAD/PUT requests) for a tvix- store.

It can be used to configure a tvix-store as a substitutor for Nix, or to upload store paths from Nix via nix copy into a tvix-store.