Skip to content

Connection leak in cri-client #133183

@rkojedzinszky

Description

@rkojedzinszky

What happened?

func NewRemoteRuntimeService(endpoint string, connectionTimeout time.Duration, tp trace.TracerProvider, logger *klog.Logger) (internalapi.RuntimeService, error) {
creates a connection to the specified endpoint, howewer, it is not possible for the caller to later close it. CRI-O uses this method for its internal health check. As client connections dont get closed, nor do server ones, and then they'll eat up resources.

What did you expect to happen?

No memory/connection leaks in client libraries too.

How can we reproduce it (as minimally and precisely as possible)?

See cri-o/cri-o#9360

Anything else we need to know?

No response

Kubernetes version

# kubectl version 
Client Version: v1.33.1
Kustomize Version: v5.6.0
Server Version: v1.33.1

Cloud provider

kvm

OS version

No response

Install tools

kubeadm

Container runtime (CRI) and version (if applicable)

crio 1.33

Related plugins (CNI, CSI, ...) and versions (if applicable)

No response

Metadata

Metadata

Assignees

Labels

kind/bugCategorizes issue or PR as related to a bug.sig/nodeCategorizes an issue or PR as relevant to SIG Node.triage/acceptedIndicates an issue or PR is ready to be actively worked on.

Type

No type

Projects

Status

Triaged

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions