Check if delegate is nil before calling Next() in terminalSizeQueueAdapter
to prevent a nil pointer dereference.
Kubernetes-commit: 72a5892dca945f000a30c7a763aa0696964b7e50
Remove reference to internal types in kuberc types
* Remove unserialized types from public APIs
Also remove defaulting
* Don't do conversion gen for plugin policy types
Because the plugin policy types are explicitly allowed to be empty, they
should not affect conversion. The autogenerated conversion functions for
the `Preference` type will leave those fields empty.
* Remove defaulting tests
Comments and simplifications (h/t jordan liggitt)
Signed-off-by: Peter Engelbert <pmengelbert@gmail.com>
Kubernetes-commit: fab280950dabfefabe6a8578b7a76372a9b21874
I can't find evidence that anything is using this anymore, if anyone does depend on this it is a tiny function that depends only on public symbols and they can just place a copy somewhere else.
Kubernetes-commit: 4e29dcdf7567cd79749b7ad35378538b1b523247
This replaces functions that wrap another function with no change with
a direct reference to the wrapped function.
Signed-off-by: Stephen Kitt <skitt@redhat.com>
Kubernetes-commit: 1e2817d5890ac5056e770cbdebdadfb7fc6ef54c
The --chunk-size flag has been around since October 2017
(i4780ad0297)
so it's about time we make it official.
Signed-off-by: Maciej Szulik <soltysh@gmail.com>
Kubernetes-commit: cf099f4fc9028c60e62de33223492d1ef4e03585
LogOptions.RunLogs unfortunately registers a signal handler and calls
os.Exit(1) after finished processing when a signal is received. This
makes it basically impossible to call that function from any custom
code.
This patch adds RunLogsContext, which does exactly what RunLogs does,
but the context to be used is passed in. RunLogs retains the current
contract, but it uses RunLogsContext internally, then calls os.Exit(1)
when a signal is received.
Kubernetes-commit: cc4666cc94be41d8b4558122717a2da9fb5a7b1a
There is a custom error message returned from resource.Builder when
SingleResourceType is set and multiple resources types are specified,
which makes it impossible to check for the condition in code easily.
This patch adds resource.ErrMultipleResourceTypes that is returned
precisely in this case so that it can be checked.
This patch also removes an extra custom error message in kubectl get,
which is actually never reached, because the builder fails before.
Kubernetes-commit: 82896feebbdf1c0809c0fec29988eff15cb02837
The output format is now used by the `Complete()` function, so it must
be set before invoking said function.
The commit also adds a unit tests for this scenario.
Signed-off-by: Marc Khouzam <marc.khouzam@gmail.com>
Kubernetes-commit: f3d278e75d1137f1c91dde7415bc577af3c3be82
The current help text wordings incorrectly suggests inference only works for RC/RS when it actually works for Pods and Deployments too
Update help text to accurately reflect that selector inference works
for any resource being exposed, as documented in main expose help.
Kubernetes-commit: 5c8f26f48032899031760e5b75ad259d23d312b2
* fix using stale pod when evict failed and retry
* simplify pod refresh process
* use activePod at getPodFn
* fix lint check
* add ut
* introduce EvictErrorRetryDelay
Kubernetes-commit: 66fdbe105831e08b588dd01039a7e3130fd2d36f
This allows consumers of term to not pull in dependencies on
github.com/gorilla/websocket and github.com/moby/spdystream.
Kubernetes-commit: 640dabd58b04b72f646ed85947cb8b407b36dc08