You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by "hvanhovell (via GitHub)" <gi...@apache.org> on 2023/09/01 04:18:14 UTC

[GitHub] [spark] hvanhovell commented on a diff in pull request #42377: [SPARK-44622][SQL][CONNECT] Implement error enrichment and setting server-side stacktrace

hvanhovell commented on code in PR #42377:
URL: https://github.com/apache/spark/pull/42377#discussion_r1312520702


##########
connector/connect/common/src/main/protobuf/spark/connect/base.proto:
##########
@@ -778,6 +778,67 @@ message ReleaseExecuteResponse {
   optional string operation_id = 2;
 }
 
+// FetchErrorDetailsRequest defines criteria for retrieving cached exceptions.
+message FetchErrorDetailsRequest {
+
+  // (Required)
+  //
+  // The session_id specifies a spark session for a user id (which is specified
+  // by user_context.user_id).
+  // The id should be an UUID string of the format `00112233-4455-6677-8899-aabbccddeeff`
+  string session_id = 1;
+
+  // User context
+  UserContext user_context = 2;
+
+  // (Required)
+  // The id of the error.
+  string error_id = 3;
+
+  // Whether to include the stacktrace in the error message when
+  // the SQLConf spark.sql.connect.serverStacktrace.enabled is true.
+  optional bool stacktrace_in_message = 4;
+}
+
+// FetchErrorDetailsResponse returns list of exceptions matching the given error ids.
+message FetchErrorDetailsResponse {
+
+  message StackTraceElement {
+
+    // Fully qualified name of the class containing the execution point.
+    string declaring_class = 1;
+
+    // Name of the method containing the execution point.
+    string method_name = 2;
+
+    // Name of the file containing the execution point.
+    string file_name = 3;
+
+    // Line number of the source line containing the execution point.
+    int32 line_number = 4;
+  }
+
+  // ExceptionInfo represents the serialized form of an exception.
+  message ExceptionInfo {
+    // Fully qualified names of the exception class and its parent classes.
+    repeated string error_type_hierarchy = 2;
+
+    // Detailed message of the exception.
+    string message = 3;
+
+    // StackTrace of the exception. It will be set
+    // if the SQLConf spark.sql.connect.serverStacktrace.enabled is true.
+    repeated StackTraceElement stack_trace = 4;
+
+    // The id of the cause error.

Review Comment:
   `The id of the error that caused this one`?



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org