Repository: phoenix Updated Branches: refs/heads/4.x-HBase-1.2 ceed6a652 -> ea8646c7d
PHOENIX-4070 Delete row should mask upserts at same timestamp (addendum for typos) Project: http://git-wip-us.apache.org/repos/asf/phoenix/repo Commit: http://git-wip-us.apache.org/repos/asf/phoenix/commit/ea8646c7 Tree: http://git-wip-us.apache.org/repos/asf/phoenix/tree/ea8646c7 Diff: http://git-wip-us.apache.org/repos/asf/phoenix/diff/ea8646c7 Branch: refs/heads/4.x-HBase-1.2 Commit: ea8646c7d8d2061174a7ec49ea6b664f208ad876 Parents: ceed6a6 Author: James Taylor <[email protected]> Authored: Mon Aug 7 23:27:53 2017 -0700 Committer: James Taylor <[email protected]> Committed: Mon Aug 7 23:33:44 2017 -0700 ---------------------------------------------------------------------- .../phoenix/end2end/OutOfOrderMutationsIT.java | 18 +++++++-------- .../end2end/index/PartialIndexRebuilderIT.java | 24 ++++++++++---------- .../java/org/apache/phoenix/util/TestUtil.java | 2 +- 3 files changed, 22 insertions(+), 22 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/phoenix/blob/ea8646c7/phoenix-core/src/it/java/org/apache/phoenix/end2end/OutOfOrderMutationsIT.java ---------------------------------------------------------------------- diff --git a/phoenix-core/src/it/java/org/apache/phoenix/end2end/OutOfOrderMutationsIT.java b/phoenix-core/src/it/java/org/apache/phoenix/end2end/OutOfOrderMutationsIT.java index 0e038e2..5cdc1ee 100644 --- a/phoenix-core/src/it/java/org/apache/phoenix/end2end/OutOfOrderMutationsIT.java +++ b/phoenix-core/src/it/java/org/apache/phoenix/end2end/OutOfOrderMutationsIT.java @@ -91,7 +91,7 @@ public class OutOfOrderMutationsIT extends ParallelStatsDisabledIT { props.setProperty(PhoenixRuntime.CURRENT_SCN_ATTRIB, Long.toString(ts)); conn = DriverManager.getConnection(getUrl(), props); - TestUtil.scutinizeIndex(conn, tableName, indexName); + TestUtil.scrutinizeIndex(conn, tableName, indexName); assertNoTimeStampAt(conn, indexName, 1030); conn.close(); @@ -175,7 +175,7 @@ public class OutOfOrderMutationsIT extends ParallelStatsDisabledIT { props.setProperty(PhoenixRuntime.CURRENT_SCN_ATTRIB, Long.toString(ts)); conn = DriverManager.getConnection(getUrl(), props); - TestUtil.scutinizeIndex(conn, tableName, indexName); + TestUtil.scrutinizeIndex(conn, tableName, indexName); ResultSet rs = conn.createStatement().executeQuery("SELECT /*+ NO_INDEX */ ts FROM " + tableName); assertTrue(rs.next()); @@ -265,7 +265,7 @@ public class OutOfOrderMutationsIT extends ParallelStatsDisabledIT { TestUtil.dumpTable(conn.unwrap(PhoenixConnection.class).getQueryServices().getTable(Bytes.toBytes(tableName))); TestUtil.dumpTable(conn.unwrap(PhoenixConnection.class).getQueryServices().getTable(Bytes.toBytes(indexName))); - TestUtil.scutinizeIndex(conn, tableName, indexName); + TestUtil.scrutinizeIndex(conn, tableName, indexName); ResultSet rs = conn.createStatement().executeQuery("SELECT /*+ NO_INDEX */ ts FROM " + tableName); assertTrue(rs.next()); @@ -331,7 +331,7 @@ public class OutOfOrderMutationsIT extends ParallelStatsDisabledIT { TestUtil.dumpTable(conn.unwrap(PhoenixConnection.class).getQueryServices().getTable(Bytes.toBytes(tableName))); TestUtil.dumpTable(conn.unwrap(PhoenixConnection.class).getQueryServices().getTable(Bytes.toBytes(indexName))); - TestUtil.scutinizeIndex(conn, tableName, indexName); + TestUtil.scrutinizeIndex(conn, tableName, indexName); ResultSet rs = conn.createStatement().executeQuery("SELECT /*+ NO_INDEX */ ts FROM " + tableName); assertTrue(rs.next()); @@ -393,7 +393,7 @@ public class OutOfOrderMutationsIT extends ParallelStatsDisabledIT { TestUtil.dumpTable(conn.unwrap(PhoenixConnection.class).getQueryServices().getTable(Bytes.toBytes(tableName))); TestUtil.dumpTable(conn.unwrap(PhoenixConnection.class).getQueryServices().getTable(Bytes.toBytes(indexName))); - TestUtil.scutinizeIndex(conn, tableName, indexName); + TestUtil.scrutinizeIndex(conn, tableName, indexName); ResultSet rs = conn.createStatement().executeQuery("SELECT /*+ NO_INDEX */ ts,v FROM " + tableName); assertTrue(rs.next()); @@ -458,7 +458,7 @@ public class OutOfOrderMutationsIT extends ParallelStatsDisabledIT { TestUtil.dumpTable(conn.unwrap(PhoenixConnection.class).getQueryServices().getTable(Bytes.toBytes(tableName))); TestUtil.dumpTable(conn.unwrap(PhoenixConnection.class).getQueryServices().getTable(Bytes.toBytes(indexName))); - TestUtil.scutinizeIndex(conn, tableName, indexName); + TestUtil.scrutinizeIndex(conn, tableName, indexName); ResultSet rs = conn.createStatement().executeQuery("SELECT /*+ NO_INDEX */ ts,v FROM " + tableName); assertTrue(rs.next()); @@ -523,7 +523,7 @@ public class OutOfOrderMutationsIT extends ParallelStatsDisabledIT { TestUtil.dumpTable(conn.unwrap(PhoenixConnection.class).getQueryServices().getTable(Bytes.toBytes(tableName))); TestUtil.dumpTable(conn.unwrap(PhoenixConnection.class).getQueryServices().getTable(Bytes.toBytes(indexName))); - TestUtil.scutinizeIndex(conn, tableName, indexName); + TestUtil.scrutinizeIndex(conn, tableName, indexName); ResultSet rs = conn.createStatement().executeQuery("SELECT /*+ NO_INDEX */ ts,v FROM " + tableName); assertTrue(rs.next()); @@ -587,7 +587,7 @@ public class OutOfOrderMutationsIT extends ParallelStatsDisabledIT { TestUtil.dumpTable(conn.unwrap(PhoenixConnection.class).getQueryServices().getTable(Bytes.toBytes(tableName))); TestUtil.dumpTable(conn.unwrap(PhoenixConnection.class).getQueryServices().getTable(Bytes.toBytes(indexName))); - long rowCount = TestUtil.scutinizeIndex(conn, tableName, indexName); + long rowCount = TestUtil.scrutinizeIndex(conn, tableName, indexName); assertEquals(0,rowCount); conn.close(); @@ -640,7 +640,7 @@ public class OutOfOrderMutationsIT extends ParallelStatsDisabledIT { TestUtil.dumpTable(conn.unwrap(PhoenixConnection.class).getQueryServices().getTable(Bytes.toBytes(tableName))); TestUtil.dumpTable(conn.unwrap(PhoenixConnection.class).getQueryServices().getTable(Bytes.toBytes(indexName))); - long rowCount = TestUtil.scutinizeIndex(conn, tableName, indexName); + long rowCount = TestUtil.scrutinizeIndex(conn, tableName, indexName); assertEquals(0,rowCount); conn.close(); http://git-wip-us.apache.org/repos/asf/phoenix/blob/ea8646c7/phoenix-core/src/it/java/org/apache/phoenix/end2end/index/PartialIndexRebuilderIT.java ---------------------------------------------------------------------- diff --git a/phoenix-core/src/it/java/org/apache/phoenix/end2end/index/PartialIndexRebuilderIT.java b/phoenix-core/src/it/java/org/apache/phoenix/end2end/index/PartialIndexRebuilderIT.java index cc5f138..1e54228 100644 --- a/phoenix-core/src/it/java/org/apache/phoenix/end2end/index/PartialIndexRebuilderIT.java +++ b/phoenix-core/src/it/java/org/apache/phoenix/end2end/index/PartialIndexRebuilderIT.java @@ -74,7 +74,7 @@ public class PartialIndexRebuilderIT extends BaseUniqueNamesOwnClusterIT { assertEquals(1,count); conn.commit(); try { - TestUtil.scutinizeIndex(conn, fullTableName, fullIndexName); + TestUtil.scrutinizeIndex(conn, fullTableName, fullIndexName); fail(); } catch (AssertionError e) { assertEquals(e.getMessage(),"Expected data table row count to match expected:<1> but was:<2>"); @@ -98,7 +98,7 @@ public class PartialIndexRebuilderIT extends BaseUniqueNamesOwnClusterIT { conn.createStatement().executeUpdate("UPSERT INTO " + fullIndexName + " VALUES ('bbb','x','0')"); conn.commit(); try { - TestUtil.scutinizeIndex(conn, fullTableName, fullIndexName); + TestUtil.scrutinizeIndex(conn, fullTableName, fullIndexName); fail(); } catch (AssertionError e) { assertEquals(e.getMessage(),"Expected to find PK in data table: ('x')"); @@ -107,7 +107,7 @@ public class PartialIndexRebuilderIT extends BaseUniqueNamesOwnClusterIT { } @Test - public void testValuetIndexScrutiny() throws Throwable { + public void testValueIndexScrutiny() throws Throwable { String schemaName = generateUniqueName(); String tableName = generateUniqueName(); String indexName = generateUniqueName(); @@ -123,7 +123,7 @@ public class PartialIndexRebuilderIT extends BaseUniqueNamesOwnClusterIT { conn.createStatement().executeUpdate("UPSERT INTO " + fullIndexName + " VALUES ('ccc','a','2')"); conn.commit(); try { - TestUtil.scutinizeIndex(conn, fullTableName, fullIndexName); + TestUtil.scrutinizeIndex(conn, fullTableName, fullIndexName); fail(); } catch (AssertionError e) { assertEquals(e.getMessage(),"Expected equality for V2, but '2'!='1'"); @@ -156,7 +156,7 @@ public class PartialIndexRebuilderIT extends BaseUniqueNamesOwnClusterIT { TestUtil.dumpTable(conn.unwrap(PhoenixConnection.class).getQueryServices().getTable(Bytes.toBytes(fullTableName))); TestUtil.dumpTable(conn.unwrap(PhoenixConnection.class).getQueryServices().getTable(Bytes.toBytes(fullIndexName))); - TestUtil.scutinizeIndex(conn, fullTableName, fullIndexName); + TestUtil.scrutinizeIndex(conn, fullTableName, fullIndexName); } } @@ -185,7 +185,7 @@ public class PartialIndexRebuilderIT extends BaseUniqueNamesOwnClusterIT { TestUtil.dumpTable(conn.unwrap(PhoenixConnection.class).getQueryServices().getTable(Bytes.toBytes(fullTableName))); TestUtil.dumpTable(conn.unwrap(PhoenixConnection.class).getQueryServices().getTable(Bytes.toBytes(fullIndexName))); - TestUtil.scutinizeIndex(conn, fullTableName, fullIndexName); + TestUtil.scrutinizeIndex(conn, fullTableName, fullIndexName); } } @@ -214,7 +214,7 @@ public class PartialIndexRebuilderIT extends BaseUniqueNamesOwnClusterIT { TestUtil.dumpTable(conn.unwrap(PhoenixConnection.class).getQueryServices().getTable(Bytes.toBytes(fullTableName))); TestUtil.dumpTable(conn.unwrap(PhoenixConnection.class).getQueryServices().getTable(Bytes.toBytes(fullIndexName))); - TestUtil.scutinizeIndex(conn, fullTableName, fullIndexName); + TestUtil.scrutinizeIndex(conn, fullTableName, fullIndexName); } } @@ -241,7 +241,7 @@ public class PartialIndexRebuilderIT extends BaseUniqueNamesOwnClusterIT { TestUtil.dumpTable(conn.unwrap(PhoenixConnection.class).getQueryServices().getTable(Bytes.toBytes(fullTableName))); TestUtil.dumpTable(conn.unwrap(PhoenixConnection.class).getQueryServices().getTable(Bytes.toBytes(fullIndexName))); - TestUtil.scutinizeIndex(conn, fullTableName, fullIndexName); + TestUtil.scrutinizeIndex(conn, fullTableName, fullIndexName); } } @@ -268,7 +268,7 @@ public class PartialIndexRebuilderIT extends BaseUniqueNamesOwnClusterIT { TestUtil.dumpTable(conn.unwrap(PhoenixConnection.class).getQueryServices().getTable(Bytes.toBytes(fullTableName))); TestUtil.dumpTable(conn.unwrap(PhoenixConnection.class).getQueryServices().getTable(Bytes.toBytes(fullIndexName))); - TestUtil.scutinizeIndex(conn, fullTableName, fullIndexName); + TestUtil.scrutinizeIndex(conn, fullTableName, fullIndexName); } } @@ -299,7 +299,7 @@ public class PartialIndexRebuilderIT extends BaseUniqueNamesOwnClusterIT { TestUtil.dumpTable(conn.unwrap(PhoenixConnection.class).getQueryServices().getTable(Bytes.toBytes(fullTableName))); TestUtil.dumpTable(conn.unwrap(PhoenixConnection.class).getQueryServices().getTable(Bytes.toBytes(fullIndexName))); - TestUtil.scutinizeIndex(conn, fullTableName, fullIndexName); + TestUtil.scrutinizeIndex(conn, fullTableName, fullIndexName); } } @@ -330,7 +330,7 @@ public class PartialIndexRebuilderIT extends BaseUniqueNamesOwnClusterIT { TestUtil.dumpTable(conn.unwrap(PhoenixConnection.class).getQueryServices().getTable(Bytes.toBytes(fullTableName))); TestUtil.dumpTable(conn.unwrap(PhoenixConnection.class).getQueryServices().getTable(Bytes.toBytes(fullIndexName))); - TestUtil.scutinizeIndex(conn, fullTableName, fullIndexName); + TestUtil.scrutinizeIndex(conn, fullTableName, fullIndexName); } } @@ -361,7 +361,7 @@ public class PartialIndexRebuilderIT extends BaseUniqueNamesOwnClusterIT { TestUtil.dumpTable(conn.unwrap(PhoenixConnection.class).getQueryServices().getTable(Bytes.toBytes(fullTableName))); TestUtil.dumpTable(conn.unwrap(PhoenixConnection.class).getQueryServices().getTable(Bytes.toBytes(fullIndexName))); - TestUtil.scutinizeIndex(conn, fullTableName, fullIndexName); + TestUtil.scrutinizeIndex(conn, fullTableName, fullIndexName); } } } http://git-wip-us.apache.org/repos/asf/phoenix/blob/ea8646c7/phoenix-core/src/test/java/org/apache/phoenix/util/TestUtil.java ---------------------------------------------------------------------- diff --git a/phoenix-core/src/test/java/org/apache/phoenix/util/TestUtil.java b/phoenix-core/src/test/java/org/apache/phoenix/util/TestUtil.java index 773006e..b5352b3 100644 --- a/phoenix-core/src/test/java/org/apache/phoenix/util/TestUtil.java +++ b/phoenix-core/src/test/java/org/apache/phoenix/util/TestUtil.java @@ -882,7 +882,7 @@ public class TestUtil { } } - public static long scutinizeIndex(Connection conn, String fullTableName, String fullIndexName) throws SQLException { + public static long scrutinizeIndex(Connection conn, String fullTableName, String fullIndexName) throws SQLException { PhoenixConnection pconn = conn.unwrap(PhoenixConnection.class); PTable ptable = pconn.getTable(new PTableKey(pconn.getTenantId(), fullTableName)); PTable pindex = pconn.getTable(new PTableKey(pconn.getTenantId(), fullIndexName));
