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

Make TemplateKind required #5580

Merged
merged 9 commits into from
May 22, 2023
Merged

Conversation

kachawla
Copy link
Contributor

@kachawla kachawla commented May 19, 2023

Description

Added a new property for recipe templateKind in here #5575. Switching the property from optional to required and updating functional test templates.

Issue reference

Fixes Support multiple template types user story under https://github.com/project-radius/radius/issues/4446.

Checklist

Please make sure you've completed the relevant tasks for this PR, out of the following list:

  • Code compiles correctly
  • Adds necessary unit tests for change
  • Adds necessary E2E tests for change
  • Unit tests passing
  • Extended the documentation / Created issue for it -- Created issue

@kachawla kachawla requested a review from a team as a code owner May 19, 2023 19:40
@github-actions
Copy link

You are editing files which require a docs update. Please ensure you've made the appropriate changes to the docs and submitted a PR.

  • Swagger changes require reference edge docs to be updated here
  • Make sure to create a branch and submit a PR into the edge branch instead of the default latest branch, as the swagger changes will not be available until the next release.

For more information on contributing to docs please visit https://docs.radapp.dev/contributing/docs/.

@github-actions
Copy link

github-actions bot commented May 19, 2023

Radius functional test overview

🔍 Go to test action run

Name Value
Repository project-radius/radius
Commit ref 8144b29
Unique ID 71c0da12ce
Image tag pr-71c0da12ce
Click here to see the list of tools in the current test run
  • KinD: v0.18.0
  • Dapr: 1.10.0
  • Azure KeyVault CSI driver: 1.4.2
  • Azure Workload identity webhook: 1.0.0
  • recipe location radiusdev.azurecr.io/test/functional/corerp/recipes/<name>:pr-71c0da12ce
  • appcore-rp test image location: radiusdev.azurecr.io/appcore-rp:pr-71c0da12ce
  • ucp test image location: radiusdev.azurecr.io/ucpd:pr-71c0da12ce

Test Status

⌛ Building Radius and pushing container images for functional tests...
✅ Container images build succeeded
⌛ Publishing Bicep Recipes for functional tests...
✅ Recipe publishing succeeded
⌛ Starting samples functional tests...
⌛ Starting corerp functional tests...
⌛ Starting ucp functional tests...
❌ Test tool installation for samples failed. Please check the logs for more details
❌ Failed to install Radius for samples functional test. Please check the logs for more details
❌ samples functional test failed. Please check the logs for more details
❌ Test tool installation for corerp failed. Please check the logs for more details
❌ Failed to install Radius for corerp functional test. Please check the logs for more details

@github-actions
Copy link

github-actions bot commented May 19, 2023

Test Results

2 722 tests  +5   2 715 ✔️ +5   1m 55s ⏱️ -1s
   243 suites +1          7 💤 ±0 
       1 files   ±0          0 ±0 

Results for commit c20accd. ± Comparison against base commit d8cce54.

This pull request removes 6 and adds 11 tests. Note that renamed tests count towards both.
github.com/project-radius/radius/pkg/armrpc/frontend/controller ‑ TestValidateEtag_IfMatch/be4e9711-545b-4d2b-9886-5bc1066e3beb
github.com/project-radius/radius/pkg/armrpc/frontend/controller ‑ TestValidateEtag_IfMatch/be4e9711-545b-4d2b-9886-5bc1066e3beb#01
github.com/project-radius/radius/pkg/cli/cmd/recipe/list ‑ Test_Run/List_recipes_linked_to_the_environment
github.com/project-radius/radius/pkg/cli/cmd/recipe/list ‑ Test_Run/List_recipes_linked_to_the_environment/Success
github.com/project-radius/radius/pkg/cli/cmd/recipe/show ‑ Test_Run/Show_recipes_details
github.com/project-radius/radius/pkg/cli/cmd/recipe/show ‑ Test_Run/Show_recipes_details/Success
github.com/project-radius/radius/pkg/armrpc/frontend/controller ‑ TestValidateEtag_IfMatch/74ff8805-6aa3-418e-ac5c-21b1bc24431a
github.com/project-radius/radius/pkg/armrpc/frontend/controller ‑ TestValidateEtag_IfMatch/74ff8805-6aa3-418e-ac5c-21b1bc24431a#01
github.com/project-radius/radius/pkg/cli/cmd/recipe/list ‑ Test_Run/List_recipes_linked_to_the_environment_-_Success
github.com/project-radius/radius/pkg/cli/cmd/recipe/list ‑ Test_Run/List_recipes_linked_to_the_environment_-_empty_template_kind
github.com/project-radius/radius/pkg/cli/cmd/recipe/register ‑ Test_Validate/Register_Command_without_template_kind
github.com/project-radius/radius/pkg/cli/cmd/recipe/show ‑ Test_Run/Show_recipe_details_-_empty_template_kind
github.com/project-radius/radius/pkg/cli/cmd/recipe/show ‑ Test_Run/Show_recipes_details_-_Success
github.com/project-radius/radius/pkg/corerp/api/v20220315privatepreview ‑ TestConvertDataModelToVersioned_EmptyTemplateKind
github.com/project-radius/radius/pkg/corerp/api/v20220315privatepreview ‑ TestConvertVersionedToDataModel/environmentresource-missing-templatekind.json
github.com/project-radius/radius/pkg/corerp/api/v20220315privatepreview ‑ TestEnvironmentRecipePropertiesConvertDataModelToVersioned_EmptyTemplateKind
…

