Skip to content

Connections remain in CLOSE_WAIT status due to lack of proper disposal #41

@ashishbinu

Description

@ashishbinu

The network connections in the Connection and Connector classes are not being properly disposed, leading to connections lingering in the CLOSE_WAIT state.

To fix this, the classes should implement IDisposable to ensure proper cleanup of resources.

I propose updating the client.Replicate function to use the connection like this:

using var connector = new Connector(_options);
var (connection, databaseProvider) = await connector.ConnectAsync(cancellationToken);

If this is okay, I can submit a PR for these changes.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions