Skip to content
Closed
Changes from 1 commit
Commits
Show all changes
24 commits
Select commit Hold shift + click to select a range
2848dfe
Describe the pull workflow
pmengelbert Jun 16, 2020
5404eba
mini update 2: new table of contents
jdolitsky Jun 10, 2020
5f59ff7
remove top-level defintions section
jdolitsky Jun 26, 2020
2ded6d5
mini update 3: fill in overview section
jdolitsky Jun 10, 2020
2acd0fb
mini update 4: fill in definitions section
jdolitsky Jun 10, 2020
922acfd
update digest and content definitions
jdolitsky Jun 26, 2020
0b74a41
mini update 5: fill in conformance section (sans workflows)
jdolitsky Jun 10, 2020
43fa878
mini update 5: fill in conformance section (sans workflows)
jdolitsky Jun 10, 2020
a367759
Describe the pull workflow
pmengelbert Jun 16, 2020
515e36c
Merge branch 'mini-update-5' of github.com:bloodorangeio/distribution…
pmengelbert Jun 29, 2020
07e23a1
Merge branch 'mini-update-6' of github.com:bloodorangeio/distribution…
pmengelbert Jun 29, 2020
1072ba0
Merge branch 'mini-update-5' of github.com:bloodorangeio/distribution…
jdolitsky Jul 16, 2020
801afc1
Adjust grammar
pmengelbert Jul 29, 2020
4933b31
Describe push workflow
pmengelbert Jun 16, 2020
d44db2d
Fix typos and English errors
pmengelbert Jul 29, 2020
b5adeb6
Add content discovery section to spec
pmengelbert Jun 29, 2020
4797796
Make small language improvements
pmengelbert Jul 29, 2020
1e90b55
Describe content management workflow
pmengelbert Jun 29, 2020
c03bb79
Make small language fixes
pmengelbert Jul 29, 2020
a2b8c84
Add endpoint table to spec
pmengelbert Jul 22, 2020
08f7078
Add summary and place method into its own column
pmengelbert Jul 29, 2020
ecf4822
Add 'error codes' section
pmengelbert Jul 22, 2020
35df229
Add references and links to endpoint IDs
pmengelbert Jul 29, 2020
a4ce092
Update definitions
pmengelbert Jul 29, 2020
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
42 changes: 41 additions & 1 deletion spec.md
Original file line number Diff line number Diff line change
Expand Up @@ -285,7 +285,47 @@ An attempt to pull a nonexistent repository MUST return response code `404 Not F

#### Content Discovery

TODO: describe the Content Discovery category and the high-level details
Content Discovery provides a way of discovering which tags are available for a given repository.

To fetch the list of tags, perform a `GET` request to a path in the following format:
`/v2/<name>/tags/list`

`<name>` is the namespace of the repository. Assuming a repository is found, Content Discovery endpoints MUST return a
`200 OK` response code. The list of tags MAY be empty, if there are no tags on the repository. If the list is not empty,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit - maybe drop the comma after 'empty'?

the tags MUST be in lexical order (i.e. case-insensitive alphanumeric order).

Upon success, the response MUST be a json body in the following format:
```json
{
"name": "<name>",
"tags": [
"<tag1>",
"<tag2>",
"<tag3>"
]
}
```

`<name>` is the namespace of the repository, and `<tag1>`, `<tag2>`, and `<tag3>` are each tags on the repository.

In addition to fetching the whole list of tags, a subset of the tags can be fetched by providing the `n` query parameter.
In this case, the path will look like the following:
`/v2/<name>/tags/list?n=<int>`

`<name>` is the namespace of the repository, and `<int>` is an integer specifying the number of tags requested. The response
to such a request MAY return fewer than `<int>` results, but ONLY when the total number of tags attached to the repository
is less than `<int>`. Otherwise, the response MUST include `<int>` results. Without the `last` query parameter (described
next), the list returned will start at the beginning of the list and include `<int>` results. As above, the tags MUST be
in lexical order.

The `last` query parameter provides further means for limiting the number of tags. It is used exclusively in combination with the
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

last seems weird. I know startafter is longer, but it's more correct, no?

`n` parameter:
`/v2/<name>/tags/list?n=<int>&last=<tagname>`

`<name>` is the namespace of the repository, `<int>` is the number of tags requested, and `<tagname>` is the *value* of
the last tag. `<tagname>` MUST NOT be an index, but rather it MUST be a proper tag. A request of this sort will return
up to `<int>` tags, beginning non-inclusively with `<tagname>`. That is to say, `<tagname>` will not be included in the
results, but up to `<int>` tags *after* `<tagname>` will be returned. The tags MUST be in lexical order.

#### Content Management

Expand Down