Skip to content

Question: how detect and deal with zombie embedded processes #148

@ericedem

Description

@ericedem

Hello, and thanks for the awesome library! We are using embedded postgres heavily in our tests which has been great.

One problem we are having is that when the process dies unexpectedly we end up with zombie processes because we were unable to call Stop() on the postgres db. In general we are able to catch this due to expected failures like failed tests, but sometimes we can't like when a debugger is running the process and gets terminated instead of running to completion.

Is there a reasonable way people have come up to deal with this problem? The best ideas I have had is using a terminal command like netstat to check a known port at test startup and try to kill any zombies but this is not ideal as it exits the test runtime and could interfere with normal processes on the host machine.

Cheers.

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