Skip to content

Python binding and life time of host and subystem #3736

Description

@igaw

The Python bindings use libnvme_get_host() and libnvme_get_subsystem() to obtain C objects representing a host or subsystem. The problem is that the lifetime of the Python objects and the underlying C objects is not coupled.

libnvme was originally designed with the assumption that it would not be used by long-running processes. However, current use cases are pushing the library into new domains, such as long-running applications that keep object references alive.

This makes it necessary for the public API to track object lifetimes.

The simplest solution is probably reference counting.

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