♻️ This comment has been updated with latest results.

@github-actions
Copy link

63.9

For the detailed report, please go to Checks tab, click Build and Test, and then download unit_test_coverage artifact at the bottom of build page.

  • Your PR branch coverage: 63.9 %
  • main branch coverage: 63.9 %
  • diff coverage: 0 %

The coverage result does not include the functional test coverage.

@github-actions
Copy link

You are editing files which require a docs update. Please ensure you've made the appropriate changes to the docs and submitted a PR.

  • Swagger changes require reference edge docs to be updated here
  • Make sure to create a branch and submit a PR into the edge branch instead of the default latest branch, as the swagger changes will not be available until the next release.

For more information on contributing to docs please visit https://docs.radapp.dev/contributing/docs/.

@github-actions

This comment has been minimized.

@github-actions
Copy link

63.9

For the detailed report, please go to Checks tab, click Build and Test, and then download unit_test_coverage artifact at the bottom of build page.

  • Your PR branch coverage: 63.9 %
  • main branch coverage: 63.9 %
  • diff coverage: 0 %

The coverage result does not include the functional test coverage.

Comment on lines 501 to +498
"required": [
"templateKind",
Copy link
Contributor Author

Choose a reason for hiding this comment

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

@AaronCrawfis Just a heads up - templateKind will be a required parameter after this is merged

@github-actions
Copy link

You are editing files which require a docs update. Please ensure you've made the appropriate changes to the docs and submitted a PR.

  • Swagger changes require reference edge docs to be updated here
  • Make sure to create a branch and submit a PR into the edge branch instead of the default latest branch, as the swagger changes will not be available until the next release.

For more information on contributing to docs please visit https://docs.radapp.dev/contributing/docs/.

@radius-project radius-project deleted a comment from github-actions bot May 19, 2023
@github-actions

This comment has been minimized.

@github-actions
Copy link

63.9

For the detailed report, please go to Checks tab, click Build and Test, and then download unit_test_coverage artifact at the bottom of build page.

  • Your PR branch coverage: 63.9 %
  • main branch coverage: 63.9 %
  • diff coverage: 0 %

The coverage result does not include the functional test coverage.

@github-actions
Copy link

github-actions bot commented May 19, 2023

⌛ Building Radius and pushing container images for functional tests...

✅ Container images build succeeded
⌛ Publishing Bicep Recipes for functional tests...
✅ Recipe publishing succeeded
⌛ Starting ucp functional tests...
⌛ Starting corerp functional tests...
⌛ Starting samples functional tests...
❌ Test tool installation for samples failed. Please check the logs for more details
❌ Failed to install Radius for samples functional test. Please check the logs for more details
❌ Test tool installation for corerp failed. Please check the logs for more details
❌ Failed to install Radius for corerp functional test. Please check the logs for more details
❌ corerp functional test failed. Please check the logs for more details
⌛ Starting ucp functional tests...
⌛ Starting corerp functional tests...
⌛ Starting samples functional tests...
❌ Test tool installation for samples failed. Please check the logs for more details
❌ Failed to install Radius for samples functional test. Please check the logs for more details
❌ samples functional test failed. Please check the logs for more details
⌛ Starting ucp functional tests...
⌛ Starting corerp functional tests...
❌ Test tool installation for ucp failed. Please check the logs for more details
❌ Failed to install Radius for ucp functional test. Please check the logs for more details
❌ ucp functional test failed. Please check the logs for more details
❌ Test tool installation for corerp failed. Please check the logs for more details
❌ Failed to install Radius for corerp functional test. Please check the logs for more details
❌ corerp functional test failed. Please check the logs for more details
⌛ Starting ucp functional tests...
⌛ Starting samples functional tests...
⌛ Starting corerp functional tests...
❌ Test tool installation for ucp failed. Please check the logs for more details
❌ Failed to install Radius for ucp functional test. Please check the logs for more details
❌ ucp functional test failed. Please check the logs for more details

})
}
// TODO Check to ensure backwards compatibility with existing environments.
// Remove this in next release once users have migrated their existing environments.
Copy link
Contributor

