Comments (7)
Hey - we're still targeting v1.24 as per our release schedule. We'll be moving to v1.25 in the next few weeks.
Cannot build because the injection interface is missing the new
So these dynamic wrapped clients were introduced here - #2210 But they're a bit of a headache as you encountered because the codegen/interface need to be updated.
Since Knative isn't actually using this functionality I'm thinking we just purge this from knative.dev/pkg
and downstream repos can just generate these clients themselves.
cc @pierDipi
cc @imjasonh since I think this was added because of tekton chains
from pkg.
Hey - we're still targeting v1.24 as per our release schedule. We'll be moving to v1.25 in the next few weeks.
Anything that relies on knative.dev/pkg and has a transitive dependency using k8s 1.26+ will break because we aren't including the new k8s client interfaces (regardless if they're being used). Because of Go's minimum version selection this is getting harder to avoid as more dependencies update.
Not looking to bump the minimum supported server version - I'm looking to add support for the new k8s client interface definition so the injection client can be forwards compatible.
So these dynamic wrapped clients were introduced here - #2210 But they're a bit of a headache as you encountered because the codegen/interface need to be updated.
I'm thinking since Knative isn't actually using this functionality I'm thinking we just purge this from knative.dev/pkg and downstream repos can just generate these clients themselves.
This is for the typed k8s client, which looks like has usage across knative. I don't think the dynamic client is affected by this.
from pkg.
I see what you're saying now about the dynamic client - it's because that's what the wrapClient is used for.
An idea - what if we modify the codegen to do this:
type wrapClient struct {
+ kubernetes.Interface
dyn dynamic.Interface
}
- var _ kubernetes.Interface = (*wrapClient)(nil)
This would let the client satisfy newer interface versions, even if Go mod used a newer client version. This has a downside of if you tried to access a newer client API then what knative supports it will panic, but we're already allowing panics for Discovery endpoints and as long as you're using existing API versions you shouldn't see a difference.
wdyt?
from pkg.
The additional methods called _expansion
s are also panic-ing with NYI
(not yet implemented): https://github.com/knative/pkg/blob/main/client/injection/kube/client/client_expansion.go, so the panic issue is currently already present for new methods that we don't use
from pkg.
The downside is that instead of having a NYI panic, we will get a nil
panic? which would make the error message a lot more cryptic?
from pkg.
Played around with this a bit - the codegen wasn't working for me because the repo wasn't on GOPATH.
The interface embedding isn't going to work because it will still fail for interfaces that were removed in newer k8s client versions (I ran into issues with the deprecated PodSecurityPolicy interface since it was removed in newer versions).
from pkg.
@wlynch we removed the dynamic.Client backed kubernetes.Interface
wrapper that was causing problems.
PR #2742
You should be able to go get knative.dev/pkg@latest
and then bump your k8s libs to the version you want.
from pkg.
Related Issues (20)
- Fix linter errors HOT 2
- queue-proxy nil pointer dereference HOT 1
- Downstream Tekton failures HOT 3
- Feature: Generic admission webhook HOT 4
- Identical version referenced in status.ConvertTo HOT 6
- Consider putting the admission review on the webhook context HOT 11
- kmeta package: ChildName function produces invalid resource names HOT 1
- Allow reconcilers to listen to leader promotion events HOT 3
- reconcilerImpl.updateStatus method performance impacted by state difference calculation used in debug mode only
- Make ZipkinTracingEnabled flag thread safe HOT 1
- Support creating TLS servers with mutual trust HOT 2
- Eventing TLS: Update Addressable and AddressStatus HOT 2
- Eventing TLS: Update Destination and KReference HOT 2
- Eventing TLS: Add AddressableFromDestination method on the resolver HOT 2
- Drop use of https://github.com/gorilla/websocket HOT 2
- Eventing TLS: Add SinkCACerts to SourceStatus HOT 1
- Bump Min K8s version to 1.25
- Drop dynamic wrapped client generation HOT 8
- Eventing TLS: validate that `Destination.CACerts` is a PEM encoded cert HOT 2
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 pkg.