You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@arrow.apache.org by al...@apache.org on 2023/01/17 18:22:52 UTC

[arrow-datafusion] branch maint-16.x updated: Make it able to specify a session id for SessionState (#4933) (#4951)

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

alamb pushed a commit to branch maint-16.x
in repository https://gitbox.apache.org/repos/asf/arrow-datafusion.git


The following commit(s) were added to refs/heads/maint-16.x by this push:
     new cecc1279a Make it able to specify a session id for SessionState (#4933) (#4951)
cecc1279a is described below

commit cecc1279a37f48b20ee6a5da1b612761583b0f0d
Author: Andy Grove <an...@gmail.com>
AuthorDate: Tue Jan 17 11:22:45 2023 -0700

    Make it able to specify a session id for SessionState (#4933) (#4951)
    
    Co-authored-by: yangzhong <ya...@ebay.com>
    
    Co-authored-by: yahoNanJing <90...@users.noreply.github.com>
    Co-authored-by: yangzhong <ya...@ebay.com>
---
 datafusion/core/src/execution/context.rs | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/datafusion/core/src/execution/context.rs b/datafusion/core/src/execution/context.rs
index 98fe6ff79..a3e453a2a 100644
--- a/datafusion/core/src/execution/context.rs
+++ b/datafusion/core/src/execution/context.rs
@@ -1585,6 +1585,12 @@ impl SessionState {
             })
     }
 
+    /// Replace the random session id.
+    pub fn with_session_id(mut self, session_id: String) -> Self {
+        self.session_id = session_id;
+        self
+    }
+
     /// Replace the default query planner
     pub fn with_query_planner(
         mut self,