-
Notifications
You must be signed in to change notification settings - Fork 524
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
[Nuctl][Dashboard] Move autofix functionality to platform side #3122
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I am not yet convinced doing the auto-fixing while validating is the right way to do it.
While I understand this saves us another deployment/validation cycle, this pretty much defies the SOLID principle of single responsibility.
Changing the function configuration on-the-fly is very intrusive and can cause some unexpected behaviors from users if not used properly.
We wanted this feature in the upgrade so it wouldn't fail, but generally I prefer that the deployment will fail if the wrong configuration is given.
I lean towards seperating the fixing from nuctl to a "Fixer" kind of object in the functionconfig
package, that can be called from the anywhere, but mainly used when importing functions.
@TomerShor agreed with those points, let's discuss tomorrow on nuclio sync |
# Conflicts: # pkg/nuctl/command/common/importreport.go
# Conflicts: # pkg/platform/abstract/platform.go
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Last comment from me - looking great
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM 👌
jira - https://jira.iguazeng.com/browse/NUC-127
This pull request moves the autofix functionality to the platform side to achieve the following:
Currenntly
maxRetries
is equal to 1, because we support only one error to be autofixed.