Skip to content

Document dlclose restrictions for Go-based (cgo) drivers #4210

@metegenez

Description

@metegenez

What feature or improvement would you like to see?

Following up on the discussion in #4206 (comment)

Embedders integrating the C driver manager (e.g., StarRocks, DuckDB) currently have to discover this through the Rust manager's changelog or by debugging hangs at process shutdown.

Proposal: add a section to the C driver manager (maybe for JNI part as well) documentation covering:

  1. dlclose must not be called on Go-based driver handles. Driver handles should stay resident until process exit.
  2. Cleanup should go through the ADBC API only: AdbcStatementRelease -> AdbcConnectionRelease -> AdbcDatabaseRelease.
  3. Multiple Go-based drivers can be dlopen-ed in the same process on Linux and ARM macOS, but not on Intel macOS (due to an unresolved Go runtime bug).

Metadata

Metadata

Assignees

No one assigned

    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