You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@ignite.apache.org by "Ivan Bessonov (Jira)" <ji...@apache.org> on 2024/09/06 10:43:00 UTC
[jira] [Commented] (IGNITE-22609) MetaStorageListener can access KeyValueStorage after it had been closed
[ https://issues.apache.org/jira/browse/IGNITE-22609?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17879834#comment-17879834 ]
Ivan Bessonov commented on IGNITE-22609:
----------------------------------------
> Also, it must be checked if similar Raft Listeners in other components are affected by the same issue.
Indeed the code of jraft can't really handle a component shutdown without data races, the pattern of using `shutdownLatch` and `synchronized` makes no sense, and proper order of components is too tangled anyway.
I guess we should fix it everywhere at once. The simplest way of doing it is in raft listeners. It won't fix the race, but we won't fail with JVM halt, at least.
> MetaStorageListener can access KeyValueStorage after it had been closed
> -----------------------------------------------------------------------
>
> Key: IGNITE-22609
> URL: https://issues.apache.org/jira/browse/IGNITE-22609
> Project: Ignite
> Issue Type: Bug
> Reporter: Aleksandr Polovtsev
> Assignee: Ivan Bessonov
> Priority: Major
> Labels: ignite-3
> Attachments: hs_err_pid2936001.log
>
>
> See the attached stacktrace for details. Looks like we are trying to process a read command in {{MetaStorageListener}} while the underlying storage has already been closed.
> This may be happening because looks like we don't guarantee that {{RaftManager#stopRaftNodes}} waits for all read commands to be processed. If this is the case, a possible solution would be to add a busy lock either to the {{MetaStorageListener}} or to the {{KeyValueStorage}}. But this needs to be verified first.
> Also, it must be checked if similar Raft Listeners in other components are affected by the same issue.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)