File tree Expand file tree Collapse file tree 2 files changed +3
-3
lines changed
sql/core/src/main/scala/org/apache/spark/sql Expand file tree Collapse file tree 2 files changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -61,7 +61,7 @@ def test_set_jvm_default_session(self):
6161
6262 def test_jvm_default_session_already_set (self ):
6363 # Here, we assume there is the default session already set in JVM.
64- jsession = self .sc ._jvm .SparkSession (self .sc ._jsc .sc (), self . sc . _jvm . PythonUtils . toScalaMap ({}) )
64+ jsession = self .sc ._jvm .SparkSession (self .sc ._jsc .sc ())
6565 self .sc ._jvm .SparkSession .setDefaultSession (jsession )
6666
6767 spark = SparkSession .builder .getOrCreate ()
Original file line number Diff line number Diff line change @@ -91,8 +91,6 @@ class SparkSession private(
9191 // The call site where this SparkSession was constructed.
9292 private val creationSite : CallSite = Utils .getCallSite()
9393
94- private [sql] def this (sc : SparkContext ) = this (sc, Map .empty)
95-
9694 /**
9795 * Constructor used in Pyspark. Contains explicit application of Spark Session Extensions
9896 * which otherwise only occurs during getOrCreate. We cannot add this to the default constructor
@@ -106,6 +104,8 @@ class SparkSession private(
106104 new SparkSessionExtensions ), initialSessionOptions)
107105 }
108106
107+ private [sql] def this (sc : SparkContext ) = this (sc, Map .empty)
108+
109109 private [sql] val sessionUUID : String = UUID .randomUUID.toString
110110
111111 sparkContext.assertNotStopped()
You can’t perform that action at this time.
0 commit comments