A speculative container registry
Go to file
Tim Burke 127658bbee Rework the stream_blob/stream_object API
Instead of just returning a generator for the data, return a tuple of
(size, generator). This removes the need to call blob_size in get_blob,
and leaves it up to the backend to decide how best to actually get that
information. As a result:

* The swift backend just needs to do a GET, rather than a HEAD then a
  GET. Either way, you should still get a Content-Length.
* Now neither backend has a race wherein a backing blob may get deleted
  between the call to blob_size and stream_blob; previously, we could
  erroneously tell the client the blob exists but is empty.

While we're refactoring, add constants for (and increase) the chunk-read
size, and include Content-Length headers for GET and HEAD responses.

Note that there's a bit of nuance to the return-check now: if the
generator is None, the blob could not be found; if the size is None, the
blob's size could not be determined -- possibly because we got a
chunk-encoded response from swift. In practice, though, expect either
both to be None, or neither.

Change-Id: Ib85cffe17d2d57cc499d863f1b07cfad8ecd401a
2019-10-07 19:41:07 +00:00
playbooks/functional-test Fix merge error in streaming support 2019-10-04 07:59:59 -07:00
tests Add tox configuration and fixe flake8 errors 2019-10-02 18:05:12 +00:00
tools Update test script to match playbook 2019-10-03 10:38:26 -07:00
zuul_registry Rework the stream_blob/stream_object API 2019-10-07 19:41:07 +00:00
.gitignore Add README, license, and Zuul config 2019-09-20 09:53:42 -07:00
.gitreview Added .gitreview 2019-09-19 16:08:44 +00:00
.stestr.conf Add tox configuration and fixe flake8 errors 2019-10-02 18:05:12 +00:00
.zuul.yaml Add tox configuration and fixe flake8 errors 2019-10-02 18:05:12 +00:00
bindep.txt Fix container image build 2019-10-02 13:50:42 -04:00
COPYING Add README, license, and Zuul config 2019-09-20 09:53:42 -07:00
Dockerfile Fix container image build 2019-10-02 13:50:42 -04:00
README.rst Add README, license, and Zuul config 2019-09-20 09:53:42 -07:00
requirements.txt Fix container image build 2019-10-02 13:50:42 -04:00
setup.cfg Fix container image build 2019-10-02 13:50:42 -04:00
setup.py Initial implementation 2019-10-01 08:09:55 -07:00
test-requirements.txt Add tox configuration and fixe flake8 errors 2019-10-02 18:05:12 +00:00
tox.ini Add tox configuration and fixe flake8 errors 2019-10-02 18:05:12 +00:00

Zuul Registry

This is a container image registry for use with the Zuul project gating system.

The defining feature of this registry is support for shadowing images: it allows you to upload a local version of an image to use instead of an upstream version. If you pull an image from this registry, it will provide the local version if it exists, or the upstream if it does not.

This makes it suitable for use in a Zuul-driven speculative image pipeline.

The latest documentation for Zuul is published at: https://zuul-ci.org/docs/

Getting Help

There are two Zuul-related mailing lists:

zuul-announce

A low-traffic announcement-only list to which every Zuul operator or power-user should subscribe.

zuul-discuss

General discussion about Zuul, including questions about how to use it, and future development.

You will also find Zuul developers in the #zuul channel on Freenode IRC.

Contributing

To browse the latest code, see: https://opendev.org/zuul/zuul-registry To clone the latest code, use git clone https://opendev.org/zuul/zuul-registry

Bugs are handled at: https://storyboard.openstack.org/#!/project/zuul/zuul-registry

Suspected security vulnerabilities are most appreciated if first reported privately following any of the supported mechanisms described at https://zuul-ci.org/docs/zuul/user/vulnerabilities.html

Code reviews are handled by gerrit at https://review.opendev.org

After creating a Gerrit account, use git review to submit patches. Example:

# Do your commits
$ git review
# Enter your username if prompted

Join #zuul on Freenode to discuss development or usage.

License

Zuul-registry is free software licensed under the General Public License, version 3.0.

Python Version Support

Zuul requires Python 3. It does not support Python 2.