Commit Graph

24 Commits

Author SHA1 Message Date
aimuz
571adf6e84
Improved FormatMap: Improves performance by about 4x, or nearly 2x in the worst case (#112661)
* Improved FormatMap

Improves performance by about 4x, or nearly 2x in the worst case

old FormatMap
BenchmarkFormatMap-12             873046                1238 ns/op             384 B/op         13 allocs/op
new FormatMap
BenchmarkFormatMap-12            3665762               327.0 ns/op             152 B/op          3 allocs/op

Signed-off-by: aimuz <mr.imuz@gmail.com>

* fixed

Signed-off-by: aimuz <mr.imuz@gmail.com>

* fixed

Signed-off-by: aimuz <mr.imuz@gmail.com>

* test: fix test

Signed-off-by: aimuz <mr.imuz@gmail.com>

---------

Signed-off-by: aimuz <mr.imuz@gmail.com>
2023-03-01 22:26:55 -08:00
Jun Gong
40f3f3bd0e Fix return value for ExtractFieldPathAsString 2019-06-04 11:52:26 +08:00
Christoph Blecker
97b2992dc1
Update gofmt for go1.11 2018-10-05 12:59:38 -07:00
Lorenzo Fontana
d645056be1
fieldpath: Add tests for missing cases
Signed-off-by: Lorenzo Fontana <lo@linux.com>
2018-07-12 10:26:18 +02:00
Yang Guo
c74b97b29d Validate key subscript for metadata.annotations and metadata.labels separately 2017-11-22 15:50:40 -08:00
Yang Guo
82c9eec164 Expose single annotation/label via downward API 2017-11-21 19:21:10 -08:00
Chao Xu
60604f8818 run hack/update-all 2017-06-22 11:31:03 -07:00
Chao Xu
f4989a45a5 run root-rewrite-v1-..., compile 2017-06-22 10:25:57 -07:00
Harry Zhang
efb10b1821 Move extract resources to its pkg
Move ExtractContainerResourceValue
2017-04-03 13:06:48 +08:00
Kubernetes Submit Queue
1b9f89691a Merge pull request #34533 from yuexiao-wang/fix-commends
Automatic merge from submit-queue

Update function name for public function in commend

**What this PR does / why we need it**:
Update function name for public function in commend and fix some typos in log information.

Signed-off-by: yuexiao-wang wang.yuexiao@zte.com.cn
2017-01-30 09:05:22 -08:00
Dr. Stefan Schimanski
bc6fdd925d pkg/api/resource: move to apimachinery 2017-01-29 21:41:44 +01:00
Clayton Coleman
9a2a50cda7
refactor: use metav1.ObjectMeta in other types 2017-01-17 16:17:19 -05:00
yuexiao-wang
27f61cb28b Update function name for public function in commend
Signed-off-by: yuexiao-wang <wang.yuexiao@zte.com.cn>
2017-01-05 00:03:11 +08:00
Chao Xu
4f3d0e3bde more dependencies packages:
pkg/metrics
pkg/credentialprovider
pkg/security
pkg/securitycontext
pkg/serviceaccount
pkg/storage
pkg/fieldpath
2016-11-23 15:53:09 -08:00
David McMahon
ef0c9f0c5b Remove "All rights reserved" from all the headers. 2016-06-29 17:47:36 -07:00
k8s-merge-robot
77cf11f4d7 Merge pull request #27441 from derekwaynecarr/downward_api_node_defaults
Automatic merge from submit-queue

Revert revert of downward api node defaults

Reverts the revert of https://github.com/kubernetes/kubernetes/pull/27439

Fixes #27062

@dchen1107 - who at Google can help debug why this caused issues with GKE infrastructure but not GCE merge queue?

/cc @wojtek-t @piosz @fgrzadkowski @eparis @pmorie
2016-06-18 12:12:24 -07:00
derekwaynecarr
18a206ad56 Downward API defaults resource limits to node capacity/allocatable 2016-06-17 14:18:18 -04:00
Piotr Szczesniak
51af487b5f Revert "Downward api node defaults" 2016-06-15 15:47:49 +02:00
Vishnu kannan
afdd9ea262 When limits are not set, use capacity as limits in downward API for resources.
Signed-off-by: Vishnu kannan <vishnuk@google.com>
2016-06-14 11:29:39 -04:00
Avesh Agarwal
3c865e45a0 Remove an empty line being output when exposing annotations and
labels via downward api volume
2016-06-08 09:22:10 -04:00
Salvatore Dario Minonne
f4dc0653aa adding downward api volume plugin 2015-09-01 22:23:03 +02:00
Mike Danese
8e33cbfa28 rewrite go imports 2015-08-05 17:30:03 -07:00
Eric Paris
6b3a6e6b98 Make copyright ownership statement generic
Instead of saying "Google Inc." (which is not always correct) say "The
Kubernetes Authors", which is generic.
2015-05-01 17:49:56 -04:00
Paul Morie
7d30f09ebf Add downward API for environment vars 2015-04-27 14:13:11 -04:00