Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[WIP][V3] Add the new schema v3alpha1. #5695

Closed
wants to merge 2 commits into from

Conversation

yuwenma
Copy link
Contributor

@yuwenma yuwenma commented Apr 16, 2021

Related: #5673

Description
his schema contains the main fields to support the new skaffold render and deployment, powered by kpt. Some config names may change based on the the user survey results.

For reviewers:

  • Render: Top tier section. It contains the basic render functions generate, validate and trasform. It does not include the helmcharts (generate) and kpt package magement yet, which will be added on following CLs.
  • Deploy: Simplified. The deployers (helm, kubectl, kpt, kustomize) are removed. Some helm and kubectl features, and flags are not covered in the deploy section yet. Will be added in following CLs.
  • v2 and v3 versions are not compatible. So the upgrade functions do not need to change. But we will add more checks on other codes to guarantee the v2 and v3 are not mixed (especially in multi-config mode).
  • Generated doc via "go run hack/schemas/main.go".

@yuwenma yuwenma requested a review from a team as a code owner April 16, 2021 03:23
@google-cla google-cla bot added the cla: yes label Apr 16, 2021
@yuwenma yuwenma added the area/v3 V3 label Apr 16, 2021
@codecov
Copy link

codecov bot commented Apr 16, 2021

Codecov Report

Merging #5695 (52f83c0) into master (863eaad) will decrease coverage by 0.23%.
The diff coverage is 0.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #5695      +/-   ##
==========================================
- Coverage   70.44%   70.21%   -0.24%     
==========================================
  Files         413      415       +2     
  Lines       15934    16051     +117     
==========================================
+ Hits        11225    11270      +45     
- Misses       3877     3949      +72     
  Partials      832      832              
Impacted Files Coverage Δ
pkg/skaffold/schema/v3alpha1/config.go 0.00% <0.00%> (ø)
pkg/skaffold/schema/v3alpha1/upgrade.go 0.00% <0.00%> (ø)
pkg/skaffold/schema/versions.go 82.41% <ø> (ø)
cmd/skaffold/app/flags/image.go 72.97% <0.00%> (-11.03%) ⬇️
pkg/skaffold/build/scheduler.go 92.98% <0.00%> (-1.36%) ⬇️
cmd/skaffold/app/cmd/flags.go 89.02% <0.00%> (ø)
pkg/skaffold/config/options.go 100.00% <0.00%> (ø)
pkg/skaffold/schema/latest/config.go 58.82% <0.00%> (ø)
... and 3 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 863eaad...52f83c0. Read the comment docs.

This schema contains the main fields to support the new skaffold render and deployment, powered by kpt. Some config names may change based on the the user survey results.

For reviewers:
 - `Render`: Top tier section. It contains the basic render functions `generate`, `validate` and `trasform`. It does not include the helmcharts (generate) and kpt package magement yet, which will be added on following CLs.
 - `Deploy`: Simplified. The deployers (helm, kubectl, kpt, kustomize) are removed. Some helm and kubectl features, and flags are not covered in the `deploy` section yet. Will be added in following CLs.
 -  v2 and v3 versions are not compatible. So the `upgrade` functions do not need to change. But we will add more checks on other codes to guarantee the v2 and v3 are not mixed (especially in multi-config mode).
 -  Generated doc via "go run hack/schemas/main.go".
@yuwenma yuwenma added this to the v1.23.0 milestone Apr 16, 2021
Copy link
Contributor

@MarlonGamez MarlonGamez left a comment

Choose a reason for hiding this comment

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

This is looking good, but we need to modify hack/check-samples here to not treat this config as the latest released one. Right now in hack/versions/cmd/latest-released/version.go it's grabbing the latest version by doing schema.SchemaVersions[len(schema.SchemaVersions)-2].APIVersion, which will hit v3alpha1 since that slice now looks like

...
        {v2beta13.Version, v2beta13.NewSkaffoldConfig, true},
        {v2beta14.Version, v2beta14.NewSkaffoldConfig, true},
	{v3alpha1.Version, v3alpha1.NewSkaffoldConfig, false},
	{latest.Version, latest.NewSkaffoldConfig, true},
}

pkg/skaffold/schema/versions.go Outdated Show resolved Hide resolved
@yuwenma yuwenma changed the title [V3] Add the new schema v3alpha1. [WIP][V3] Add the new schema v3alpha1. Apr 23, 2021
@aaron-prindle aaron-prindle modified the milestones: v1.23.0, v1.24.0 Apr 29, 2021
@tejal29 tejal29 requested review from nkubala and removed request for nkubala April 29, 2021 21:29
@yuwenma
Copy link
Contributor Author

yuwenma commented Apr 29, 2021

Deprecated.

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

Successfully merging this pull request may close these issues.

5 participants