Choose a reason for hiding this comment

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

If there's work to do in the next release can we use an issue to track this? I think the TODO in code is fine and helpful, but ideally it will reference an issue as well so we can find the relevant code.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Sure, will create an issue and update the comment. I was planning to delete it myself next week after the release so that it doesn't linger around that's why just left it at TODO.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Updated

@@ -36,13 +36,13 @@ You can specify parameters using the '--parameter' flag ('-p' for short). Parame
`,
Example: `
# Add a recipe to an environment
rad recipe register cosmosdb -e env_name -w workspace --template-path template_path --link-type Applications.Link/mongoDatabases
rad recipe register cosmosdb -e env_name -w workspace --template-kind bicep --template-path template_path --link-type Applications.Link/mongoDatabases
Copy link
Contributor

Choose a reason for hiding this comment

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

Rando question for both @kachawla @jasonviviano @AaronCrawfis - would it be possible to infer the template kind in the CLI based on the template path? Non-blocking for this PR.

Copy link
Contributor Author

@kachawla kachawla May 22, 2023

Choose a reason for hiding this comment

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

I thought about that in general for env authoring experience. We could technically do this for current point in time requirements - if the path points to a container registry then it is Bicep else Terraform, but I don't think it is a reliable solution if we plan to support combination of different formats and multiple storage options for recipes in every format. Would like to hear from Aaron/Jason on what do we envision adding support for in the future based on customer asks so far.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Created https://github.com/project-radius/radius/issues/5801 to track this discussion.

@kachawla kachawla force-pushed the kachawla/recipe-templatekind-required branch from 155122e to a6d0b1c Compare May 22, 2023 16:56
@github-actions
Copy link

You are editing files which require a docs update. Please ensure you've made the appropriate changes to the docs and submitted a PR.

  • Swagger changes require reference edge docs to be updated here
  • Make sure to create a branch and submit a PR into the edge branch instead of the default latest branch, as the swagger changes will not be available until the next release.

For more information on contributing to docs please visit https://docs.radapp.dev/contributing/docs/.

@github-actions
Copy link

github-actions bot commented May 22, 2023

Radius functional test overview

🔍 Go to test action run

Name Value
Repository project-radius/radius
Commit ref a6d0b1c
Unique ID af31a349de
Image tag pr-af31a349de
Click here to see the list of tools in the current test run
  • KinD: v0.18.0
  • Dapr: 1.10.0
  • Azure KeyVault CSI driver: 1.4.2
  • Azure Workload identity webhook: 1.0.0
  • recipe location radiusdev.azurecr.io/test/functional/corerp/recipes/<name>:pr-af31a349de
  • appcore-rp test image location: radiusdev.azurecr.io/appcore-rp:pr-af31a349de
  • ucp test image location: radiusdev.azurecr.io/ucpd:pr-af31a349de

Test Status

⌛ Building Radius and pushing container images for functional tests...
✅ Container images build succeeded
⌛ Publishing Bicep Recipes for functional tests...
✅ Recipe publishing succeeded
⌛ Starting corerp functional tests...
⌛ Starting samples functional tests...
⌛ Starting ucp functional tests...
✅ samples functional tests succeeded
✅ ucp functional tests succeeded
✅ corerp functional tests succeeded

@github-actions
Copy link

63.9

