ignite-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Pavel Kuznetsov (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (IGNITE-10897) Blocked drop table operations cause strange issues
Date Thu, 31 Jan 2019 14:51:00 GMT

    [ https://issues.apache.org/jira/browse/IGNITE-10897?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16757312#comment-16757312

Pavel Kuznetsov commented on IGNITE-10897:

Discussed with [~vozerov].
If we got blocked select, first drop table will block till that select ends. Unfortunately,
first drop query mutates data structures before it acquires the table lock, so second drop
table would say, there is no such table. 
Naive fix is to acquire lock earlier, but it doesn't solve the problem in all cases. We could
have some nodes that doesn't executing freezed select and some nodes - does. So on the "freezed"
nodes all drop table operations would be blocked on the lock, the other nodes would execute

Vladimir suggested fix concept: we need multi-phase mechanism for selects and drops similar
to PME. 
1) Notify nodes that particular table should become disabled for all subsequent selects
2) Wait for all running selects are done. This is selects that had been running before we
sent drop table.
3) Actually remove the tables.

> Blocked drop table operations cause strange issues
> --------------------------------------------------
>                 Key: IGNITE-10897
>                 URL: https://issues.apache.org/jira/browse/IGNITE-10897
>             Project: Ignite
>          Issue Type: Bug
>          Components: sql
>    Affects Versions: 2.6, 2.7
>            Reporter: JiajunYang
>            Assignee: Pavel Kuznetsov
>            Priority: Major
> Reproduce steps to get a blocked drop table operation:
> 1.Create a table and put some data to a node with persistence enabled. 
>  2.Do a select query targeting on the table which runs long time. 
>  3.Drop the table before the select query end. 
>  Then u will see drop table operation blocks until the select query end.
> A strange issue cause by blocked drop table operations:
> 1.Do another drop table operation when there is a blocked drop table operation.This operation
will also block.
> 2.Try to recreate the table with same name.Then you can see "table 
>  already exists" exception. 
> 3.Try to drop the table again,then you can see 
>  "Table doesn't exist" exception. 

This message was sent by Atlassian JIRA

View raw message