Repository: phoenix Updated Branches: refs/heads/4.x-HBase-1.2 af5716c1b -> d79dd50ff
PHOENIX-4275 Use unique table names for ViewIT Project: http://git-wip-us.apache.org/repos/asf/phoenix/repo Commit: http://git-wip-us.apache.org/repos/asf/phoenix/commit/4bf1b224 Tree: http://git-wip-us.apache.org/repos/asf/phoenix/tree/4bf1b224 Diff: http://git-wip-us.apache.org/repos/asf/phoenix/diff/4bf1b224 Branch: refs/heads/4.x-HBase-1.2 Commit: 4bf1b2242e78be31e751a12455a1d98eb7fcbc8a Parents: af5716c Author: James Taylor <[email protected]> Authored: Tue Oct 3 15:03:03 2017 -0700 Committer: James Taylor <[email protected]> Committed: Tue Oct 3 15:06:40 2017 -0700 ---------------------------------------------------------------------- .../src/it/java/org/apache/phoenix/end2end/ViewIT.java | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/phoenix/blob/4bf1b224/phoenix-core/src/it/java/org/apache/phoenix/end2end/ViewIT.java ---------------------------------------------------------------------- diff --git a/phoenix-core/src/it/java/org/apache/phoenix/end2end/ViewIT.java b/phoenix-core/src/it/java/org/apache/phoenix/end2end/ViewIT.java index 267dbc9..1953f79 100644 --- a/phoenix-core/src/it/java/org/apache/phoenix/end2end/ViewIT.java +++ b/phoenix-core/src/it/java/org/apache/phoenix/end2end/ViewIT.java @@ -701,15 +701,15 @@ public class ViewIT extends BaseViewIT { Properties props = new Properties(); Connection conn1 = DriverManager.getConnection(getUrl(), props); conn1.setAutoCommit(true); - String TABLE_NAME="UpdateCacheViewTest"+System.currentTimeMillis(); - String VIEW_NAME="VIEW_"+System.currentTimeMillis(); + String tableName=generateUniqueName(); + String viewName=generateUniqueName(); conn1.createStatement().execute( - "CREATE TABLE "+TABLE_NAME+" (k VARCHAR PRIMARY KEY, v1 VARCHAR, v2 VARCHAR) UPDATE_CACHE_FREQUENCY=1000000"); - conn1.createStatement().execute("upsert into "+TABLE_NAME+" values ('row1', 'value1', 'key1')"); + "CREATE TABLE "+tableName+" (k VARCHAR PRIMARY KEY, v1 VARCHAR, v2 VARCHAR) UPDATE_CACHE_FREQUENCY=1000000"); + conn1.createStatement().execute("upsert into "+tableName+" values ('row1', 'value1', 'key1')"); conn1.createStatement().execute( - "CREATE VIEW "+VIEW_NAME+" (v43 VARCHAR) AS SELECT * FROM "+TABLE_NAME+" WHERE v1 = 'value1'"); + "CREATE VIEW "+viewName+" (v43 VARCHAR) AS SELECT * FROM "+tableName+" WHERE v1 = 'value1'"); ResultSet rs = conn1.createStatement() - .executeQuery("SELECT * FROM "+TABLE_NAME+" WHERE v1 = 'value1'"); + .executeQuery("SELECT * FROM "+tableName+" WHERE v1 = 'value1'"); assertTrue(rs.next()); }
