Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Logging #132

Merged
merged 8 commits into from
Jan 14, 2025
Merged

Add Logging #132

merged 8 commits into from
Jan 14, 2025

Conversation

samansmink
Copy link
Collaborator

With DuckDB's new logging infra, we can hook up the delta logging to the DuckDB logger to allow us to expose the kernel logging in a clean way to DuckDB users.

To enable:

set enable_logging=true;
set delta_kernel_logging=true;
set logging_level='DEBUG'

FROM delta_scan('...');

FROM duckdb_logs;

will now show entries such as:

2025-01-13 12:30:22.033	delta.Kernel	DEBUG	[delta_kernel_ffi] ffi/src/lib.rs@363 : dropping engine interface 	DATABASE	NULL	NULL	NULL
2025-01-13 12:30:22.033	delta.Kernel	DEBUG	[delta_kernel_ffi] ffi/src/lib.rs@594 : engine released snapshot 	DATABASE	NULL	NULL	NULL

Note that the 'delta_kernel_logging' setting was added to explicitly enable kernel log forwarding, because enabling them by default might be potentially expensive even if DuckDB logging is enabled. Also note that disabling kernel logging forwarding is not possible because the ffi has no way of unregistering the callback.

@samansmink samansmink merged commit 4691801 into duckdb:feature Jan 14, 2025
19 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant