SparkSession.NewSession Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Start a new session with isolated SQL configurations, temporary tables, registered functions are isolated, but sharing the underlying SparkContext and cached data.
public Microsoft.Spark.Sql.SparkSession NewSession ();
member this.NewSession : unit -> Microsoft.Spark.Sql.SparkSession
Public Function NewSession () As SparkSession
Returns
New SparkSession object
Remarks
Other than the SparkContext, all shared state is initialized lazily. This method will force the initialization of the shared state to ensure that parent and child sessions are set up with the same shared state. If the underlying catalog implementation is Hive, this will initialize the metastore, which may take some time.