You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@phoenix.apache.org by GitBox <gi...@apache.org> on 2020/07/07 15:15:13 UTC

[GitHub] [phoenix] gjacoby126 commented on a change in pull request #823: PHOENIX-5991 IndexRegionObserver should not overwrite mutation timest…

gjacoby126 commented on a change in pull request #823:
URL: https://github.com/apache/phoenix/pull/823#discussion_r450943309



##########
File path: phoenix-core/src/it/java/org/apache/phoenix/end2end/DeleteIT.java
##########
@@ -817,7 +838,59 @@ private void testDeleteCount(boolean autoCommit, Integer limit) throws Exception
         }
 
     }
-    
+
+    private void testDeleteCountWithIndex(boolean autoCommit, boolean scn) throws Exception {
+        String tableName = generateUniqueName();
+        String tableDDL = "CREATE TABLE IF NOT EXISTS " + tableName + " (pk1 DECIMAL NOT NULL, v1 VARCHAR CONSTRAINT PK PRIMARY KEY (pk1))";
+        String indexName = generateUniqueName();
+        String indexDDL = "CREATE INDEX IF NOT EXISTS " + indexName + " ON " + tableName + "(v1)";
+        int numRecords = 1010;

Review comment:
       If you do go that way, please remember to reset() the EnvironmentEdgeManager in a finally block

##########
File path: phoenix-core/src/it/java/org/apache/phoenix/end2end/DeleteIT.java
##########
@@ -817,7 +838,59 @@ private void testDeleteCount(boolean autoCommit, Integer limit) throws Exception
         }
 
     }
-    
+
+    private void testDeleteCountWithIndex(boolean autoCommit, boolean scn) throws Exception {
+        String tableName = generateUniqueName();
+        String tableDDL = "CREATE TABLE IF NOT EXISTS " + tableName + " (pk1 DECIMAL NOT NULL, v1 VARCHAR CONSTRAINT PK PRIMARY KEY (pk1))";
+        String indexName = generateUniqueName();
+        String indexDDL = "CREATE INDEX IF NOT EXISTS " + indexName + " ON " + tableName + "(v1)";
+        int numRecords = 1010;

Review comment:
       do we need so many rows to test the timestamp behavior? How much time do these tests add to the test suite run? Seems like you could get the same effect in the scn case with 2 rows, using the edge manager to force a two millisecond time increment between the two upserts. 




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

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