Comments (6)
Hello,
We are using this method in order to query the stats of the node directly.
let node_summary_request = Node::connect_get_proxy_with_path(node_name, "stats/summary", Default::default()).unwrap();
It seems this method have been removed by the change you describe.
Could you let me know if it is correct ? And if yes, if you see any alternative in the latest version to achieve this ?
At the moment, we pinned the version to v0.19.0 to avoid the breaking change.
Regards
from k8s-openapi.
Right, that is an API operation and so it has been removed. Also kube does not implement the full proxy API to .../proxy
yet.
But since k8s-openapi never implemented the rest of the proxy response / stream handling, you presumably already have code to do that yourself. So you don't need support from kube for it anyway, just the http::Request
that k8s-openapi used to give you. You can create it yourself as k8s-openapi used to: https://docs.rs/k8s-openapi/0.19.0/src/k8s_openapi/v1_27/api/core/v1/node.rs.html#178-199
from k8s-openapi.
Thank you for the swift answer @Arnavion.
Indeed, we have a custom parser for the raw bytes returned by this call.
We will try to use http::Request directly as you suggest :)
Thank you for Kube-rs
from k8s-openapi.
First of all thank you for your amazing work!
Responding to the comment request, we're using Pod::log_stream
because Api::<Pod>::LogStream
doesn't check (or expose) the status code of the HTTP response.
from k8s-openapi.
Yes, comparing Client::request_text
(used by other CRUD API) with Client::request_stream
(used by Pod::log_stream
), the latter is missing the handle_api_errors
or equivalent that would act on res.status()
. Once it did that, that would solve the "check" problem, and it would also result in the status code appearing as Err(Error::Api(...))
which would solve the "expose" problem.
I didn't find an open issue on their tracker about this, so please open one and link it here.
from k8s-openapi.
Thanks for the research! Opened kube-rs/kube#1300.
from k8s-openapi.
Related Issues (20)
- Consider extending the crate with merge functionality HOT 7
- Documentation snippet about kubernetes detection is not working as expected HOT 4
- Improve Name and Namespace optionality HOT 7
- `apimachinery::pkg::api::resource::Quantity` compatibility with Go HOT 2
- i32 for port number HOT 5
- `MicroTime` can be `null` HOT 6
- Add `latest` and `earliest` version features that track highest and lowest supported version HOT 1
- Can't find `meta/v1/Duration` HOT 2
- `k8s_openapi::ListResponse` should be serializable HOT 2
- release with v1.27 HOT 3
- v1.28.0
- Looking for example on how to use k8s_openapi::api::core::v1::Event::create function HOT 1
- ServiceSpec not creating headless service when cluster_ip set to None HOT 4
- Size of generated code HOT 7
- about k8s-openapi features upgrade question HOT 4
- Comparison of elements is too strict HOT 2
- int-or-string parameters are typed out with mismatched "type" property HOT 2
- Namespaces are not Serializing HOT 4
- Plans to Support Builder Pattern in Kube.rs? HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from k8s-openapi.