Skip to content

Add support for DuckDB#121

Merged
RasmusSkytte merged 20 commits intomainfrom
feature/duck_db
Feb 27, 2024
Merged

Add support for DuckDB#121
RasmusSkytte merged 20 commits intomainfrom
feature/duck_db

Conversation

@RasmusSkytte
Copy link
Copy Markdown
Contributor

@RasmusSkytte RasmusSkytte commented Feb 26, 2024

Intent

This PR adds support for DuckDB.

Approach

Several of the S3 functions interfacing directly with the backend needed an extension for DuckDB.

In addition, get_connection() was converted to a S3 generic to better separate the different arguments needed for each backend.

Known issues

The DuckDB backend is showing a lot warning messages about garbage collection.

Database is garbage-collected, use dbDisconnect(con, shutdown=TRUE) or duckdb::duckdb_shutdown(drv) to avoid this.

Looking into the root cause of this, we are using shutdown = TRUE..

Turns out we needed to shutdown the driver AND the connection.

Checklist

  • The PR passes all local unit tests
  • I have documented any new features introduced
  • If the PR adds a new feature, please add an entry in NEWS.md
  • A reviewer is assigned to this PR

@RasmusSkytte RasmusSkytte self-assigned this Feb 26, 2024
@RasmusSkytte RasmusSkytte added the enhancement New feature or request label Feb 26, 2024
@RasmusSkytte RasmusSkytte added this to the v0.4 milestone Feb 26, 2024
Copy link
Copy Markdown
Contributor

@LasseEngboChr LasseEngboChr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just two small items to look at - and great that it was relatively easy to add a fourth backend :-)

@RasmusSkytte RasmusSkytte merged commit e0be72e into main Feb 27, 2024
@RasmusSkytte RasmusSkytte deleted the feature/duck_db branch February 27, 2024 11:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants