Add swagger.yaml and generate a few types from the spec#27117
Merged
thaJeztah merged 7 commits intomoby:masterfrom Oct 22, 2016
Merged
Add swagger.yaml and generate a few types from the spec#27117thaJeztah merged 7 commits intomoby:masterfrom
thaJeztah merged 7 commits intomoby:masterfrom
Conversation
Member
Author
Member
Author
|
I guess the types could also be generated from a |
2abf33e to
3cb9d36
Compare
Contributor
|
Big 👍 on the proposed change. |
44ef526 to
0c12029
Compare
Member
Author
|
@mlaventure the generated types are now using normal |
Contributor
|
It looks some much cleaner, thanks! They're not go-lint proof, but I see we added them to the skip list, LGTM |
Contributor
|
design LGTM |
Member
|
ping @dnephin can you rebase? Then I think we should be ready to go. We may need to describe the process (i.e. when to generate, integrate into CI etc) |
Generate Volume type from the swagger.yaml Add makefile target for generating the models Signed-off-by: Daniel Nephin <[email protected]>
Signed-off-by: Daniel Nephin <[email protected]>
and rename it to a more appropriate name ImageSummary. Signed-off-by: Daniel Nephin <[email protected]>
Signed-off-by: Daniel Nephin <[email protected]>
Signed-off-by: Daniel Nephin <[email protected]>
Signed-off-by: Daniel Nephin <[email protected]>
generation fixed some comments. Signed-off-by: Daniel Nephin <[email protected]>
Member
Author
|
rebased |
Member
Author
|
Yes, this also needs CI integration. It should work the same way as our vendor check (but it runs much faster). |
Contributor
|
LGTM |
Member
|
looks like we have enough LGTM's and CI is 💚, merging |
dnephin
pushed a commit
to dnephin/docker
that referenced
this pull request
Apr 17, 2017
Add swagger.yaml and generate a few types from the spec
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Related issues: #22931, #5893, docker-archive-public/docker.engine-api#77
The swagger spec was developed here: https://github.com/bfirsh/docker-api-reference/blob/master/swagger.yaml. That repo include some validation checks which I think we should also include if this PR is merged.
The swagger spec will initially be used:
api/typesEventually we should also be able to generate
api/server/router/*and most ofclient/*from the spec. Most of the code in those packages is very boilerplate, and would be a lot more consistent if it were generated from a spec.