Skip to content

withClient API can hit precondition #2214

Closed
@FranzBusch

Description

@FranzBusch

Describe the bug

If the withGRPCClient API is called with an empty handleClient closure then it is possible to hit the The client has stopped and can only be started once. precondition in its internal state machine. The reason for this is that beginGracefulShutdown() is called before runConnections().

To reproduce

Write a test that does this

try await GRPCClient.withGRPCClient(....) {}

Expected behaviour

We should handle this gracefully

Metadata

Metadata

Assignees

No one assigned

    Labels

    kind/bugFeature doesn't work as expected.version/v2Relates to v2

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions