phoenix-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Monani Mihir (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (PHOENIX-5193) Handle SQLException:ERROR 2008 (INT10) in PhoenixIndexFailurePolicy#doBatchWithRetries
Date Thu, 14 Mar 2019 12:23:00 GMT

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

Monani Mihir commented on PHOENIX-5193:
---------------------------------------

No, [~vincentpoon] . It only gets handled if this is first try for do...while loop in MutationState class. 

The patch i have created is for below case:- 

For first try of do...while loop , Data table write succeeds and Index table write fails
with *INDEX_WRITE_FAILURE*. In this case, we update data table mutationBatch with *REPLAY_ONLY_INDEX_WRITES*
and set *shouldRetryIndexedMutation=true* in MutationState class. So when second and final
retry for do...while loop happens we run PhoenixIndexFailurePolicy.doBatchWithRetries#doMutation()
. Here while retries are happening for indexes, it might throw *INDEX_METADATA_NOT_FOUND*
or *INDEX_WRITE_FAILURE* if it encounters SQLException.

> Handle SQLException:ERROR 2008 (INT10) in PhoenixIndexFailurePolicy#doBatchWithRetries

> ---------------------------------------------------------------------------------------
>
>                 Key: PHOENIX-5193
>                 URL: https://issues.apache.org/jira/browse/PHOENIX-5193
>             Project: Phoenix
>          Issue Type: Sub-task
>    Affects Versions: 4.14.0, 5.0.0, 4.14.1
>            Reporter: Monani Mihir
>            Assignee: Monani Mihir
>            Priority: Critical
>         Attachments: PHOENIX-5193-4.x-HBase-1.3.01.patch
>
>
> In MutationState#send(Iterator<TableRef>)#doMutation , we use htable.batch() which
will throw SQLException wrapped in RetriesExhaustedWithDetailsException. 
>  These wrapped SQLException are of two types, 
> 1) INDEX_WRITE_FAILURE(1121, "XCL21", "Write to the index failed.")
> 2) INDEX_METADATA_NOT_FOUND(2008, "INT10", "Unable to find cached index metadata. ")
> Out of this we only handle 1st (INDEX_WRITE_FAILURE) and we should handle 2nd one too
(INDEX_METADATA_NOT_FOUND)



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Mime
View raw message