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

Fix up some potential leaks, by calling close() #106

Merged
merged 1 commit into from
Nov 3, 2017

Conversation

brendandburns
Copy link
Contributor

Apropos of #95

I audited the rest of our code...

@@ -42,7 +42,7 @@ public static void main(String[] args) throws IOException, ApiException, Interru
Configuration.setDefaultApiClient(client);

Attach attach = new Attach();
final Attach.AttachResult result = attach.attach("default", "nginx-2371676037-czqx3", true);
final Attach.AttachResult result = attach.attach("default", "nginx-4217019353-k5sn9", true);
Copy link
Contributor

Choose a reason for hiding this comment

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

How useful is this pod name? Looks like it was generated by a deployment

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Well, this is example code :)

I could put "nginx-example-pod"

I suppose I could dynamically query and try to attach to the first pod I find, but I'm not sure how perfect an example needs to be. (I could also take the pod as a command line argument I suppose, but it seems like something for a different PR)

Copy link
Contributor

Choose a reason for hiding this comment

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

Fair enough :) maybe we can revisit if someone files an issue but you're right, let's not complicate it

@brendandburns
Copy link
Contributor Author

@lwander any other comments? @mbohlool any thoughts?

If not, I can haz lgtmz?

Copy link
Contributor

@lwander lwander left a comment

Choose a reason for hiding this comment

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

LGTM!

@mbohlool
Copy link
Contributor

mbohlool commented Nov 3, 2017

Will look and merge today.

@mbohlool
Copy link
Contributor

mbohlool commented Nov 3, 2017

/lgtm

@mbohlool mbohlool merged commit 91b88e7 into kubernetes-client:master Nov 3, 2017
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