For the detailed report, please go to Checks tab, click Build and Test, and then download unit_test_coverage artifact at the bottom of build page.

  • Your PR branch coverage: 63.9 %
  • main branch coverage: 63.9 %
  • diff coverage: 0 %

The coverage result does not include the functional test coverage.

@github-actions
Copy link

You are editing files which require a docs update. Please ensure you've made the appropriate changes to the docs and submitted a PR.

  • Swagger changes require reference edge docs to be updated here
  • Make sure to create a branch and submit a PR into the edge branch instead of the default latest branch, as the swagger changes will not be available until the next release.

For more information on contributing to docs please visit https://docs.radapp.dev/contributing/docs/.

@github-actions
Copy link

github-actions bot commented May 22, 2023

Radius functional test overview

🔍 Go to test action run

Name Value
Repository project-radius/radius
Commit ref 3645dec
Unique ID d0c79c9ab0
Image tag pr-d0c79c9ab0
Click here to see the list of tools in the current test run
  • KinD: v0.18.0
  • Dapr: 1.10.0
  • Azure KeyVault CSI driver: 1.4.2
  • Azure Workload identity webhook: 1.0.0
  • recipe location radiusdev.azurecr.io/test/functional/corerp/recipes/<name>:pr-d0c79c9ab0
  • appcore-rp test image location: radiusdev.azurecr.io/appcore-rp:pr-d0c79c9ab0
  • ucp test image location: radiusdev.azurecr.io/ucpd:pr-d0c79c9ab0

Test Status

⌛ Building Radius and pushing container images for functional tests...
✅ Container images build succeeded
⌛ Publishing Bicep Recipes for functional tests...
✅ Recipe publishing succeeded
⌛ Starting ucp functional tests...
⌛ Starting corerp functional tests...
⌛ Starting samples functional tests...
✅ samples functional tests succeeded
✅ ucp functional tests succeeded
✅ corerp functional tests succeeded

@github-actions
Copy link

63.9

For the detailed report, please go to Checks tab, click Build and Test, and then download unit_test_coverage artifact at the bottom of build page.

  • Your PR branch coverage: 63.9 %
  • main branch coverage: 63.9 %
  • diff coverage: 0 %

The coverage result does not include the functional test coverage.

@github-actions
Copy link

You are editing files which require a docs update. Please ensure you've made the appropriate changes to the docs and submitted a PR.

  • Swagger changes require reference edge docs to be updated here
  • Make sure to create a branch and submit a PR into the edge branch instead of the default latest branch, as the swagger changes will not be available until the next release.

For more information on contributing to docs please visit https://docs.radapp.dev/contributing/docs/.

@github-actions
Copy link

github-actions bot commented May 22, 2023

Radius functional test overview

🔍 Go to test action run

Name Value
Repository project-radius/radius
Commit ref c20accd
Unique ID 08bb493f29
Image tag pr-08bb493f29
Click here to see the list of tools in the current test run
  • KinD: v0.18.0
  • Dapr: 1.10.0
  • Azure KeyVault CSI driver: 1.4.2
  • Azure Workload identity webhook: 1.0.0
  • recipe location radiusdev.azurecr.io/test/functional/corerp/recipes/<name>:pr-08bb493f29
  • appcore-rp test image location: radiusdev.azurecr.io/appcore-rp:pr-08bb493f29
  • ucp test image location: radiusdev.azurecr.io/ucpd:pr-08bb493f29

Test Status

⌛ Building Radius and pushing container images for functional tests...
✅ Container images build succeeded
⌛ Publishing Bicep Recipes for functional tests...
✅ Recipe publishing succeeded
⌛ Starting samples functional tests...
⌛ Starting ucp functional tests...
✅ samples functional tests succeeded
⌛ Starting corerp functional tests...
✅ ucp functional tests succeeded
✅ corerp functional tests succeeded

@github-actions
Copy link

64.0

For the detailed report, please go to Checks tab, click Build and Test, and then download unit_test_coverage artifact at the bottom of build page.

  • Your PR branch coverage: 64.0 %
  • main branch coverage: 63.9 %
  • diff coverage: .1 %

The coverage result does not include the functional test coverage.

@kachawla kachawla merged commit 45e95ce into main May 22, 2023
@kachawla kachawla deleted the kachawla/recipe-templatekind-required branch May 22, 2023 19:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants