Skip to content

[Refactoring Suggestions] refactored Operator.register api in v2 #687

Closed
@heesuk-ahn

Description

@heesuk-ahn

Motivation

Operator register api of v2 can remove the part that passes null as a parameter through method overloading.

In this case, we can remove the logic to protect null from the logic inside the register api.

This can make register api code more readable.

Proposal

  • Change deprecated kubernetesClient.getVersion to KubernetesClient.getKubernetesVersion
  • Pass a non-null value as a parameter by creating defaultConfiguration in register(Reconciler reconciler)
  • Remove unnecessary null defense code

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions