@@ -22,8 +22,8 @@ import java.util.jar.JarFile
2222
2323import scala .collection .mutable .{ArrayBuffer , HashMap }
2424
25+ import org .apache .spark .deploy .SparkSubmitAction .SparkSubmitAction
2526import org .apache .spark .util .Utils
26- import org .apache .spark .deploy .Action .Action
2727
2828/**
2929 * Parses and encapsulates arguments from the spark-submit script.
@@ -60,11 +60,11 @@ private[spark] class SparkSubmitArguments(args: Seq[String], env: Map[String, St
6060 var driverToKill : String = null
6161 var driverToRequestStatusFor : String = null
6262
63- def action : Action = {
63+ def action : SparkSubmitAction = {
6464 (driverToKill, driverToRequestStatusFor) match {
65- case (null , null ) => Action .SUBMIT
66- case (_, null ) => Action .KILL
67- case (null , _) => Action .REQUEST_STATUS
65+ case (null , null ) => SparkSubmitAction .SUBMIT
66+ case (_, null ) => SparkSubmitAction .KILL
67+ case (null , _) => SparkSubmitAction .REQUEST_STATUS
6868 case _ => SparkSubmit .printErrorAndExit(
6969 " Requested to both kill and request status for a driver. Choose only one." )
7070 null // never reached
@@ -189,9 +189,9 @@ private[spark] class SparkSubmitArguments(args: Seq[String], env: Map[String, St
189189 /** Ensure that required fields exists. Call this only once all defaults are loaded. */
190190 private def validateArguments (): Unit = {
191191 action match {
192- case Action .SUBMIT => validateSubmitArguments()
193- case Action .KILL => validateKillArguments()
194- case Action .REQUEST_STATUS => validateStatusRequestArguments()
192+ case SparkSubmitAction .SUBMIT => validateSubmitArguments()
193+ case SparkSubmitAction .KILL => validateKillArguments()
194+ case SparkSubmitAction .REQUEST_STATUS => validateStatusRequestArguments()
195195 }
196196 }
197197
0 commit comments