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

Jeffrey Zhong commented on PHOENIX-1688:
----------------------------------------

I c. I already forgot PHOENIX-1257:-). The issue is as following:

We create sequence using different ways: 
a) createIndex case we use data table timestamp which is from System.catalog RS
b) normal sequence creation we use server timestamp which is from 
system.sequence RS.
c)delete sequence using server timestamp which is from system.sequence RS. 

Here comes the issues:
1) if related system.sequence region moved between two RSs with time clock skew 
issue, create/delete same sequence repeatedly will have unexpected result like 
sequence not found or already exist exceptions

2) for createIndex case, we may get unexpected issue when repeatedly 
create/delete same table and sequences because previous delete marker may 
shadow new sequence creation, etc.

I think we should change create & delete sequence code path to uses current 
timestamp from system.catalog RS like other insert/delete cases.  


> dropSequence uses HConstants.LATEST_TIMESTAMP as the Append timestamp
> ---------------------------------------------------------------------
>
>                 Key: PHOENIX-1688
>                 URL: https://issues.apache.org/jira/browse/PHOENIX-1688
>             Project: Phoenix
>          Issue Type: Bug
>            Reporter: Jeffrey Zhong
>            Assignee: Jeffrey Zhong
>         Attachments: PHOENIX-1688.patch
>
>
> system.sequence isn't running on the same region server of system.catalog. 
> When the Append uses HContants.LATEST_TIMESTAMP, the append will use the 
> current server time of the RS which is hosting system.sequence table.
> If the two servers have time clock skew, then unexpected errors like 
> SequenceNotFoundException will happen.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to