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

Client: expose default_namespace() #1123

Merged
merged 1 commit into from
Jan 18, 2023
Merged

Conversation

jpmcb
Copy link
Contributor

@jpmcb jpmcb commented Jan 18, 2023

Motivation

Closes: #1118
Succeeds: #1121 (GitHub didn't like me force pushing to my fork's main branch and auto closed it 😭 - sorry for the noise)

Solution

Exposes and documents the default_namespace() method for the Client. Now, users can get the namespace stored on the client which will be especially useful for in-cluster configs doing namespace specific operations

Added a simple test as well. Let me know if this needs anything else!

Signed-off-by: John McBride <jpmmcbride@gmail.com>
@codecov-commenter
Copy link

Codecov Report

Merging #1123 (88a427d) into main (e0a4e49) will increase coverage by 0.04%.
The diff coverage is 100.00%.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1123      +/-   ##
==========================================
+ Coverage   72.68%   72.73%   +0.04%     
==========================================
  Files          65       65              
  Lines        4877     4882       +5     
==========================================
+ Hits         3545     3551       +6     
+ Misses       1332     1331       -1     
Impacted Files Coverage Δ
kube-client/src/api/mod.rs 68.75% <100.00%> (ø)
kube-client/src/client/mod.rs 71.34% <100.00%> (+0.86%) ⬆️
kube-runtime/src/wait.rs 77.35% <0.00%> (+1.88%) ⬆️

Copy link
Member

@clux clux left a comment

Choose a reason for hiding this comment

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

LGTM. Thank you!

@clux clux added the changelog-add changelog added category for prs label Jan 18, 2023
@clux clux added this to the 0.79.0 milestone Jan 18, 2023
@clux clux added the client http issues with the client label Jan 18, 2023
@clux clux merged commit 7557890 into kube-rs:main Jan 18, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
changelog-add changelog added category for prs client http issues with the client
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Expose default_namespace on Client
3 participants