[
https://issues.apache.org/jira/browse/YUNIKORN-1807?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Peter Bacsko reassigned YUNIKORN-1807:
--------------------------------------
Assignee: Peter Bacsko
> Remove error check from createEventRecord()
> -------------------------------------------
>
> Key: YUNIKORN-1807
> URL: https://issues.apache.org/jira/browse/YUNIKORN-1807
> Project: Apache YuniKorn
> Issue Type: Sub-task
> Components: core - scheduler
> Reporter: Peter Bacsko
> Assignee: Peter Bacsko
> Priority: Major
>
> Currently, {{createEventRecord()}} performs an error check:
> {noformat}
> if objectID == "" {
> return nil, fmt.Errorf("objectID should not be nil")
> }
> if reason == "" {
> return nil, fmt.Errorf("reason should not be nil")
> }
> {noformat}
> These error checks are not necessary. Everything is in our hands here, the
> two strings are not user-supplied input. We'll have tons of tests, both unit
> and e2e, such defensive coding is not needed.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]