You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: sql/core/src/main/scala/org/apache/spark/sql/execution/python/streaming/TransformWithStateInPySparkStateServer.scala
+11-3Lines changed: 11 additions & 3 deletions
Original file line number
Diff line number
Diff line change
@@ -208,14 +208,22 @@ class TransformWithStateInPySparkStateServer(
208
208
privatedefparseProtoMessage():StateRequest= {
209
209
valmessageLen= inputStream.readInt()
210
210
valmessageBytes=newArray[Byte](messageLen)
211
-
valreadBytes= inputStream.read(messageBytes)
212
211
// inputStream.readFully(messageBytes)
213
-
// val readBytes = messageLen
212
+
// inputStream.read(messageBytes)
213
+
// /*
214
+
valreadBytes= inputStream.read(messageBytes)
214
215
if (readBytes != messageLen) {
215
216
thrownewException(s"TESTING: Failed to read message bytes: expected $messageLen bytes, "+
216
217
s"but only read $readBytes bytes")
217
218
}
218
-
219
+
/*
220
+
else if (messageLen > 500) {
221
+
val debug = StateRequest.parseFrom(ByteString.copyFrom(messageBytes))
222
+
throw new Exception(s"Unexpectedly matched message length: $messageLen bytes, "
0 commit comments