alamb commented on code in PR #10794:
URL: https://github.com/apache/datafusion/pull/10794#discussion_r1628022118


##########
datafusion/core/src/execution/context/mod.rs:
##########
@@ -1280,7 +1253,7 @@ impl SessionContext {
     /// `query_execution_start_time` to the current time
     pub fn state(&self) -> SessionState {
         let mut state = self.state.read().clone();
-        state.execution_props.start_execution();
+        state.execution_props_mut().start_execution();

Review Comment:
   It is needed because the start execution method actually modifies the 
execution_props field -- when SessionContext was part of the same module, it 
could simply directly modify `state.execution_props` (the field, not a method)
   
   Now that they are in separate modules, SessionContext can't modify 
`SessionState` internal fields directly.
   
   So TLDR is that this code does the same as the previous version (modifies  
`execution_props`) but is more explicit about it, which I think is an 
improvement



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


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

Reply via email to