Skip to content

Commit 2b011c9

Browse files
fix broken tests
1 parent 60d97a4 commit 2b011c9

File tree

1 file changed

+5
-6
lines changed

1 file changed

+5
-6
lines changed

core/src/main/scala/org/apache/spark/deploy/rest/StandaloneRestClient.scala

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -114,17 +114,16 @@ private[deploy] class StandaloneRestClient(master: String) extends Logging {
114114
logInfo(s"Submitting a request for the status of submission $submissionId in $master.")
115115
var suc: Boolean = false
116116
var response: SubmitRestProtocolResponse = null
117+
masters.foreach(println(_))
117118
for (m <- masters) {
118119
validateMaster(m)
119120
response = get(getStatusUrl(m, submissionId))
120121
response match {
121-
case s: SubmissionStatusResponse =>
122-
if (!s.message.contains("Can only")) {
123-
if (!quiet) {
124-
handleRestResponse(s)
125-
}
126-
suc = true
122+
case s: SubmissionStatusResponse if s.success =>
123+
if (!quiet) {
124+
handleRestResponse(s)
127125
}
126+
suc = true
128127
case unexpected =>
129128
handleUnexpectedRestResponse(unexpected)
130129
}

0 commit comments

Comments
 (0)