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

KO-382 cleanup after scaleup #80

Merged
merged 2 commits into from
May 8, 2020
Merged

Conversation

sandoichi
Copy link
Collaborator

No description provided.

Copy link
Collaborator

@johntrimble johntrimble left a comment

Choose a reason for hiding this comment

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

Looks great!

body: body,
}

_, err = callNodeMgmtEndpoint(client, request, "application/json")
Copy link
Collaborator

Choose a reason for hiding this comment

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

there is an http constant for this, I think

@sandoichi sandoichi merged commit 4a71be4 into master May 8, 2020
@sandoichi sandoichi deleted the KO-382-cleanup-after-scaleup branch May 8, 2020 16:35
Comment on lines +175 to +186
postData := make(map[string]interface{})
if jobs > -1 {
postData["jobs"] = strconv.Itoa(jobs)
}

if keyspaceName != "" {
postData["keyspace_name"] = keyspaceName
}

if len(tables) > 0 {
postData["tables"] = tables
}
Copy link
Collaborator

Choose a reason for hiding this comment

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

Do you think this is nicer? It's not exactly the same logic, yet

postData := struct {
    Jobs string `json:"jobs"`
    Keyspace string `json:"keyspace_name"`
    Tables []string `json:"tables"`
}{
    Jobs: strconv.Itoa(jobs),
    Keyspace: keyspaceName,
    Tables: tables,
}

Copy link
Collaborator

@jimdickinson jimdickinson left a comment

Choose a reason for hiding this comment

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

lgtm

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.

3 participants