Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Handle leaks are reported intermingled on app exit #224

@tchaloupka

Description

@tchaloupka

Sample output for 4 threads:

[vibe-1(RfiZ) INF] Listening for requests on http://0.0.0.0:8080/
[vibe-3(MsfE) INF] Listening for requests on http://0.0.0.0:8080/
[vibe-2(kqJG) INF] Listening for requests on http://0.0.0.0:8080/
[vibe-0(q6Kw) INF] Listening for requests on http://0.0.0.0:8080/
^C[main(----) INF] Received signal 2. Shutting down.
WWarning (thread: vibe-2): lWarnieaking eventcore narWganin rdg (ri(nthread: ver becausthrvibe-0e e)itn: leakiaghndge (thread: vibe-1): vibe-3): leaki er:nve ge l naeeventcore raking eventctde sticroloirlrve e driver because therree activeb   eadhriver bceacanuadre stillse tlh eusere are sa there tceare stilitslli
 l acv   FateDctive handlei  s4
vh7ae  n  (dh streamListenlaF)es
n D
   FD 49 (streamListen)
22 (streamListen)
dles
   FD 25 (streamListen)
Warning (thread: vibe-2): leaking eventcore driver because theWarniWare are still acWarning (threang (thretadrive handle: vibe-3): leakidsnng i:
en  vgvibe-0 en) FD 47  t:(streamListen)
core (thread: vibe-1): leaking eventcore driver because there are still active handles
   FD 22 (streamListen)
 leaking eventcore driver driver because there are still active handles
   FD 25 (streamListen)
because there are still active handles
   FD 49 (streamListen)
  • eventcore: 0.9.8
  • vibe-core: 1.9.4
  • vibe-d: 0.9.1

Test code:

void main() {
    setupWorkerThreads(4);
    runWorkerTaskDist(&runServer);
    runApplication();
}

void runServer() {
    auto settings = new HTTPServerSettings;
    settings.options |= HTTPServerOption.reusePort;
    settings.bindAddresses = ["0.0.0.0"];
    settings.port = 8080;
    listenHTTP(settings, &handleRequest);
}

void handleRequest(scope HTTPServerRequest req, scope HTTPServerResponse res) {
        res.writeBody("Hello, World!", "text/plain");
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions