Skip to content
This repository was archived by the owner on Apr 22, 2025. It is now read-only.
This repository was archived by the owner on Apr 22, 2025. It is now read-only.

PeerConnection Listener Memory Leak? #135

@cal2195

Description

@cal2195

Hello,

I've been working with this library, and I've come across a problem. While using the PeerDHT, after a few hours, my application crashes with OutOfMemory. It appears that the PeerConnections aren't being GC'd, and they build up after a couple of hours!

After inspecting the heap dump, I can see a NioDatagramChannel with 390,509 closeFuture listeners attached, most of which are PeerConnections?

Am I doing something wrong, or is there a reason why tens of thousands of PeerConnections are persisting between 4 peers?

Thanks!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions