You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@phoenix.apache.org by "James Taylor (JIRA)" <ji...@apache.org> on 2017/09/11 22:53:00 UTC

[jira] [Commented] (PHOENIX-4194) Modify RoundFloorCeilFuncIT, RowValueConstructorIT, SaltedTableIT, TenantIdTypeIT, StoreNullsIT and RebuildIndexConnectionPropsIT to not use CurrentSCN

    [ https://issues.apache.org/jira/browse/PHOENIX-4194?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16162184#comment-16162184 ] 

James Taylor commented on PHOENIX-4194:
---------------------------------------

Thanks, [~mujtabachohan]. Looks good, a couple of minor items that you can fix when you commit:
- Looks like there are still a few references to nextTimestamp() here that need to be removed. You should be able to just pass in null instead:
{code}
@@ -908,25 +848,27 @@ public class RowValueConstructorIT extends BaseClientManagedTimeIT {
     @Test
     public void testInListOfRVC1() throws Exception {
         String tenantId = "ABC";
+        String tableName = generateUniqueName();
+        String viewName = generateUniqueName();
         String tenantSpecificUrl = getUrl() + ";" + PhoenixRuntime.TENANT_ID_ATTRIB + '=' + tenantId;
-        String baseTableDDL = "CREATE TABLE t (tenantId varchar(5) NOT NULL, pk2 varchar(5) NOT NULL, pk3 INTEGER NOT NULL, c1 INTEGER constraint pk primary key (tenantId,pk2,pk3)) MULTI_TENANT=true";
+        String baseTableDDL = "CREATE TABLE " + tableName + " (tenantId varchar(5) NOT NULL, pk2 varchar(5) NOT NULL, pk3 INTEGER NOT NULL, c1 INTEGER constraint pk primary key (tenantId,pk2,pk3)) MULTI_TENANT=true";
         createTestTable(getUrl(), baseTableDDL, null, nextTimestamp());
-        String tenantTableDDL = "CREATE VIEW t_view (tenant_col VARCHAR) AS SELECT *\n" + 
-                "                FROM t";
+        String tenantTableDDL = "CREATE VIEW " + viewName + " (tenant_col VARCHAR) AS SELECT *\n" + 
+                "                FROM " + tableName;
         createTestTable(tenantSpecificUrl, tenantTableDDL, null, nextTimestamp());
{code}
- Just to confirm, are there perhaps calls to {{initEntityHistoryTableValues}} outside of the files you're changing so that's why you're adding/keeping this method?
{code}
-    private static void initEntityHistoryTableValues(String tenantId, byte[][] splits, Date date, Long ts, String url) throws Exception {
+    protected static String initEntityHistoryTableValues(String tenantId, byte[][] splits, Date date, String url) throws Exception {
+        return initEntityHistoryTableValues(ENTITY_HISTORY_TABLE_NAME, tenantId, splits, date, null, url);
+    }
{code}

> Modify RoundFloorCeilFuncIT, RowValueConstructorIT, SaltedTableIT, TenantIdTypeIT, StoreNullsIT and RebuildIndexConnectionPropsIT to not use CurrentSCN
> -------------------------------------------------------------------------------------------------------------------------------------------------------
>
>                 Key: PHOENIX-4194
>                 URL: https://issues.apache.org/jira/browse/PHOENIX-4194
>             Project: Phoenix
>          Issue Type: Test
>            Reporter: Mujtaba Chohan
>            Assignee: Mujtaba Chohan
>             Fix For: 4.12.0
>
>         Attachments: PHOENIX-4194.patch
>
>




--
This message was sent by Atlassian JIRA
(v6.4.14#64029)