This is an automated email from the ASF dual-hosted git repository.

alamb pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/datafusion.git


The following commit(s) were added to refs/heads/main by this push:
     new 66933ccbbb Add debug logging for default catalog overwrite in 
SessionState build (#15251)
66933ccbbb is described below

commit 66933ccbbbb3d965effd211a97e28534a71b96f2
Author: cjw <[email protected]>
AuthorDate: Tue Mar 18 00:05:23 2025 +0800

    Add debug logging for default catalog overwrite in SessionState build 
(#15251)
    
    Co-authored-by: Kermit <[email protected]>
---
 datafusion/core/src/execution/session_state.rs | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/datafusion/core/src/execution/session_state.rs 
b/datafusion/core/src/execution/session_state.rs
index 32c04409ad..d640f8e37a 100644
--- a/datafusion/core/src/execution/session_state.rs
+++ b/datafusion/core/src/execution/session_state.rs
@@ -1415,10 +1415,14 @@ impl SessionStateBuilder {
                 &state.runtime_env,
             );
 
-            state.catalog_list.register_catalog(
+            let existing_default_catalog = state.catalog_list.register_catalog(
                 state.config.options().catalog.default_catalog.clone(),
                 Arc::new(default_catalog),
             );
+
+            if existing_default_catalog.is_some() {
+                debug!("Overwrote the default catalog");
+            }
         }
 
         if let Some(analyzer_rules) = analyzer_rules {


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to