-
Notifications
You must be signed in to change notification settings - Fork 29k
[SPARK-31894][SS] Introduce UnsafeRow format validation for streaming state store #28707
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from 1 commit
1119756
2153abf
179208a
4c919ca
b83f0c3
0313016
fc5ad19
12eb2a2
01007fb
fd74ff9
557eb30
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
- Loading branch information
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -259,6 +259,8 @@ private[state] class HDFSBackedStateStoreProvider extends StateStoreProvider wit | |
| @volatile private var storeConf: StateStoreConf = _ | ||
| @volatile private var hadoopConf: Configuration = _ | ||
| @volatile private var numberOfVersionsToRetainInMemory: Int = _ | ||
| // TODO: The validation should be moved to a higher level so that it works for all state store | ||
| // implementations | ||
| @volatile private var isValidated = false | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Can we add a TODO that this validation should be moved to a higher level so that it works for all state store implementations?
Member
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Thanks, add the TODO in fd74ff9. |
||
|
|
||
| private lazy val loadedMaps = new util.TreeMap[Long, MapType](Ordering[Long].reverse) | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -32,7 +32,6 @@ import org.apache.spark.internal.Logging | |
| import org.apache.spark.sql.catalyst.expressions.UnsafeRow | ||
| import org.apache.spark.sql.catalyst.util.UnsafeRowUtils | ||
| import org.apache.spark.sql.execution.streaming.StatefulOperatorStateInfo | ||
| import org.apache.spark.sql.internal.SQLConf | ||
| import org.apache.spark.sql.types.StructType | ||
| import org.apache.spark.util.{ThreadUtils, Utils} | ||
|
|
||
|
|
@@ -149,7 +148,7 @@ case class StateStoreCustomTimingMetric(name: String, desc: String) extends Stat | |
| * An exception thrown when an invalid UnsafeRow is detected in state store. | ||
| */ | ||
| class InvalidUnsafeRowException | ||
| extends SparkException("The streaming query failed by state format invalidation. " + | ||
| extends RuntimeException("The streaming query failed by state format invalidation. " + | ||
| "The following reasons may cause this: 1. An old Spark version wrote the checkpoint that is " + | ||
| "incompatible with the current one; 2. Broken checkpoint files; 3. The query is changed " + | ||
| "among restart. For the first case, you can try to restart the application without " + | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Member
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The resolution is for the first case. For the rest cases listing, they should be considered as user problems. |
||
|
|
||
Uh oh!
There was an error while loading. Please reload this page.