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

Move function resource presets from labels to annotations #15407

Closed
3 tasks
kwiatekus opened this issue Sep 8, 2022 · 1 comment
Closed
3 tasks

Move function resource presets from labels to annotations #15407

kwiatekus opened this issue Sep 8, 2022 · 1 comment
Labels
area/serverless Issues or PRs related to serverless duplicate This issue or pull request already exists kind/cleanup Categorizes issue or PR as related to cleaning up code, process, or technical debt.

Comments

@kwiatekus
Copy link
Contributor

kwiatekus commented Sep 8, 2022

Description

Function resource presets should be based on annotations, not on labels.

  • Remove the functionality around serverless.kyma-project.io/replicas-preset
  • When serverless.kyma-project.io/xxx-resources-preset label is used log warning - no need to migrate
  • Annotations on function level should end up storing matching cpu and memory resources in the spec.templates.xxxTemplate.resources

For example, annotating function with :

  • serverless.kyma-project.io/function-resources-preset=L
    should apply matching resources on runtime pod.
  • serverless.kyma-project.io/build-resources-preset=L
    should apply matching resources on build pod.

Reasons

Labels should be used only for resource filtering, not to drive functionalities.

Related issues
Depends on #15402
Related to #15282
Related proposal : https://github.com/kyma-project/kyma/blob/main/components/function-controller/design/subresources_templates_proposal.md

@kwiatekus kwiatekus added area/serverless Issues or PRs related to serverless kind/cleanup Categorizes issue or PR as related to cleaning up code, process, or technical debt. labels Sep 8, 2022
@kwiatekus kwiatekus added this to the 2.8 milestone Sep 8, 2022
@kwiatekus
Copy link
Contributor Author

closed in favor of #15288

@kwiatekus kwiatekus added the duplicate This issue or pull request already exists label Oct 14, 2022
@kwiatekus kwiatekus removed this from the 2.8 milestone Oct 14, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/serverless Issues or PRs related to serverless duplicate This issue or pull request already exists kind/cleanup Categorizes issue or PR as related to cleaning up code, process, or technical debt.
Projects
None yet
Development

No branches or pull requests

1 participant