Skip to content

Commit

Permalink
Updated the extensions spec with the new discover routes
Browse files Browse the repository at this point in the history
Signed-off-by: Tejaswini Duggaraju <[email protected]>
Signed-off-by: Vincent Batts <[email protected]>
  • Loading branch information
mnltejaswini authored and vbatts committed Dec 9, 2021
1 parent 0e4c0e6 commit 6fd88c3
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 10 deletions.
10 changes: 5 additions & 5 deletions ext/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,16 +10,16 @@ be emulated for all extensions.

## Table

_notice_: All new `./ext/ext-$name.md` docs MUST be added to this table.
_notice_: All new `./ext/ext-$ns-$name.md` docs MUST be added to this table.

| `$name` | Summary |
| `$ns-$name` | Summary |
|:------------------------:|:----------------------------------------------------:|
| [ext](./ext.md) | Extensions discovering extensions on registry server |

## Name

Extension names MUST be unique. Extensions are specified by
`namespace` aligning with the project, followed by the `extension` provided by the project and last by by the `component`. This constitues the URI segments
`namespace` aligning with the project, followed by the `extension` provided by the project and last by by the `component`. This constitutes the URI segments
of the extension endpoint. Additional options may be passed as parameters to the endpoint.

```http
Expand Down Expand Up @@ -49,8 +49,8 @@ GET /v2/<name>/_<ns>/<ext>/<component>[?<key>=<value>&...]

## Filename

Extention definitions SHOULD be placed under `./ext/`. Extension files
SHOULD follow the `ext-$name.md`. Refer [ext.md](./ext.md) for more details.
Extension definitions SHOULD be placed under `./ext/`. Extension files
SHOULD follow the `ext-$ns-$name.md`. Refer [ext.md](./ext.md) for more details.

## Detail

Expand Down
12 changes: 7 additions & 5 deletions ext/ext.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

## Summary

This base extension is used to discover and return an array of extensions.
This base extension namespace is used to discover and return an array of extensions.

## Reference Explanation

Expand All @@ -12,13 +12,13 @@ extensions.
Registry level extensions may be discovered with a standard GET as follows.

```HTTP
GET /v2/_ext/
GET /v2/_ext/discover
```

Repository level extensions may be discovered with a standard GET as follows.

```HTTP
GET /v2/{name}/_ext/
GET /v2/{name}/_ext/discover
```

The base extension returns an array of supported extensions with details of the
Expand All @@ -31,14 +31,16 @@ Content-Type: application/json
{
"extensions: [
"_<ns>/<ext>/<component>",
{
"name": "_<ns>/<ext>/<component>"
},
]
}
```

### *Extensions* Property Descriptions

- **`extensions`** *array of strings*
- **`extensions`** *array of extension objects with properties like `name`*

This REQUIRED property contains a list of supported extension endpoints.

Expand Down

0 comments on commit 6fd88c3

Please sign in to comment.