You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@phoenix.apache.org by "vmeka2020 (via GitHub)" <gi...@apache.org> on 2025/07/25 05:52:26 UTC

[PR] PHOENIX-7625 Adding query plan information to connection Activity Logger [phoenix]

vmeka2020 opened a new pull request, #2246:
URL: https://github.com/apache/phoenix/pull/2246

   (no comment)


-- 
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: issues-unsubscribe@phoenix.apache.org

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


Re: [PR] PHOENIX-7625 Adding query plan information to ConnectionActivityLogger [phoenix]

Posted by "virajjasani (via GitHub)" <gi...@apache.org>.
virajjasani merged PR #2246:
URL: https://github.com/apache/phoenix/pull/2246


-- 
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: issues-unsubscribe@phoenix.apache.org

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


Re: [PR] PHOENIX-7625 Adding query plan information to connection Activity Logger [phoenix]

Posted by "vmeka2020 (via GitHub)" <gi...@apache.org>.
vmeka2020 commented on PR #2246:
URL: https://github.com/apache/phoenix/pull/2246#issuecomment-3116497321

   Link to CI build: https://ci-hadoop.apache.org/job/Phoenix/job/Phoenix-PreCommit-GitHub-PR/job/PR-2246/


-- 
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: issues-unsubscribe@phoenix.apache.org

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


Re: [PR] PHOENIX-7625 Adding query plan information to connection Activity Logger [phoenix]

Posted by "vmeka2020 (via GitHub)" <gi...@apache.org>.
vmeka2020 commented on code in PR #2246:
URL: https://github.com/apache/phoenix/pull/2246#discussion_r2238279209


##########
phoenix-core/src/it/java/org/apache/phoenix/jdbc/LoggingConnectionLimiterIT.java:
##########
@@ -186,6 +187,55 @@ public void testActivityLogsOnQueryWhenFailures() throws Exception {
 
   }
 
+  @Test
+  public void testQueryExplainPlan() throws Exception {
+
+    String query = "SELECT * FROM " + tableName; // FULL SCAN
+
+    if (getConnection() instanceof PhoenixConnection) {
+      try (PhoenixConnection pconn = getConnection().unwrap(PhoenixConnection.class);
+        Statement stmt = pconn.createStatement()) {
+        ResultSet rs = stmt.executeQuery(query);
+        while (rs.next()) {
+          // do nothing
+        }
+        boolean queryPlanFound = false;
+        String queryPlan = pconn.getActivityLogger().getExplainPlanInfo();

Review Comment:
   @virajjasani added the UT



-- 
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: issues-unsubscribe@phoenix.apache.org

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


Re: [PR] PHOENIX-7625 Adding query plan information to connection Activity Logger [phoenix]

Posted by "virajjasani (via GitHub)" <gi...@apache.org>.
virajjasani commented on code in PR #2246:
URL: https://github.com/apache/phoenix/pull/2246#discussion_r2234985340


##########
phoenix-core/src/it/java/org/apache/phoenix/jdbc/LoggingConnectionLimiterIT.java:
##########
@@ -186,6 +187,55 @@ public void testActivityLogsOnQueryWhenFailures() throws Exception {
 
   }
 
+  @Test
+  public void testQueryExplainPlan() throws Exception {
+
+    String query = "SELECT * FROM " + tableName; // FULL SCAN
+
+    if (getConnection() instanceof PhoenixConnection) {
+      try (PhoenixConnection pconn = getConnection().unwrap(PhoenixConnection.class);
+        Statement stmt = pconn.createStatement()) {
+        ResultSet rs = stmt.executeQuery(query);
+        while (rs.next()) {
+          // do nothing
+        }
+        boolean queryPlanFound = false;
+        String queryPlan = pconn.getActivityLogger().getExplainPlanInfo();

Review Comment:
   Can we add a test in some other IT class where we can validate that queryPlan is null by default?



-- 
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: issues-unsubscribe@phoenix.apache.org

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


Re: [PR] PHOENIX-7625 Adding query plan information to connection Activity Logger [phoenix]

Posted by "virajjasani (via GitHub)" <gi...@apache.org>.
virajjasani commented on PR #2246:
URL: https://github.com/apache/phoenix/pull/2246#issuecomment-3133946943

   Awaiting final build results before merging the PR


-- 
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: issues-unsubscribe@phoenix.apache.org

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