Commit Graph

7 Commits

Author SHA1 Message Date
Ben Luddy
8cb21671f4 Add CBOR feature gates.
For alpha, there is one apiserver feature gate and two client-go feature gates controlling
CBOR. They were initially wired to separate test-only feature gate instances in order to prevent
them from being configurable at runtime via command-line flags or environment variables (for
client-go feature gates outside of Kubernetes components). All of the integration tests required by
the KEP as alpha criteria have been implemented. This adds the feature gates to the usual feature
gate instances and removes the temporary code to support separate test-only feature gate instances.

Kubernetes-commit: 072dfcb416fd4e1ddab0a89ac4faf519e268bc96
2024-11-04 10:40:19 -05:00
Ben Luddy
1cca19dc02 Add test-only client feature gates for CBOR.
As with the apiserver feature gate for CBOR as a serving and storage encoding, the client feature
gates for CBOR are being initially added through a test-only feature gate instance that is not wired
to environment variables or to command-line flags and is intended only to be enabled
programmatically from integration tests. The test-only instance will be removed as part of alpha
graduation and replaced by conventional client feature gating.

Kubernetes-commit: ea13190d8bd3a4bb3e82055b529aa7599ae5c6e1
2024-10-23 16:36:37 -04:00
Ben Luddy
ee51eaf9d0 Use content negotiation in the dynamic client.
Kubernetes-commit: 97958d96a2911c8b1df324868f4730b1c622c798
2024-02-15 17:47:19 -05:00
liyuerich
68d318f3aa drop deprecated json/yaml newSerializers, use json.NewSerializerWithOptions instead
Signed-off-by: liyuerich <yue.li@daocloud.io>

Kubernetes-commit: 3c9309db463679c348934429d8487d190ed5e64a
2024-05-29 19:00:00 +08:00
Clayton Coleman
881cd219a8 dynamic: The dynamic client no longer needs a special cased watch
By correctly handling content type negotiation, we can avoid the
need for a special version of watch and use the same code path as
typed clients.

Kubernetes-commit: 3f94f80b0a79293e54d7080aaf7a64d7df8b1d4a
2019-11-03 15:10:12 -05:00
Clayton Coleman
33b8c3799f Unify runtime.SerializerInfo with negotiate.AcceptedMediaTypes
There was no reason to have two types and this avoids ~10% of allocations
on the GET code path.

```
BenchmarkGet-12          	  100000	    109045 ns/op	   17608 B/op	     146 allocs/op

BenchmarkGet-12          	  100000	    108850 ns/op	   15942 B/op	     132 allocs/op
```

Kubernetes-commit: 0489d0b1cf139253b82f73b072578073bc5616d6
2019-03-21 21:00:55 -04:00
David Eads
2e1683e1a1 add easy to use dynamic client
Kubernetes-commit: 3632037e600d82a954c05ecd4f9cb6f1ca93d41c
2018-04-24 13:41:40 -04:00