8000 [RFC][WIP] Move to a reference(distribution) based image access and related CAS store. by sgotti · Pull Request #3071 · rkt/rkt · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
8000
This repository was archived by the owner on Feb 24, 2020. It is now read-only.

[RFC][WIP] Move to a reference(distribution) based image access and related CAS store. #3071

Open
wants to merge 10 commits into
base: master
Choose a base branch
from

Conversation

sgotti
Copy link
Contributor
@sgotti sgotti commented Aug 15, 2016

Please see Documentation/proposals/reference_based_image_access_and_cas_store.md where I tried to describe the rationale behind this and the implementation details.

Probably the best thing to understand it better is to build it and try how it works and the UX.

It's based on the distribution concept introduced in #2953.

I'd like to hear you thoughts on this since IMHO is a fundamental step to fix different discrepancies and add support for multiple image types. In this state, more than on the current implementation, I'm just interested on your opinion on the overall idea and effects on the UX.

Notes

Since the store remote table has gone, the code using it has been commented out waiting for the fetcher refactor in #2964 and the introduction of the transport caching. So the http transport caching is disabled.

TODOs

  • Add/Fix some unit and functional tests (due to changed behaviors described in the proposal).
  • Add native docker v2.2 and OCI image initial support (OCI renderer and fetching of an oci image layout Location distribution type and Extend pod manifest to accept other image formats #3039) just to test how it works. Future Name based docker and OCI distributions handling could probably come after the fetchers refactor.
  • Implement, possible migration from the old image store.

/cc @coreos/rkt-maintainers

sgotti added 9 commits August 15, 2016 11:22
This patch implements a new treestore to handle different needs:

* Use a key/value db (boltdb) to save store data. The primary key is the
store id. An additional non unique index on the image digest is created
to easy getting all the treestore generated with the same starting image
(needed for ACI, not needed for OCI)

* Move the default treestore dir to datadir/treestore/

* Handle backward compatibility (to handle prepared/exited/garbage pods
with previous version a work with the new implementation) with the
previous treestore implementation and paths.

* The store will in future be extended to also support other image types
than ACI (like OCI images).
A distribution represents the method to fetch an image starting from an
input string.

Before this concept was introduced, rkt used the ImageType concept, the
ImageType was mapped to the input image string format and internally
covered multiple concepts like distribution, transport and image type
(hidden since all are now appc ACIs).

The distribution concept will be used as the primary information in the
different layers of rkt (fetching but also for references in a CAS/ref
store).

This patch introduces the distribution concept and three kind of
distributions. It just make the smallest required changes to the fetcher
logic to make them work and pass the functional tests. This is the base
for a future fetchers (a future patch will refactor the fetcher logic to
better fit the distribution concept) and store refactors.

See Documentation/devel/distribution.md for a detailed description.
Add some utility functions to interact with the casref store.
@serverwentdown
Copy link

What is the status on this?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants
0