[
https://issues.apache.org/jira/browse/IGNITE-6380?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16219542#comment-16219542
]
Pavel Pereslegin commented on IGNITE-6380:
------------------------------------------
Hello, [~rajivgandhi].
I see that second thread is stuck on latch2.await() instead of cache1.clear()
are you sure this is correct reproducer?
If you want to show that clear() stuck and be sure that reentrantLock was
executed first - you can change it to latch2.await(1, TimeUnit.SECONDS), for
example.
And in this case (with proposed patch) execution of clear() will be rejected.
> Exception should be thrown on cache creation attempt inside transaction
> -----------------------------------------------------------------------
>
> Key: IGNITE-6380
> URL: https://issues.apache.org/jira/browse/IGNITE-6380
> Project: Ignite
> Issue Type: Improvement
> Reporter: Yakov Zhdanov
> Assignee: Pavel Pereslegin
> Labels: newbie, usability
>
> Exception should be thrown on cache creation attempt inside transaction to
> prevent deadlocks since cache start triggers exchange and exchange cannot
> finish until all txs are finished.
> We need to check if thread owns a tx before starting cache and if it does
> then IllegalStateException should be thrown.
--
This message was sent by Atlassian JIRA
(v6.4.14#64029)