Github user CK50 commented on the issue:
https://github.com/apache/spark/pull/13925
@sowen: yes, supportsTransactions() sounds good. I do not remember why I
took the other two conditions and whether this makes any difference.
I agree that committing in between defeats the purpose of the
transaction action handling.
On 28.06.2016 15:04, Sean Owen wrote:
>
> No, an exception will now only roll back anything that happened since
> the last commit. It is not the same. The whole reason it's 'blocking'
> is that you are holding open a transaction, but, that's the point.
>
> There's an interesting point here though; this code is willing to
> proceed if the RDBMS does not support transactions at all, in which
> case it /will/ write partial results that can't be rolled back. Really
> I'd think that in this case you want to call |executeBatch()| only
> once at the end. I wonder if that's actually a bug (CC @rxin
> <https://github.com/rxin> who wrote that bit?)
>
> However, if that is acceptable, then perhaps a weaker JDBC transaction
> isolation level is acceptable for the case where transactions are
> supported. If you're willing to accept dirty reads with
> |TRANSACTION_READ_UNCOMMITTED|, then I don't think (?) the table has
> to be locked, which may solve your problem. It still means the writes
> would be rolled back in case of a failure, which is much of the point
> here according to comments.
>
> CC @CK50 <https://github.com/CK50> for the transaction question. Also
> barely related but shouldn't it just call |supportsTransactions()| at
> the beginning?
>
> â
> You are receiving this because you were mentioned.
> Reply to this email directly, view it on GitHub
> <https://github.com/apache/spark/pull/13925#issuecomment-229042189>,
> or mute the thread
>
<https://github.com/notifications/unsubscribe/APQTSY-IpRC38pooh6dQGmRBT90Rgi7uks5qQRvTgaJpZM4I_Kd7>.
>
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]