gaurav-narula commented on code in PR #23537:
URL: https://github.com/apache/kafka/pull/23537#discussion_r4098471160


##########
tests/kafkatest/services/kafka/kafka.py:
##########
@@ -972,6 +972,9 @@ def run_features_command(self, op, feature, new_version):
     def pids(self, node):
         """Return process ids associated with running processes on the given 
node."""
         try:
+            kafka_mode = self.context.globals.get("kafka_mode", "")
+            if kafka_mode == "native":
+                return [int(pid) for pid in node.account.ssh_capture(f"pgrep 
{self.java_class_name()}", allow_fail=True)]

Review Comment:
   Thanks for your review Murali!
   
   The native process' name is `kafka.Kafka` and that's what 
`self.java_class_name()` returns. You can verify the correctness of this change 
by running a system test in native mode like so:
   
   ```
   _DUCKTAPE_OPTIONS="--globals '{\"kafka_mode\":\"native\"}'" 
TC_PATHS="tests/kafkatest/tests/client/compression_test.py" bash 
tests/docker/run_tests.sh
   ```



-- 
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]

Reply via email to