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

Refactor node interface and implementation to allow for easier create / #11

Merged
merged 1 commit into from
Jul 15, 2021

Conversation

marcushines
Copy link
Contributor

deletion of custom resources

func (n *Node) CreateNodeResource(ctx context.Context, kClient kubernetes.Interface, ns string) error {
log.Infof("Create IxiaTG node resource %s\n", n.pb.Name)
func (n *Node) CreateNodeResource(ctx context.Context, ni node.Interface) error {
log.Infof("Create IxiaTG node resource %s", n.pb.Name)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: Creating ?

log.Infof("Delete IxiaTG node resource %s\n", n.pb.Name)
err := kClient.CoreV1().RESTClient().
func (n *Node) DeleteNodeResource(ctx context.Context, ni node.Interface) error {
log.Infof("Delete IxiaTG node resource %s", n.pb.Name)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: Deleting ?

@@ -124,7 +149,7 @@ func toEnvVar(kv map[string]string) []corev1.EnvVar {
return envVar
}

func toResourceRequirements(kv map[string]string) corev1.ResourceRequirements {
func ToResourceRequirements(kv map[string]string) corev1.ResourceRequirements {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should we add some docstring ? as this func is being exported now ?

@marcushines marcushines merged commit 5d7aeb6 into main Jul 15, 2021
@marcushines marcushines deleted the hines branch July 16, 2021 15:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants