Skip to content

sql/instancestorage: TestRefreshSession tries to use logic that is not copacetic #109410

@knz

Description

@knz

Describe the problem

When pointing TestRefreshSession to a secondary tenant, we get the following error:

    sql_runner.go:322: error executing 'SELECT count(*) FROM system.sql_instances WHERE id = 1 AND session_id <> decode('010180bafc8a4b9cfa441db9fee7401e7791f6', 'hex')': pq: no healthy sql instances available for planning

Which is hardly surprising, given the test removes the rows just before.

It's unclear what the test is trying to do -- removing the rows in that table will block SQL planning, which will prevent further SQL.

Expected behavior

The test works equally well when pointed to a secondary tenant.

cc @dt

Jira issue: CRDB-30910

Epic CRDB-26687

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions