You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@ignite.apache.org by "ASF GitHub Bot (JIRA)" <ji...@apache.org> on 2017/04/26 13:34:04 UTC

[jira] [Commented] (IGNITE-4648) IgniteInternalTx.prepare() does not wait for async operations to complete

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

ASF GitHub Bot commented on IGNITE-4648:
----------------------------------------

GitHub user SomeFire opened a pull request:

    https://github.com/apache/ignite/pull/1876

    IGNITE-4648

    

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/SomeFire/ignite ignite-4648

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/ignite/pull/1876.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #1876
    
----
commit 400dca03c510730d867807a734195ff4a6bae77a
Author: Dmitrii Ryabov <so...@gmail.com>
Date:   2017-04-26T13:28:18Z

    tx.txState().awaitLastFut() inserted into prepareTx()

----


> IgniteInternalTx.prepare() does not wait for async operations to complete
> -------------------------------------------------------------------------
>
>                 Key: IGNITE-4648
>                 URL: https://issues.apache.org/jira/browse/IGNITE-4648
>             Project: Ignite
>          Issue Type: Bug
>          Components: cache
>    Affects Versions: 1.7
>            Reporter: Pavel Tupitsyn
>            Assignee: Ryabov Dmitrii
>            Priority: Minor
>             Fix For: 2.1
>
>
> {{commit}} and {{rollback}} wait for async operations by calling {{tx.txState().awaitLastFut();}} (see {{GridCacheSharedContext}}).
> There is no such thing in {{IgniteInternalTx.prepare()}} implementations.
> Since {{prepare}} is an internal method, this is not an issue mostly, except for two things:
> * JTA. {{CacheJtaResource}} calls {{prepare()}} explicitly. 
> * .NET {{TransactionScope}} API. Same thing as JTA, basically. {{PlatformTransactions}} call {{prepare()}} as well.
> As a result, if user starts an async operation within JTA transaction and then completes the tx, undefined behavior is possible.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)