Skip to content

bug: ydb_go_sdk_driver_conns metric does not clear old endpoints #1692

Open
@qrort

Description

@qrort

Bug Report

YDB GO SDK version:

v3.101.0

Environment

linux, amd64

Current behavior:

when set of YDB dynnodes is changed, new endpoints are added to ydb_go_sdk_driver_conns metric, but the old ones, that are absent now, are not removed from it

Expected behavior:

ydb_go_sdk_driver_conns should list only endpoints, for which there is an alive connection in balancer connections pool

Steps to reproduce:

turn off one dynnode which is reported in ydb_go_sdk_driver_conns

Other information:

https://github.com/ydb-platform/ydb-go-sdk/blob/master/metrics/driver.go#L162

this code is not called, maybe because connections state is replaced on rediscovery here

b.connectionsState.Store(state)
and Close() is not actually called

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions