Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion core/src/main/resources/error/error-classes.json
Original file line number Diff line number Diff line change
Expand Up @@ -453,7 +453,7 @@
"Max offset with <rowsPerSecond> rowsPerSecond is <maxSeconds>, but it's <endSeconds> now."
]
},
"INCORRECT_RUMP_UP_RATE" : {
"INCORRECT_RAMP_UP_RATE" : {
"message" : [
"Max offset with <rowsPerSecond> rowsPerSecond is <maxSeconds>, but 'rampUpTimeSeconds' is <rampUpTimeSeconds>."
]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2387,11 +2387,11 @@ private[sql] object QueryExecutionErrors extends QueryErrorsBase {
new SparkException("Foreach writer has been aborted due to a task failure")
}

def incorrectRumpUpRate(rowsPerSecond: Long,
def incorrectRampUpRate(rowsPerSecond: Long,
maxSeconds: Long,
rampUpTimeSeconds: Long): Throwable = {
new SparkRuntimeException(
errorClass = "INCORRECT_RUMP_UP_RATE",
errorClass = "INCORRECT_RAMP_UP_RATE",
messageParameters = Map(
"rowsPerSecond" -> rowsPerSecond.toString,
"maxSeconds" -> maxSeconds.toString,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ class RateStreamMicroBatchStream(
private val maxSeconds = Long.MaxValue / rowsPerSecond

if (rampUpTimeSeconds > maxSeconds) {
throw QueryExecutionErrors.incorrectRumpUpRate(
throw QueryExecutionErrors.incorrectRampUpRate(
rowsPerSecond, maxSeconds, rampUpTimeSeconds)
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -197,7 +197,7 @@ class RateStreamProviderSuite extends StreamTest {
}
}

testQuietly("microbatch - rump up error") {
testQuietly("microbatch - ramp up error") {
val e = intercept[SparkRuntimeException](
new RateStreamMicroBatchStream(
rowsPerSecond = Long.MaxValue,
Expand All @@ -207,7 +207,7 @@ class RateStreamProviderSuite extends StreamTest {

checkError(
exception = e,
errorClass = "INCORRECT_RUMP_UP_RATE",
errorClass = "INCORRECT_RAMP_UP_RATE",
parameters = Map(
"rowsPerSecond" -> Long.MaxValue.toString,
"maxSeconds" -> "1",
Expand Down