-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
omitempty
corrections
#2255
base: master
Are you sure you want to change the base?
omitempty
corrections
#2255
Conversation
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: The full list of commands accepted by this bot can be found here.
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
Signed-off-by: Thomas Newton <[email protected]>
Signed-off-by: Thomas Newton <[email protected]>
Signed-off-by: Thomas Newton <[email protected]>
Signed-off-by: Thomas Newton <[email protected]>
Signed-off-by: Thomas Newton <[email protected]>
Signed-off-by: Thomas Newton <[email protected]>
Signed-off-by: Thomas Newton <[email protected]>
Signed-off-by: Thomas Newton <[email protected]>
Signed-off-by: Thomas Newton <[email protected]>
Signed-off-by: Thomas Newton <[email protected]>
Signed-off-by: Thomas Newton <[email protected]>
Signed-off-by: Thomas Newton <[email protected]>
Signed-off-by: Thomas Newton <[email protected]>
Signed-off-by: Thomas Newton <[email protected]>
Signed-off-by: Thomas Newton <[email protected]>
Signed-off-by: Thomas Newton <[email protected]>
6b26711
to
284d5ab
Compare
Signed-off-by: Thomas Newton <[email protected]>
@Tom-Newton Since v2, we use kubebuilder to create api for SparkApplication/SchedulerSparkApplication with the command like follows: kubebuilder create api --version v1beta2 --kind SparkApplication and the |
Thanks for the info. Does that mean that mean we should keep them as they were? or is there somewhere else that is source of truth to mark them as required when running |
Purpose of this PR
Some corrections to make a couple of required fields required and optional fields genuinely optional.
Proposed changes:
sparkUIOptions
have become required #2215. This problem was caused by some optional fields in the CRD not usingomitempty
. That meant that validSparkApplication
configs gotnull
s added were they weren't allowed during some encode and decode in the SparkApplication default webhook.\+optional\n^(?!.*omitempty).*$
to find all the optional parameters that don't useomitempty
and addomitempty
to them, to avoid the same problem in other places.omitempty
onmetadata
andspec
fields ofSparkApplication
andScheduledSparkApplication
. I think these should be required and they used to be in the past. and I suspect this may have been changed accidentally. Obviously let me know if there is good reason to addomitempty
on these.Change Category
Indicate the type of change by marking the applicable boxes:
Checklist
Before submitting your PR, please review the following:
Additional Notes
I'm still a
golang
noob.