Commit Graph

13 Commits (d1a8f137c1bcd04bec934dcb62fcbedcd27713d4)

Author SHA1 Message Date
Erik Sipsma 0ddfb544b5 snapshot: cleanup diffApply and prepare for DiffOp
This breaks the giant blob that was the diffApply function into two
separate parts, a differ and an applier, which results in more modular
code that should be easier to follow and easier to make any future
updates to. For example, if we want to optimize by allowing differ and
applier to run in parallel in the future, that's straightforward now.

There are also some fixes that weren't needed for MergeOp, but will be
for DiffOp, such as correctly handling the case where a deletion is
applied that is under parent directories which don't exist yet (the
correct behavior is, surprisingly, to create the parent directories as
that is what the image import/export code ends up doing).

Signed-off-by: Erik Sipsma <erik@sipsma.dev>
2021-12-09 21:21:35 -08:00
Erik Sipsma d73e62f878 Add initial MergeOp implementation.
This consists of just the base MergeOp with support for merging LLB
results that include deletions using hardlinks as the efficient path
and copies as fallback.

Signed-off-by: Erik Sipsma <erik@sipsma.dev>
2021-11-18 11:10:48 -08:00
Paul "TBBle" Hampson cd47186783 Split LocalMounter.Mount into Windows and Unix
Due to current deficiencies in the Windows implementation of
containerd's Mount.Mount, we need different behaviour for mounting on
Windows and Unix platforms.

Specifically:
* Windows mounts can only mount in-place, and hence only one mount
  should be in the list.
* BuildKit doesn't own the mount directory, so should not try and remove
  it on unmount.

Signed-off-by: Paul "TBBle" Hampson <Paul.Hampson@Pobox.com>
2020-07-16 17:13:46 +10:00
Tonis Tiigi a0dead0809 fix possible double release on mountable
Refactor the interface to avoid such issues in the future.

BuildKit own mounts are stateless and not affected but
a different mountable implementation could get confused.

Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
2019-08-16 08:03:16 -07:00
Akihiro Suda 1269bc5682 snapshot: wrap mount err
Signed-off-by: Akihiro Suda <suda.akihiro@lab.ntt.co.jp>
2018-06-02 15:33:26 +09:00
Tonis Tiigi 566e28c174 snapshot: update mounts to mountable interface
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
2018-04-27 17:58:24 -07:00
Akihiro Suda c71a1ca768 bump up containerd (v1.0.0-beta.3)
Signed-off-by: Akihiro Suda <suda.akihiro@lab.ntt.co.jp>
2017-11-13 05:36:59 +00:00
Tonis Tiigi 9f6d9a9e78 exporter: add local exporter
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
2017-08-04 17:12:19 -07:00
Tonis Tiigi eac79f7c7e cache: refactor reference reuse and caching
Replaces previous mutable.Freeze logic with
commits that can live together with mutable data.
Finalize method is added if the implementation
needs to make sure that the immutable ref is
flushed to the driver. Refs are automaitcally
finalized when writable layers are created on
top of them.

Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
2017-07-18 16:01:01 -07:00
Tonis Tiigi 08134677cd worker: runc worker exection
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
2017-06-02 10:20:05 -07:00
Tonis Tiigi 1c5dbe562a cachemanager: size reporting in diskusage
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
2017-05-31 16:45:04 -07:00
Tonis Tiigi 490ac15654 snapshot: add tracking for content blobs
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
2017-05-31 15:09:48 -07:00
Tonis Tiigi f2739f0728 cachemanager: new active creation
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
2017-05-26 10:20:41 -07:00