ueshin commented on code in PR #45091:
URL: https://github.com/apache/spark/pull/45091#discussion_r1501037087


##########
connector/connect/common/src/main/protobuf/spark/connect/commands.proto:
##########
@@ -421,6 +424,39 @@ message StreamingQueryManagerCommandResult {
   }
 }
 
+// The protocol for client-side StreamingQueryListener.
+// This command will only be set when either the first listener is added to 
the client, or the last
+// listener is removed from the client.
+// The add_listener_bus_listener command will only be set true in the first 
case.
+// The remove_listener_bus_listener command will only be set true in the 
second case.
+message StreamingQueryListenerBusCommand {
+  oneof command {
+    bool add_listener_bus_listener = 1;
+    bool remove_listener_bus_listener = 2;
+  }
+}
+
+// The enum used for client side streaming query listener event
+// There is no QueryStartedEvent defined here,
+// it is added as a field in WriteStreamOperationStartResult
+enum StreamingQueryEventType {
+  QUERY_PROGRESS_EVENT = 0;
+  QUERY_TERMINATED_EVENT = 1;
+  QUERY_IDLE_EVENT = 2;
+}

Review Comment:
   Also, each variable should have the same prefix as the enum name? I'm not 
sure if this is a strict rule or not, though. @grundprinzip @amaliujia 



-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to